Commit db98727b by liuhui

首页前台后台拆分基本完成

parent 666bb2a0
Showing with 18175 additions and 25 deletions
...@@ -269,6 +269,13 @@ ...@@ -269,6 +269,13 @@
<artifactId>fastjson</artifactId> <artifactId>fastjson</artifactId>
</dependency> </dependency>
<!-- 工具类 -->
<dependency>
<groupId>com.xiaoleilu</groupId>
<artifactId>hutool-all</artifactId>
<version>3.3.2</version>
</dependency>
</dependencies> </dependencies>
<build> <build>
...@@ -277,39 +284,45 @@ ...@@ -277,39 +284,45 @@
<resource> <resource>
<directory>src/main/resources</directory> <directory>src/main/resources</directory>
<filtering>true</filtering> <filtering>true</filtering>
<excludes>
<exclude>static/fonts/**</exclude>
<exclude>static/file/**</exclude>
<exclude>**/*.woff</exclude>
<exclude>**/*.woff2</exclude>
<exclude>**/*.ttf</exclude>
</excludes>
<includes> <includes>
<include>application.yml</include> <include>application.yml</include>
<include>application-${profileActive}.yml</include> <include>application-${profileActive}.yml</include>
<include>banner.txt</include> <include>banner.txt</include>
<include>ehcache/*</include>
<include>i18n/*</include>
<include>log4j.xml</include>
<include>mybatis/**/*</include> <include>mybatis/**/*</include>
<include>static/**/*</include> <include>static/**/*</include>
<include>templates/**/*</include> <include>templates/**/*</include>
<include>ehcache/*</include> <include>wps.properties</include>
<include>log4j.xml</include> </includes>
</resource>
<resource>
<directory>src/main/resources</directory>
<filtering>false</filtering>
<includes>
<include>static/fonts/**</include>
<include>static/file/**</include>
<include>**/*.woff</include>
<include>**/*.woff2</include>
<include>**/*.ttf</include>
</includes> </includes>
</resource> </resource>
</resources> </resources>
<plugins> <plugins>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<failOnMissingWebXml>false</failOnMissingWebXml>
</configuration>
</plugin>
<plugin>
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId> <artifactId>spring-boot-maven-plugin</artifactId>
<configuration> <configuration>
<includeSystemScope>true</includeSystemScope> <includeSystemScope>true</includeSystemScope>
</configuration> </configuration>
<executions>
<execution>
<goals>
<goal>repackage</goal>
</goals>
</execution>
</executions>
</plugin> </plugin>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
...@@ -320,6 +333,24 @@ ...@@ -320,6 +333,24 @@
<target>1.8</target> <target>1.8</target>
</configuration> </configuration>
</plugin> </plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.10</version>
<executions>
<execution>
<id>copy-dependencies</id>
<phase>compile</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>${project.build.directory}/${project.build.finalName}/WEB-INF/lib</outputDirectory>
<includeScope>system</includeScope>
</configuration>
</execution>
</executions>
</plugin>
</plugins> </plugins>
</build> </build>
</project> </project>
...@@ -131,7 +131,9 @@ public class ShiroRedisConfig { ...@@ -131,7 +131,9 @@ public class ShiroRedisConfig {
redisManager.setHost(redisHost); redisManager.setHost(redisHost);
redisManager.setPort(redisPort); redisManager.setPort(redisPort);
redisManager.setTimeout(redisTimeout); redisManager.setTimeout(redisTimeout);
if(!"".equals(redisPassword.trim())){
redisManager.setPassword(redisPassword); redisManager.setPassword(redisPassword);
}
return redisManager; return redisManager;
} }
......
package com.sinobase.framework.config;
import java.util.Properties;
import com.alibaba.druid.filter.config.ConfigTools;
import com.alibaba.druid.util.DruidPasswordCallback;
/**
*
* @author shj 对配置文件中的数据库密码进行解密
*/
public class DbPasswordCallback extends DruidPasswordCallback {
@Override
public void setProperties(Properties properties) {
super.setProperties(properties);
String password = (String) properties.get("password");
String publickey = (String) properties.get("publicKey");
try {
String dbpassword = DbPasswordCallback.decryptStr(password);
setPassword(dbpassword.toCharArray());
} catch (Exception e) {
e.printStackTrace();
}
}
public static final byte[] SECRET_KEY = "0123456789abcdef".getBytes();
public static String decryptStr(String enStr) {
com.xiaoleilu.hutool.crypto.symmetric.SymmetricCrypto aes = new com.xiaoleilu.hutool.crypto.symmetric.SymmetricCrypto(
com.xiaoleilu.hutool.crypto.symmetric.SymmetricAlgorithm.AES, SECRET_KEY);
return aes.decryptStr(enStr);
}
public static String encryptStr(String enStr) {
com.xiaoleilu.hutool.crypto.symmetric.SymmetricCrypto aes = new com.xiaoleilu.hutool.crypto.symmetric.SymmetricCrypto(
com.xiaoleilu.hutool.crypto.symmetric.SymmetricAlgorithm.AES, SECRET_KEY);
return new String(aes.encryptHex(enStr));
}
}
...@@ -41,7 +41,7 @@ public class UserRealm extends AuthorizingRealm { ...@@ -41,7 +41,7 @@ public class UserRealm extends AuthorizingRealm {
logger.debug("username: {} will validate" , username); logger.debug("username: {} will validate" , username);
User user = new User(); User user = new User();
if(isPlatform) { //如果集成SSO登录 if(isPlatform) { //如果集成SSO登录
user = platformService.getUserByLoginname(username); user = platformService.setLoginUserInfo(username);
return new SimpleAuthenticationInfo(user, password, getName()); return new SimpleAuthenticationInfo(user, password, getName());
}else { //如果没有集成sso的情况下,需要开发者自行验证用户信息 }else { //如果没有集成sso的情况下,需要开发者自行验证用户信息
if("developer".equals(username) && "123456".equals(password)) { if("developer".equals(username) && "123456".equals(password)) {
......
package com.sinobase.project.module.docsend.controller;
import com.github.pagehelper.PageHelper;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.framework.web.controller.BaseController;
import com.sinobase.framework.web.page.PageDomain;
import com.sinobase.framework.web.page.TableDataInfo;
import com.sinobase.framework.web.page.TableSupport;
import com.sinobase.project.module.docsend.service.IReadExtranetService;
import com.sinobase.project.module.docsend.service.IReadService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping("/read")
public class ReadController extends BaseController {
@Autowired
private IReadService readService;
@Autowired
private IReadExtranetService readExtranetService;
@Value("${sinobase.isIntranet}")
private boolean isIntranet;
/**
* 获取已阅分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return json型式的整页待办数据
*/
@RequestMapping("/list/{pageNumber}/{countPerPage}")
@ResponseBody
public List<Map<String, String>> getDocSendList(@PathVariable int pageNumber, @PathVariable int countPerPage){
int pageCount = 0;
if(isIntranet){
pageCount = readService.getPageCount(countPerPage);
}else{
pageCount = readExtranetService.getPageCount(countPerPage);
}
List<Map<String, String>> docSendList = null;
if(pageNumber <= pageCount) {
if(isIntranet){
docSendList = readService.docSendList(pageNumber, countPerPage,"self","","");
}else{
docSendList = readExtranetService.docSendList(pageNumber, countPerPage,"self","","");
}
}
return docSendList;
}
/**
* 获取列表信息
* @return
*/
@RequestMapping("/tablelist")
@ResponseBody
public TableDataInfo getDocSendTableList(String title,String number){
PageDomain pageDomain = TableSupport.buildPageRequest();
Integer pageNum = pageDomain.getPageNum();
Integer pageSize = pageDomain.getPageSize();
if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
String orderBy = pageDomain.getOrderBy();
PageHelper.startPage(pageNum, pageSize, orderBy);
}
int indexCount = 0;
List<Map<String, String>> docSendList = null;
if(isIntranet){
indexCount = readService.getIndexCount(title,number);
docSendList = readService.docSendList(pageNum, pageSize,"self",title,number);
}else{
indexCount = readExtranetService.getIndexCount(title,number);
docSendList = readExtranetService.docSendList(pageNum, pageSize,"self",title,number);
}
TableDataInfo rspData = new TableDataInfo();
rspData.setCode(0);
rspData.setRows(docSendList);
rspData.setTotal(indexCount);
return rspData;
}
/**
* 获取已阅数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
@RequestMapping("/page_count/{count}")
@ResponseBody
public int getPageCount(@PathVariable int count) {
int pageCount = 0;
if(isIntranet){
pageCount = readService.getPageCount(count);
}else{
pageCount = readExtranetService.getPageCount(count);
}
return pageCount;
}
}
package com.sinobase.project.module.docsend.dao;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.system.user.domain.User;
public class IndexReadHandler {
private static final Logger log = LoggerFactory.getLogger(IndexReadHandler.class);
/**
* 刷新已阅索引数据
* @param dataSource
* @return
*/
public static synchronized boolean refreshIndex(DruidDataSource dataSource) {
boolean result = true;
//step.1 查询索引表最新的日期
Date latestTime = new Date();
List<Map<String, Object>> localList = new ArrayList<Map<String, Object>>();
List<Map<String, Object>> remoteList = new ArrayList<Map<String, Object>>();
try {
latestTime = IndexReadHandler.getLatestOfIndex(dataSource);
} catch (SQLException e) {
result = false;
e.printStackTrace();
}
try {
//step.2 根据第一步的时间查询出本地缺少的已阅数据
localList = LocalSysReadHandler.getNotIndexedLocal(dataSource, latestTime);
//step.3 根据第一步的时间查询出远程缺少的已阅数
remoteList = RemoteSysReadHandler.getNotIndexedRemote(latestTime);
} catch (SQLException e) {
e.printStackTrace();
}
//step.4 把第二、三步查出来的数据插入到索引表当中(分批执行,每次执行1000条)
int bufferSize = 1000;
List<String> sqlList = new LinkedList<String>(); //切割后的批量插入sql语句集合
List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();
list.addAll(localList);
list.addAll(remoteList);
do {
List<Map<String, Object>> tempList = new ArrayList<Map<String, Object>>();
if(list.size() > bufferSize) {
tempList = list.subList(0, bufferSize - 1);
}else {
tempList = list;
}
String sqlFragment = IndexReadHandler.buildSQLFragment(tempList);
String sql = IndexReadHandler.buildSQLStatement(sqlFragment);
if(null != sql && !"".equals(sql.trim()))
sqlList.add(sql);
tempList.clear();
}while(list.size() != 0);
try {
IndexReadHandler.queryInsert4Index(dataSource, sqlList);
} catch (SQLException e) {
e.printStackTrace();
}
return result;
}
/**
* 从已阅索引中获取已阅数量
* @param dataSource
* @return
*/
public static int getIndexCount(DruidDataSource dataSource,String title,String number)
throws SQLException{
User user = ShiroUtils.getSysUser();
int count = 0;
String sql = "select count(1) as count from sys_read_index where (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"')";
if(StringUtils.isNotEmpty(title)){
sql += " and title like '%"+title+"%'";
}
if(StringUtils.isNotEmpty(title)){
sql += " and number like '%"+number+"%'";
}
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs && rs.next()) {
count = rs.getInt("count");
}
} catch (SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
return count;
}
/**
* 从已阅列表中获取分页数据
* @param dataSource
* @param pageNumber
* @param countPerPage
* @return
*/
public static List<Map<String, Object>> paging(DruidDataSource dataSource, int pageNumber, int countPerPage,String title,String number){
User user = ShiroUtils.getSysUser();
String sql = "select id,doomsday,userid,source_system from sys_read_index where (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"')";
if(StringUtils.isNotEmpty(title)){
sql += " and title like '%"+title+"%'";
}
if(StringUtils.isNotEmpty(number)){
sql += " and number like '%"+number+"%'";
}
sql += " order by str_to_date(doomsday,'%Y-%m-%d %H:%i:%s') desc limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
List<Map<String, Object>> ret = new LinkedList<Map<String, Object>>();
try {
Connection conn = dataSource.getConnection();
PreparedStatement pstmt = conn.prepareStatement(sql);
ResultSet rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, Object> map = new HashMap<String, Object>();
String id = rs.getString("id");
Date doomsday = new Date(rs.getTimestamp("doomsday").getTime());
String userid = rs.getString("userid");
String source = rs.getString("source_system");
map.put("id", id);
map.put("doomsday", doomsday);
map.put("userid", userid);
map.put("source", source);
ret.add(map);
}
}
rs.close();
pstmt.close();
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}
return ret;
}
/**
* 获取所有的已阅
* @param dataSource
* @return
*/
public static List<Map<String, Object>> paging(DruidDataSource dataSource){
User user = ShiroUtils.getSysUser();
String sql = "select id,doomsday,userid,source_system from sys_read_index where (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"')" +
" order by str_to_date(doomsday,'%Y-%m-%d %H:%i:%s') desc ";
List<Map<String, Object>> ret = new LinkedList<Map<String, Object>>();
try {
Connection conn = dataSource.getConnection();
PreparedStatement pstmt = conn.prepareStatement(sql);
ResultSet rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, Object> map = new HashMap<String, Object>();
String id = rs.getString("id");
Date doomsday = new Date(rs.getTimestamp("doomsday").getTime());
String userid = rs.getString("userid");
String source = rs.getString("source_system");
map.put("id", id);
map.put("doomsday", doomsday);
map.put("userid", userid);
map.put("source", source);
ret.add(map);
}
}
rs.close();
pstmt.close();
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}
return ret;
}
//获取当前索引表中最近的时间
private static Date getLatestOfIndex(DruidDataSource dataSource)
throws SQLException {
User user = ShiroUtils.getSysUser();
String sql = "select id,doomsday,source_system from sys_read_index where (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"') order by doomsday desc limit 1";
Date latestOfIndex = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
try {
latestOfIndex = sdf.parse("1970-01-01 08:00:00");
} catch (ParseException e1) {
e1.printStackTrace();
}
Connection conn = dataSource.getConnection();
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs && rs.next()) {
latestOfIndex = new Date(rs.getTimestamp("doomsday").getTime());
}
rs.close();
pstmt.close();
conn.close();
} catch(SQLException e) {
e.printStackTrace();
}
return latestOfIndex;
}
//向已阅索引表插入已阅数据
private static void queryInsert4Index(DruidDataSource dataSource, List<String> sqlList)
throws SQLException {
Connection conn = dataSource.getConnection();
Statement stmt = conn.createStatement();
int sqlSize = sqlList.size();
for(int ix = 0; ix < sqlSize; ++ ix) { //直接遍历执行所有sql语句,按理说应该不需要sleep
String sql = sqlList.get(ix);
//log.debug("query:"+sql);
stmt.executeUpdate(sql);
}
stmt.close();
conn.close();
}
//构建SQL语句片段
private static String buildSQLFragment(List<Map<String, Object>> list) {
StringBuffer fragment = new StringBuffer("");
int size = list.size();
for(int ix = 0; ix < size; ++ ix) {
Map<String, Object> cur = list.get(ix);
String id = String.valueOf(cur.get("id"));
String doomsday = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format((Date)cur.get("doomsday"));
String userid = String.valueOf(cur.get("userid"));
String title = cur.get("title") == null ? "" : cur.get("title").toString();
String number = cur.get("number") == null ? "" : cur.get("number").toString();
String source = cur.get("source") == null ? "" : cur.get("source").toString();
if(0 != ix) {
fragment.append(",");
}
fragment.append("('"+id+"','"+doomsday+"','"+userid+"','"+title+"','"+number+"','"+source+"')");
}
return fragment.toString();
}
//将SQL语句片段构建成完整语句
private static String buildSQLStatement(String fragment) {
String sql = "";
if(null != fragment && !"".equals(fragment.trim())) {
sql = "insert into sys_read_index (id,doomsday,userid,title,number,source_system) values " + fragment;
}
return sql;
}
}
package com.sinobase.project.module.docsend.dao;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.system.user.domain.User;
import org.apache.poi.util.StringUtil;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.text.SimpleDateFormat;
import java.util.*;
public class LocalSysReadHandler {
public static final String SOURCE = "local";
/**
* 外网直接获取mysql中已阅数据
* @param dataSource
* @param pageNumber
* @param countPerPage
* @param title
* @return
* @throws SQLException
*/
public static List<Map<String, String>> getDoneList(DruidDataSource dataSource,int pageNumber,int countPerPage,String title,String number)
throws SQLException{
User user = ShiroUtils.getSysUser();
List<Map<String, String>> ret = new ArrayList<Map<String, String>>();
String fieldArray[] = new String[] {"send_id", "send_title", "user_notion", "view_url", "keyword", "relation_id", "relation_table", "relation_key", "notion_date"};
String filedStr = StringUtil.join(fieldArray, ",");
String sql = "select "+filedStr+" from doc_send where (in_user_id='"+user.getUserId()+"' or in_user_id='"+user.getHistoryId()+"')";
if(StringUtils.isNotEmpty(title)){
sql += " and title like '%"+title+"%'";
}
if(StringUtils.isNotEmpty(number)){
sql += " and number like '%"+number+"%'";
}
sql += " order by str_to_date(notion_date,'%Y-%m-%d %H:%i:%s') desc ";
if(pageNumber!=0&&countPerPage!=0){
sql += " limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
}
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, String> cur = new HashMap<String, String>();
for(int ix = 0; ix < fieldArray.length; ++ ix) {
String field = fieldArray[ix];
String val = rs.getString(field);
cur.put(field, val);
}
cur.put("source",LocalSysReadHandler.SOURCE);
ret.add(cur);
}
}
} catch (SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
/**
* 从已办表中查询一个时间点到当前时间的数据
* @param dataSource
* @param latestTime
* @return
* @throws SQLException
*/
static List<Map<String, Object>> getNotIndexedLocal(DruidDataSource dataSource, Date latestTime)
throws SQLException{
User user = ShiroUtils.getSysUser();
String time = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(latestTime);
List<Map<String, Object>> ret = new ArrayList<Map<String, Object>>(); //ArrayList即可,无需排序
String sql = "select send_id, str_to_date(notion_date, '%Y-%m-%d %H:%i:%s') as doomsday,in_user_id,send_title,user_notion " +
" from doc_send " +
" where (in_user_id='"+user.getUserId()+"' or in_user_id='"+user.getHistoryId()+"') and " +
"str_to_date(notion_date, '%Y-%m-%d %H:%i:%s') > str_to_date('"+time+"', '%Y-%m-%d %H:%i:%s') and see_flag='1'" +
" order by str_to_date(notion_date, '%Y-%m-%d %H:%i:%s') desc";
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, Object> temp = new HashMap<String, Object>();
String id = rs.getString("send_id");
Date doomsday = new Date(rs.getTimestamp("doomsday").getTime());
String userid = rs.getString("in_user_id");
String title = rs.getString("send_title");
String number = rs.getString("user_notion");
temp.put("id", id);
temp.put("doomsday", doomsday);
temp.put("userid", userid);
temp.put("title", title);
temp.put("number", number);
temp.put("source", LocalSysReadHandler.SOURCE);
ret.add(temp);
}
}
} catch(SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
/**
* 根据已办ID批量获取已办信息(不排序)
* @param dataSource
* @param idList
* @return
*/
public static Map<String, Map<String, String>> getDoneListById(DruidDataSource dataSource, List<String> idList)
throws SQLException{
Map<String,Map<String, String>> ret = new HashMap<String, Map<String, String>>();
String fragment = LocalSysReadHandler.buildSQLFragment(idList);
if(StringUtils.isNotEmpty(fragment)){
String fieldArray[] = new String[] {"send_id", "send_title", "user_notion", "view_url", "keyword", "relation_id", "relation_table", "relation_key", "notion_date"};
String filedStr = StringUtil.join(fieldArray, ",");
String sql = "select "+filedStr+" from doc_send where send_id in ("+fragment+")";
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, String> cur = new HashMap<String, String>();
for(int ix = 0; ix < fieldArray.length; ++ ix) {
String field = fieldArray[ix];
String val = rs.getString(field);
cur.put(field, val);
}
ret.put(cur.get("send_id"), cur);
}
}
} catch (SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
}
return ret;
}
//构建SQL语句片段
private static String buildSQLFragment(List<String> idList) {
StringBuffer fragment = new StringBuffer();
int size = idList.size();
for(int ix = 0; ix < size; ++ ix) {
if(ix != 0)
fragment.append(",");
fragment.append("'"+idList.get(ix)+"'");
}
return fragment.toString();
}
}
package com.sinobase.project.module.docsend.dao;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.common.utils.spring.SpringUtils;
import com.sinobase.datasource.aspectj.lang.enums.DataSourceType;
import com.sinobase.datasource.source.DynamicDataSourceContextHolder;
import com.sinobase.oldoa.util.Cp30Datasource;
import com.sinobase.project.system.user.domain.User;
import org.apache.commons.dbutils.QueryRunner;
import org.apache.poi.util.StringUtil;
import javax.sql.DataSource;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import java.text.SimpleDateFormat;
import java.util.*;
public class RemoteSysReadHandler {
public static final String SOURCE = "old";
public static QueryRunner qr = new QueryRunner(Cp30Datasource.getDataSource());
static List<Map<String, Object>> getNotIndexedRemote(Date latestTime)
throws SQLException {
User user = ShiroUtils.getSysUser();
List<Map<String, Object>> resultList = new ArrayList<Map<String, Object>>();
DynamicDataSourceContextHolder.setDataSourceType(DataSourceType.ORACLE.name());
DataSource dataSource = (DataSource) SpringUtils.getBean("dynamicDataSource");
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
// format.setTimeZone(TimeZone.getTimeZone("GMT+8:00"));
String sql = "select send_id, TO_DATE(notion_date, 'yyyy-mm-dd hh24:mi:ss') as doomsday,in_user_id,send_title,user_notion from doc_send " +
" where (in_user_id='"+user.getUserId()+"' or in_user_id='"+user.getHistoryId()+"') and" +
" TO_DATE(notion_date, 'yyyy-mm-dd hh24:mi:ss') > TO_DATE('"+format.format(latestTime)+"', 'yyyy-mm-dd hh24:mi:ss') and see_flag='1' and keyword!='退文' and keyword!='收回'"+
" order by TO_DATE(notion_date, 'yyyy-mm-dd hh24:mi:ss') desc";
List<Map<String, Object>> list = new ArrayList<>();
Connection conn = null;
Statement stmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
stmt = conn.createStatement();
rs = stmt.executeQuery(sql);
getValue(conn,stmt,rs,resultList);
} catch (Exception e) {
e.printStackTrace();
}finally{
rs.close();
stmt.close();
conn.close();
DynamicDataSourceContextHolder.clearDataSourceType();
}
return resultList;
}
private static void getValue(Connection conn,Statement stmt,ResultSet rs,List<Map<String, Object>> resultList) throws Exception{
User user = ShiroUtils.getSysUser();
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
if(null != rs) {
while (rs.next()) {
Map<String, Object> temp = new HashMap<String, Object>();
String id = parseString(rs.getString("send_id"));
Date doomsday = format.parse(parseString(rs.getString("doomsday")));
String userid = parseString(rs.getString("in_user_id"));
String title = parseString(rs.getString("send_title"));
String number = parseString(rs.getString("user_notion"));
temp.put("id", id);
temp.put("doomsday", doomsday);
temp.put("userid", userid);
temp.put("title", title);
temp.put("number", number);
temp.put("source", RemoteSysReadHandler.SOURCE);
resultList.add(temp);
}
}
DynamicDataSourceContextHolder.clearDataSourceType();
}
private static String parseString(Object obj) {
String ret = "";
if(obj != null)
ret = obj.toString();
return ret;
}
public static synchronized Map<String, Map<String, String>> getDoneListById(List<String> idList)
throws SQLException {
Map<String,Map<String, String>> ret = new HashMap<String, Map<String, String>>();
String fragment = RemoteSysReadHandler.buildSQLFragment(idList);
if(StringUtils.isNotEmpty(fragment)){
DynamicDataSourceContextHolder.setDataSourceType(DataSourceType.ORACLE.name());
DataSource dataSource = (DataSource) SpringUtils.getBean("dynamicDataSource");
Connection conn = null;
Statement stmt = null;
ResultSet rs = null;
String fieldArray[] = new String[] {"send_id", "send_title", "user_notion", "view_url", "keyword", "relation_id", "relation_table", "relation_key", "notion_date"};
String filedStr = StringUtil.join(fieldArray, ",");
String sql = "select "+filedStr+" from doc_send where send_id in ("+fragment+")";
List<Map<String, Object>> list = new ArrayList<>();
try {
conn = dataSource.getConnection();
stmt = conn.createStatement();
rs = stmt.executeQuery(sql);
getValue(conn,stmt,rs,ret,fieldArray);
} catch (Exception e) {
e.printStackTrace();
}finally{
rs.close();
stmt.close();
conn.close();
DynamicDataSourceContextHolder.clearDataSourceType();
}
}
return ret;
}
private static void getValue(Connection conn,Statement stmt,ResultSet rs,Map<String,Map<String, String>> ret,String[] fieldArray) throws Exception{
if(null != rs) {
while (rs.next()) {
Map<String, String> cur = new HashMap<String, String>();
for(int i = 0; i < fieldArray.length; ++ i) {
String field = fieldArray[i];
String val = parseString(rs.getString(field));
cur.put(field, val);
}
ret.put(rs.getString("send_id"), cur);
}
}
DynamicDataSourceContextHolder.clearDataSourceType();
}
//构建SQL语句片段
private static String buildSQLFragment(List<String> idList) {
StringBuffer fragment = new StringBuffer();
int size = idList.size();
for(int ix = 0; ix < size; ++ ix) {
if(ix != 0)
fragment.append(",");
fragment.append("'"+idList.get(ix)+"'");
}
return fragment.toString();
}
}
package com.sinobase.project.module.docsend.service;
import java.util.List;
import java.util.Map;
public interface IReadExtranetService {
/**
* 获取已阅分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return 整页待办数据
*/
public List<Map<String, String>> docSendList(int pageNumber, int countPerPage, String type, String title, String number);
/**
* 获取已阅数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
public int getPageCount(int count);
/**
* 获取登录人所有记录数
* @return
*/
public int getIndexCount(String title, String number);
}
package com.sinobase.project.module.docsend.service;
import java.util.List;
import java.util.Map;
public interface IReadService {
/**
* 获取已阅分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return 整页待办数据
*/
public List<Map<String, String>> docSendList(int pageNumber, int countPerPage,String type,String title,String number);
/**
* 获取已阅数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
public int getPageCount(int count);
/**
* 获取登录人所有记录数
* @return
*/
public int getIndexCount(String title,String number);
}
package com.sinobase.project.module.docsend.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.project.module.docsend.dao.LocalSysReadHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
@Service
public class ReadExtranetServiceImpl implements IReadExtranetService {
@Autowired
private DruidDataSource dataSource;
@Override
public List<Map<String, String>> docSendList(int pageNumber, int countPerPage,String type,String title,String number) {
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
try{
if(type.equals("table")){
ret = LocalSysReadHandler.getDoneList(dataSource, 0, 0,title,number);
}else{
ret = LocalSysReadHandler.getDoneList(dataSource, pageNumber, countPerPage,title,number);
}
}catch(Exception e){
e.printStackTrace();
}
return ret;
}
@Override
public int getPageCount(int count) {
int indexCount = 0;
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
try{
ret = LocalSysReadHandler.getDoneList(dataSource, 0, 0,null,null);
indexCount = ret.size();
}catch(Exception e){
e.printStackTrace();
}
// 计算页数并返回
int pageCount = indexCount / count;
if(0 != indexCount % count)
++ pageCount;
return pageCount;
}
@Override
public int getIndexCount(String title,String number) {
int indexCount = 0;
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
try{
ret = LocalSysReadHandler.getDoneList(dataSource, 0, 0,title,number);
indexCount = ret.size();
}catch(Exception e){
e.printStackTrace();
}
return indexCount;
}
}
package com.sinobase.project.module.docsend.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.project.module.docsend.dao.IndexReadHandler;
import com.sinobase.project.module.docsend.dao.LocalSysReadHandler;
import com.sinobase.project.module.docsend.dao.RemoteSysReadHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.sql.SQLException;
import java.util.*;
@Service
public class ReadServiceImpl implements IReadService {
@Autowired
private DruidDataSource dataSource;
@Override
public List<Map<String, String>> docSendList(int pageNumber, int countPerPage,String type,String title,String number) {
// step.1 刷新待阅索引的数据
//IndexHandler.refreshIndex(dataSource);
// step.2 通过分页的形式查询索引表
List<Map<String, Object>> pagingList = new ArrayList<Map<String,Object>>();
if(type.equals("table")){
pagingList = IndexReadHandler.paging(dataSource);
}else{
pagingList = IndexReadHandler.paging(dataSource, pageNumber, countPerPage,title,number);
}
// step.3 根据分页表中的id和source_system字段,分别调用LocalSystemHandler和RemoteSysHandler类中的查询方法
List<String> localIds = new ArrayList<String>(); //本系统待办表中的ID集合
List<String> remoteOldIds = new ArrayList<String>(); //老系统待办表中的ID集合
for(int ix = 0; ix < pagingList.size(); ++ ix) {
Map<String, Object> cur = pagingList.get(ix);
String id = cur.get("id").toString();
String source = cur.get("source").toString();
switch(source) {
case LocalSysReadHandler.SOURCE:
localIds.add(id);
break;
case RemoteSysReadHandler.SOURCE:
remoteOldIds.add(id);
break;
}
}
Map<String, Map<String, String>> localDone = new HashMap<>();
Map<String, Map<String, String>> remoteOldDone = new HashMap<>();
try {
localDone = LocalSysReadHandler.getDoneListById(dataSource, localIds);
remoteOldDone = RemoteSysReadHandler.getDoneListById(remoteOldIds);
} catch (SQLException throwables) {
throwables.printStackTrace();
}
// step.4 把两个来源的数据进行排序操作,并返回
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
for(int ix = 0; ix < pagingList.size(); ++ ix) {
Map<String, Object> pMap = pagingList.get(ix);
String id = pMap.get("id").toString();
String source = pMap.get("source").toString();
Map<String, String> cur = null;
switch(source) {
case LocalSysReadHandler.SOURCE:
cur = localDone.get(id);
if(null != cur){
cur.put("source",LocalSysReadHandler.SOURCE);
}
break;
case RemoteSysReadHandler.SOURCE:
cur = remoteOldDone.get(id);
if(null != cur){
cur.put("source",RemoteSysReadHandler.SOURCE);
}
break;
}
if(null != cur)
ret.add(cur);
}
return ret;
}
@Override
public int getPageCount(int count) {
// step.1 刷新待办索引的数据
IndexReadHandler.refreshIndex(dataSource);
// step.2 查出待办索引表的数据量count(1)
int indexCount = 0;
try {
indexCount = IndexReadHandler.getIndexCount(dataSource,"","");
} catch (SQLException throwables) {
throwables.printStackTrace();
}
// step.3 计算页数并返回
int pageCount = indexCount / count;
if(0 != indexCount % count)
++ pageCount;
return pageCount;
}
@Override
public int getIndexCount(String title,String number) {
// step.1 刷新待办索引的数据
IndexReadHandler.refreshIndex(dataSource);
// step.2 查出待办索引表的数据量count(1)
int indexCount = 0;
try {
indexCount = IndexReadHandler.getIndexCount(dataSource,title,number);
} catch (SQLException throwables) {
throwables.printStackTrace();
}
return indexCount;
}
}
# 获取已办数据信息
因为新旧系统同时运行,所以已办信息存在于MySQL和Oracle两个数据库中。
列表显示已办数据时,要把两个库的数据综合在一起做一个排序。
## 代码结构
`controller`
* `DoneController.java` 供前端请求的controller类
`service`
* `IDoneService.java` 获取已办相关信息的Service接口
* `DoneServiceImpl.java` 获取已办相关信息的Service实现类
`dao`
* `LocalSysHandler.java` 本地已办数据的查询方法类
* `RemoteSysHandler.java` 旧(其它)系统已办数据的方法类
`tools`
* 工具类,包含httpClient、排序算法等(用不上了,老系统的数据也在本地开发,无需http请求)
数据库表没建JavaBean,数据存储到Map中,字段名分别为:`id``doomsday``source`
> 本系统中的source值为 `local`
> 老系统中source值为 `old`
## 数据库
在数据库中建立了一个 *索引表* 用于存储两个系统中所有的已办信息ID和时间,用于排序。
```
drop table if exists sys_done_index;
create table sys_done_index
(
`id` varchar(50) NOT NULL,
`doomsday` datetime NOT NULL,
`source_system` varchar(50) NOT NULL,
primary key (`id`)
);
```
\ No newline at end of file
package com.sinobase.project.module.done.controller;
import com.github.pagehelper.PageHelper;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.framework.web.controller.BaseController;
import com.sinobase.framework.web.page.PageDomain;
import com.sinobase.framework.web.page.TableDataInfo;
import com.sinobase.framework.web.page.TableSupport;
import com.sinobase.project.module.done.service.IDoneExtranetService;
import com.sinobase.project.module.done.service.IDoneService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping("/done")
public class DoneController extends BaseController {
@Autowired
private IDoneService doneService;
@Autowired
private IDoneExtranetService doneExtranetService;
@Value("${sinobase.isIntranet}")
private boolean isIntranet;
/**
* 获取已办分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return json型式的整页待办数据
*/
@RequestMapping("/list/{pageNumber}/{countPerPage}")
@ResponseBody
public List<Map<String, String>> getDoneList(@PathVariable int pageNumber, @PathVariable int countPerPage){
int pageCount = 0;
if(isIntranet){
pageCount = doneService.getPageCount(countPerPage);
}else{
pageCount = doneExtranetService.getPageCount(countPerPage);
}
List<Map<String, String>> doneList = null;
if(pageNumber <= pageCount) {
if(isIntranet){
doneList = doneService.doneList(pageNumber, countPerPage,"self","");
}else{
doneList = doneExtranetService.doneList(pageNumber, countPerPage,"self","");
}
}
return doneList;
}
/**
* 获取列表信息
* @return
*/
@RequestMapping("/tablelist")
@ResponseBody
public TableDataInfo getDoneTableList(String title,String number){
PageDomain pageDomain = TableSupport.buildPageRequest();
Integer pageNum = pageDomain.getPageNum();
Integer pageSize = pageDomain.getPageSize();
if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
String orderBy = pageDomain.getOrderBy();
PageHelper.startPage(pageNum, pageSize, orderBy);
}
int indexCount = 0;
List<Map<String, String>> doneList = null;
if(isIntranet){
indexCount = doneService.getIndexCount(title);
doneList = doneService.doneList(pageNum, pageSize,"self",title);
}else{
indexCount = doneExtranetService.getIndexCount(title);
doneList = doneExtranetService.doneList(pageNum, pageSize,"self",title);
}
TableDataInfo rspData = new TableDataInfo();
rspData.setCode(0);
rspData.setRows(doneList);
rspData.setTotal(indexCount);
return rspData;
}
/**
* 获取已办数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
@RequestMapping("/page_count/{count}")
@ResponseBody
public int getPageCount(@PathVariable int count) {
int pageCount = 0;
if(isIntranet){
pageCount = doneService.getPageCount(count);
}else{
pageCount = doneExtranetService.getPageCount(count);
}
return pageCount;
}
/**
* 获取已办理文件数
* @return
*/
@RequestMapping("/getFileCount")
@ResponseBody
public int getFileCount() {
int fileCount = 0;
if(isIntranet){
fileCount = doneService.getIndexCount("");
}else{
fileCount = doneExtranetService.getIndexCount("");
}
return fileCount;
}
}
package com.sinobase.project.module.done.dao;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.system.user.domain.User;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.sql.*;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.*;
public class IndexHandler {
private static final Logger log = LoggerFactory.getLogger(IndexHandler.class);
/**
* 刷新已办索引数据
* @param dataSource
* @return
*/
public static synchronized boolean refreshIndex(DruidDataSource dataSource) {
System.out.println("mysql 当前连接数:"+dataSource.getActiveCount());
boolean result = true;
//step.1 查询索引表最新的日期
Date latestTime = new Date();
List<Map<String, Object>> localList = new ArrayList<Map<String, Object>>();
List<Map<String, Object>> remoteList = new ArrayList<Map<String, Object>>();
try {
System.out.println("step.1 查询索引表最新的日期--------begin");
latestTime = IndexHandler.getLatestOfIndex(dataSource);
System.out.println("step.1 查询索引表最新的日期--------end");
} catch (SQLException e) {
result = false;
e.printStackTrace();
}
try {
//step.2 根据第一步的时间查询出本地缺少的已办数据
System.out.println("step.2 根据第一步的时间查询出本地缺少的已办数据--------begin");
localList = LocalSysHandler.getNotIndexedLocal(dataSource, latestTime);
System.out.println("step.2 根据第一步的时间查询出本地缺少的已办数据--------end");
//step.3 根据第一步的时间查询出远程缺少的已办数
System.out.println("step.3 根据第一步的时间查询出远程缺少的已办数--------begin");
remoteList = RemoteSysHandler.getNotIndexedRemote(latestTime);
System.out.println("step.3 根据第一步的时间查询出远程缺少的已办数--------end");
} catch (SQLException e) {
e.printStackTrace();
}
//step.4 把第二、三步查出来的数据插入到索引表当中(分批执行,每次执行1000条)
System.out.println("step.4 把第二、三步查出来的数据插入到索引表当中(分批执行,每次执行1000条)--------begin");
int bufferSize = 1000;
List<String> sqlList = new LinkedList<String>(); //切割后的批量插入sql语句集合
List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();
list.addAll(localList);
list.addAll(remoteList);
do {
List<Map<String, Object>> tempList = new ArrayList<Map<String, Object>>();
if(list.size() > bufferSize) {
tempList = list.subList(0, bufferSize - 1);
}else {
tempList = list;
}
String sqlFragment = IndexHandler.buildSQLFragment(tempList);
String sql = IndexHandler.buildSQLStatement(sqlFragment);
if(null != sql && !"".equals(sql.trim()))
sqlList.add(sql);
tempList.clear();
}while(list.size() != 0);
try {
IndexHandler.queryInsert4Index(dataSource, sqlList);
} catch (SQLException e) {
e.printStackTrace();
}
System.out.println("step.4 把第二、三步查出来的数据插入到索引表当中(分批执行,每次执行1000条)--------end");
return result;
}
/**
* 从已办索引中获取已办数量
* @param dataSource
* @return
*/
public static int getIndexCount(DruidDataSource dataSource,String title)
throws SQLException{
User user = ShiroUtils.getSysUser();
int count = 0;
String sql = "select count(1) as count from sys_done_index d " +
" INNER JOIN ( SELECT i.userid AS userid, i.recordid AS recordid, max(i.doomsday) AS doomsday " +
" FROM sys_done_index i WHERE userid IN ( '"+user.getUserId()+"' , '"+user.getHistoryId()+"') " +
" GROUP BY i.userid, i.recordid ) dd ON dd.recordid = d.recordid AND dd.doomsday = d.doomsday " +
" where d.userid in ( '"+user.getUserId()+"' , '"+user.getHistoryId()+"') ";
if(StringUtils.isNotEmpty(title)){
sql += " and d.title like '%"+title+"%'";
}
Logger logger = LoggerFactory.getLogger(RemoteSysHandler.class);
logger.debug(sql);
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs && rs.next()) {
count = rs.getInt("count");
}
} catch (SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
return count;
}
/**
* 从已办列表中获取分页数据
* @param dataSource
* @param pageNumber
* @param countPerPage
* @return
*/
public static List<Map<String, Object>> paging(DruidDataSource dataSource, int pageNumber, int countPerPage,String title)
throws SQLException{
User user = ShiroUtils.getSysUser();
String sql = "SELECT d.id,max(d.doomsday) AS doomsday, d.userid,d.source_system FROM sys_done_index d " +
" INNER JOIN ( SELECT i.userid AS userid, i.recordid AS recordid, max(i.doomsday) AS doomsday " +
" FROM sys_done_index i WHERE userid IN ( '"+user.getUserId()+"' , '"+user.getHistoryId()+"' )" +
" GROUP BY i.userid, i.recordid ) dd ON dd.recordid = d.recordid AND dd.doomsday = d.doomsday " +
" where d.userid in ( '"+user.getUserId()+"' , '"+user.getHistoryId()+"') ";
if(StringUtils.isNotEmpty(title)){
sql += " and d.title like '%"+title+"%'";
}
sql += " group by d.recordid,d.userid,d.id,d.source_system order by str_to_date(d.doomsday,'%Y-%m-%d %H:%i:%s') desc limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
List<Map<String, Object>> ret = new LinkedList<Map<String, Object>>();
Logger logger = LoggerFactory.getLogger(RemoteSysHandler.class);
logger.debug(sql);
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, Object> map = new HashMap<String, Object>();
String id = rs.getString("id");
Date doomsday = new Date(rs.getTimestamp("doomsday").getTime());
String userid = rs.getString("userid");
String source = rs.getString("source_system");
map.put("id", id);
map.put("doomsday", doomsday);
map.put("userid", userid);
map.put("source", source);
ret.add(map);
}
}
} catch (SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
/**
* 获取所有的已办
* @param dataSource
* @return
*/
public static List<Map<String, Object>> paging(DruidDataSource dataSource)
throws SQLException{
User user = ShiroUtils.getSysUser();
String sql = "select id,doomsday,userid,source_system from sys_done_index as b where not exists(select 1 from sys_done_index where recordid= b.recordid and b.doomsday<doomsday ) and " +
"(userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"') order by str_to_date(doomsday,'%Y-%m-%d %H:%i:%s') desc ";
List<Map<String, Object>> ret = new LinkedList<Map<String, Object>>();
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, Object> map = new HashMap<String, Object>();
String id = rs.getString("id");
Date doomsday = new Date(rs.getTimestamp("doomsday").getTime());
String userid = rs.getString("userid");
String source = rs.getString("source_system");
map.put("id", id);
map.put("doomsday", doomsday);
map.put("userid", userid);
map.put("source", source);
ret.add(map);
}
}
} catch (SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
//获取当前索引表中最近的时间
private static Date getLatestOfIndex(DruidDataSource dataSource)
throws SQLException {
User user = ShiroUtils.getSysUser();
String sql = "select id,doomsday,source_system from sys_done_index where (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"') order by doomsday desc limit 1";
System.out.println("getLatestOfIndex "+sql);
Date latestOfIndex = new Date();
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
try {
latestOfIndex = sdf.parse("1970-01-01 08:00:00");
} catch (ParseException e1) {
e1.printStackTrace();
}
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs && rs.next()) {
latestOfIndex = new Date(rs.getTimestamp("doomsday").getTime());
}
} catch(SQLException e) {
e.printStackTrace();
} finally {
rs.close();
pstmt.close();
conn.close();
}
return latestOfIndex;
}
//向已办索引表插入已办数据
private static void queryInsert4Index(DruidDataSource dataSource, List<String> sqlList)
throws SQLException {
Connection conn = null;
Statement stmt = null;
try{
conn = dataSource.getConnection();
stmt = conn.createStatement();
int sqlSize = sqlList.size();
for(int ix = 0; ix < sqlSize; ++ ix) { //直接遍历执行所有sql语句,按理说应该不需要sleep
String sql = sqlList.get(ix);
stmt.executeUpdate(sql);
}
}catch (Exception e){
e.printStackTrace();
}finally {
stmt.close();
conn.close();
}
}
//构建SQL语句片段
private static String buildSQLFragment(List<Map<String, Object>> list) {
StringBuffer fragment = new StringBuffer("");
int size = list.size();
for(int ix = 0; ix < size; ++ ix) {
Map<String, Object> cur = list.get(ix);
String id = parseString(cur.get("id"));
String doomsday = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format((Date)cur.get("doomsday"));
String userid = parseString(cur.get("userid"));
String title = cur.get("title")!=null?parseString(cur.get("title")).replaceAll("'","\\\\'"):"";
String recordid = cur.get("recordid")!=null?parseString(cur.get("recordid")):"";
String source = parseString(cur.get("source"));
if(0 != ix) {
fragment.append(",");
}
fragment.append("('"+id+"','"+doomsday+"','"+userid+"','"+title+"','"+recordid+"','"+source+"')");
}
return fragment.toString();
}
//将SQL语句片段构建成完整语句
private static String buildSQLStatement(String fragment) {
String sql = "";
if(null != fragment && !"".equals(fragment.trim())) {
sql = "insert into sys_done_index (id,doomsday,userid,title,recordid,source_system) values " + fragment;
}
return sql;
}
private static String parseString(Object obj) {
String ret = "";
if(obj != null)
ret = obj.toString();
return ret;
}
}
package com.sinobase.project.module.done.dao;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.system.user.domain.User;
import org.apache.poi.util.StringUtil;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.text.SimpleDateFormat;
import java.util.*;
public class LocalSysHandler {
public static final String SOURCE = "local";
private static final Logger log = LoggerFactory.getLogger(LocalSysHandler.class);
/**
* 外网直接获取mysql中已办数据
* @param dataSource
* @param pageNumber
* @param countPerPage
* @param title
* @return
* @throws SQLException
*/
public static List<Map<String, String>> getDoneList(DruidDataSource dataSource,int pageNumber,int countPerPage,String title)
throws SQLException{
User user = ShiroUtils.getSysUser();
List<Map<String, String>> ret = new ArrayList<Map<String, String>>();
String fieldArray[] = new String[] {"id", "title", "filetypeid", "filetypename", "workflowid", "workflowname", "recordid", "readtime","handdoneurl","docid"};
String filedStr = StringUtil.join(fieldArray, ",");
String sql = "select "+filedStr+" from flow_read_new as b where not exists(select 1 from flow_read_new where userid=b.userid and recordid= b.recordid " +
"and b.readtime<readtime ) and (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"')";
if(StringUtils.isNotEmpty(title)){
sql += " and title like '%"+title+"%'";
}
sql += " order by str_to_date(readtime,'%Y-%m-%d %H:%i:%s') desc ";
System.out.println("已办 sql "+sql);
if(pageNumber!=0&&countPerPage!=0){
sql += "limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
}
log.debug("flow_read_new:"+sql);
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, String> cur = new HashMap<String, String>();
for(int ix = 0; ix < fieldArray.length; ++ ix) {
String field = fieldArray[ix];
String val = rs.getString(field);
cur.put(field, val);
}
ret.add(cur);
}
}
} catch (SQLException e) {
e.printStackTrace();
}finally{
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
/**
* 从已办表中查询一个时间点到当前时间的数据
* @param dataSource
* @param latestTime
* @return
* @throws SQLException
*/
static List<Map<String, Object>> getNotIndexedLocal(DruidDataSource dataSource, Date latestTime)
throws SQLException{
User user = ShiroUtils.getSysUser();
String time = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(latestTime);
List<Map<String, Object>> ret = new ArrayList<Map<String, Object>>(); //ArrayList即可,无需排序
String sql = "select id, str_to_date(readtime, '%Y-%m-%d %H:%i:%s') as doomsday,userid,title,recordid " +
" from flow_read_new as b where not EXISTS( select 1 from flow_read_new where userid=b.userid and recordid= b.recordid" +
" and b.readtime<readtime ) and (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"') and " +
" str_to_date(readtime, '%Y-%m-%d %H:%i:%s') > str_to_date('"+time+"', '%Y-%m-%d %H:%i:%s')" +
" order by str_to_date(readtime, '%Y-%m-%d %H:%i:%s') desc";
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
System.out.println("getNotIndexedLocal "+sql);
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, Object> temp = new HashMap<String, Object>();
String id = rs.getString("id");
Date doomsday = new Date(rs.getTimestamp("doomsday").getTime());
String userid = rs.getString("userid");
String title = rs.getString("title");
String recordid = rs.getString("recordid");
temp.put("id", id);
temp.put("doomsday", doomsday);
temp.put("userid", userid);
temp.put("title", title);
temp.put("recordid", recordid);
temp.put("source", LocalSysHandler.SOURCE);
ret.add(temp);
}
}
} catch(SQLException e) {
e.printStackTrace();
}finally{
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
/**
* 根据已办ID批量获取已办信息(不排序)
* @param dataSource
* @param idList
* @return
*/
public static Map<String, Map<String, String>> getDoneListById(DruidDataSource dataSource, List<String> idList)
throws SQLException{
Map<String,Map<String, String>> ret = new HashMap<String, Map<String, String>>();
String fragment = LocalSysHandler.buildSQLFragment(idList);
if(StringUtils.isNotEmpty(fragment)){
String fieldArray[] = new String[] {"id", "title", "filetypeid", "filetypename", "workflowid", "workflowname", "recordid", "readtime","handdoneurl","docid"};
String filedStr = StringUtil.join(fieldArray, ",");
String sql = "select "+filedStr+" from flow_read_new where id in ("+fragment+")";
log.debug("flow_read_new:"+sql);
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
conn = dataSource.getConnection();
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, String> cur = new HashMap<String, String>();
for(int ix = 0; ix < fieldArray.length; ++ ix) {
String field = fieldArray[ix];
String val = rs.getString(field);
cur.put(field, val);
}
ret.put(cur.get("id"), cur);
}
}
} catch (SQLException e) {
e.printStackTrace();
} finally{
rs.close();
pstmt.close();
conn.close();
}
}
return ret;
}
//构建SQL语句片段
private static String buildSQLFragment(List<String> idList) {
StringBuffer fragment = new StringBuffer();
int size = idList.size();
for(int ix = 0; ix < size; ++ ix) {
if(ix != 0)
fragment.append(",");
fragment.append("'"+idList.get(ix)+"'");
}
return fragment.toString();
}
}
package com.sinobase.project.module.done.dao;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.common.utils.spring.SpringUtils;
import com.sinobase.datasource.aspectj.lang.enums.DataSourceType;
import com.sinobase.datasource.source.DynamicDataSourceContextHolder;
import com.sinobase.project.system.user.domain.User;
import org.apache.poi.util.StringUtil;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import javax.sql.DataSource;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import java.text.SimpleDateFormat;
import java.util.*;
public class RemoteSysHandler {
public static final String SOURCE = "old";
private static final Logger log = LoggerFactory.getLogger(RemoteSysHandler.class);
static List<Map<String, Object>> getNotIndexedRemote(Date latestTime)
throws SQLException {
User user = ShiroUtils.getSysUser();
List<Map<String, Object>> resultList = new ArrayList<Map<String, Object>>();
DynamicDataSourceContextHolder.setDataSourceType(DataSourceType.ORACLE.name());
DataSource dataSource = (DataSource) SpringUtils.getBean("dynamicDataSource");
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
// format.setTimeZone(TimeZone.getTimeZone("GMT+8:00"));
String sql = "select id, TO_DATE(readtime, 'yyyy-mm-dd hh24:mi:ss') as doomsday,userid,title,recordid from flow_read " +
" where (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"') and TO_DATE(readtime, 'yyyy-mm-dd hh24:mi:ss') > TO_DATE('"+format.format(latestTime)+"', 'yyyy-mm-dd hh24:mi:ss')"+
" order by TO_DATE(readtime, 'yyyy-mm-dd hh24:mi:ss') desc";
log.debug(sql);
Connection conn = null;
Statement stmt = null;
ResultSet rs = null;
System.out.println("getNotIndexedRemote "+sql);
try {
conn = dataSource.getConnection();
stmt = conn.createStatement();
rs = stmt.executeQuery(sql);
getValue(conn,stmt,rs,resultList);
} catch (Exception e) {
e.printStackTrace();
} finally {
rs.close();
stmt.close();
conn.close();
DynamicDataSourceContextHolder.clearDataSourceType();
}
return resultList;
}
private static void getValue(Connection conn,Statement stmt,ResultSet rs,List<Map<String, Object>> resultList) throws Exception{
User user = ShiroUtils.getSysUser();
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
if(null != rs) {
while (rs.next()) {
Map<String, Object> temp = new HashMap<String, Object>();
String id = parseString(rs.getString("id"));
Date doomsday = format.parse(parseString(rs.getString("doomsday")));
String userid = parseString(rs.getString("userid"));
String title = parseString(rs.getString("title"));
String recordid = parseString(rs.getString("recordid"));
temp.put("id", id);
temp.put("doomsday", doomsday);
temp.put("userid", userid);
temp.put("title", title);
temp.put("recordid", recordid);
temp.put("source", RemoteSysHandler.SOURCE);
resultList.add(temp);
}
}
DynamicDataSourceContextHolder.clearDataSourceType();
}
private static String parseString(Object obj) {
String ret = "";
if(obj != null)
ret = obj.toString();
return ret;
}
public static synchronized Map<String, Map<String, String>> getDoneListById(List<String> idList)
throws SQLException{
Map<String,Map<String, String>> ret = new HashMap<String, Map<String, String>>();
String fragment = RemoteSysHandler.buildSQLFragment(idList);
if(StringUtils.isNotEmpty(fragment)){
DynamicDataSourceContextHolder.setDataSourceType(DataSourceType.ORACLE.name());
DataSource dataSource = (DataSource) SpringUtils.getBean("dynamicDataSource");
Connection conn = null;
Statement stmt = null;
ResultSet rs = null;
String fieldArray[] = new String[] {"id", "title", "filetypeid", "filetypename", "workflowid", "workflowname", "recordid", "readtime","(select w.overdo_url||'&'||w.target_key||'=' from waitdo_config w where w.filetype_id=r.filetypeid and rownum=1) as readUrl"};
String fieldArray2[] = new String[] {"id", "title", "filetypeid", "filetypename", "workflowid", "workflowname", "recordid", "readtime","readUrl"};
String filedStr = StringUtil.join(fieldArray, ",");
String sql = "select "+filedStr+" from flow_read r where r.id in ("+fragment+")";
try {
conn = dataSource.getConnection();
stmt = conn.createStatement();
rs = stmt.executeQuery(sql);
getValue(conn,stmt,rs,ret,fieldArray2);
} catch (Exception e) {
e.printStackTrace();
}finally{
rs.close();
stmt.close();
conn.close();
DynamicDataSourceContextHolder.clearDataSourceType();
}
}
return ret;
}
private static void getValue(Connection conn,Statement stmt,ResultSet rs,Map<String,Map<String, String>> ret,String[] fieldArray2) throws Exception{
if(null != rs) {
while (rs.next()) {Map<String, String> cur = new HashMap<String, String>();
for(int i = 0; i < fieldArray2.length; ++ i) {
String field = fieldArray2[i];
String val = parseString(rs.getString(field));
cur.put(field, val);
}
ret.put(rs.getString("id"), cur);
}
}
DynamicDataSourceContextHolder.clearDataSourceType();
}
//构建SQL语句片段
private static String buildSQLFragment(List<String> idList) {
StringBuffer fragment = new StringBuffer();
int size = idList.size();
for(int ix = 0; ix < size; ++ ix) {
if(ix != 0)
fragment.append(",");
fragment.append("'"+idList.get(ix)+"'");
}
return fragment.toString();
}
}
package com.sinobase.project.module.done.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.project.module.done.dao.LocalSysHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
@Service
public class DoneExtranetServiceImpl implements IDoneExtranetService {
@Autowired
private DruidDataSource dataSource;
@Override
public List<Map<String, String>> doneList(int pageNumber, int countPerPage,String type,String title) {
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
try{
if(type.equals("table")){
ret = LocalSysHandler.getDoneList(dataSource,0,0,title);
}else{
ret = LocalSysHandler.getDoneList(dataSource,pageNumber,countPerPage,title);
}
}catch(Exception e){
e.printStackTrace();
}
return ret;
}
@Override
public int getPageCount(int count) {
int indexCount = 0;
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
try{
ret = LocalSysHandler.getDoneList(dataSource,0,0,"");
indexCount = ret.size();
}catch(Exception e){
e.printStackTrace();
}
// 计算页数并返回
int pageCount = indexCount / count;
if(0 != indexCount % count)
++ pageCount;
return pageCount;
}
@Override
public int getIndexCount(String title) {
int indexCount = 0;
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
try{
ret = LocalSysHandler.getDoneList(dataSource,0,0,title);
indexCount = ret.size();
}catch(Exception e){
e.printStackTrace();
}
return indexCount;
}
}
package com.sinobase.project.module.done.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.project.module.done.dao.IndexHandler;
import com.sinobase.project.module.done.dao.LocalSysHandler;
import com.sinobase.project.module.done.dao.RemoteSysHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.sql.SQLException;
import java.util.*;
@Service
public class DoneServiceImpl implements IDoneService {
@Autowired
private DruidDataSource dataSource;
@Override
public List<Map<String, String>> doneList(int pageNumber, int countPerPage,String type,String title) {
// step.1 刷新待办索引的数据
//IndexHandler.refreshIndex(dataSource);
// step.2 通过分页的形式查询索引表
List<Map<String, Object>> pagingList = new ArrayList<Map<String,Object>>();
try{
if(type.equals("table")){
pagingList = IndexHandler.paging(dataSource);
}else{
pagingList = IndexHandler.paging(dataSource, pageNumber, countPerPage, title);
}
}catch (Exception e){
e.printStackTrace();
}
// step.3 根据分页表中的id和source_system字段,分别调用LocalSystemHandler和RemoteSysHandler类中的查询方法
List<String> localIds = new ArrayList<String>(); //本系统待办表中的ID集合
List<String> remoteOldIds = new ArrayList<String>(); //老系统待办表中的ID集合
for(int ix = 0; ix < pagingList.size(); ++ ix) {
Map<String, Object> cur = pagingList.get(ix);
String id = cur.get("id").toString();
String source = cur.get("source").toString();
switch(source) {
case LocalSysHandler.SOURCE:
localIds.add(id);
break;
case RemoteSysHandler.SOURCE:
remoteOldIds.add(id);
break;
}
}
Map<String, Map<String, String>> localDone = new HashMap<>();
Map<String, Map<String, String>> remoteOldDone = new HashMap<>();
try {
localDone = LocalSysHandler.getDoneListById(dataSource, localIds);
remoteOldDone = RemoteSysHandler.getDoneListById(remoteOldIds);
} catch (SQLException throwables) {
throwables.printStackTrace();
}
// step.4 把两个来源的数据进行排序操作,并返回
List<Map<String, String>> ret = new LinkedList<Map<String,String>>();
for(int ix = 0; ix < pagingList.size(); ++ ix) {
Map<String, Object> pMap = pagingList.get(ix);
String id = pMap.get("id").toString();
String source = pMap.get("source").toString();
Map<String, String> cur = null;
switch(source) {
case LocalSysHandler.SOURCE:
cur = localDone.get(id);
break;
case RemoteSysHandler.SOURCE:
cur = remoteOldDone.get(id);
break;
}
if(null != cur)
ret.add(cur);
}
return ret;
}
@Override
public int getPageCount(int count) {
// step.1 刷新待办索引的数据
IndexHandler.refreshIndex(dataSource);
// step.2 查出待办索引表的数据量count(1)
int indexCount = 0;
try {
indexCount = IndexHandler.getIndexCount(dataSource,"");
} catch (SQLException throwables) {
throwables.printStackTrace();
}
// step.3 计算页数并返回
int pageCount = indexCount / count;
if(0 != indexCount % count)
++ pageCount;
return pageCount;
}
@Override
public int getIndexCount(String title) {
// step.1 刷新待办索引的数据
IndexHandler.refreshIndex(dataSource);
// step.2 查出待办索引表的数据量count(1)
int indexCount = 0;
try {
indexCount = IndexHandler.getIndexCount(dataSource,title);
} catch (SQLException throwables) {
throwables.printStackTrace();
}
return indexCount;
}
}
package com.sinobase.project.module.done.service;
import java.util.List;
import java.util.Map;
public interface IDoneExtranetService {
/**
* 获取已办分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return 整页待办数据
*/
public List<Map<String, String>> doneList(int pageNumber, int countPerPage, String type, String title);
/**
* 获取已办数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
public int getPageCount(int count);
/**
* 获取登录人所有记录数
* @return
*/
public int getIndexCount(String title);
}
package com.sinobase.project.module.done.service;
import java.util.List;
import java.util.Map;
public interface IDoneService {
/**
* 获取已办分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return 整页待办数据
*/
public List<Map<String, String>> doneList(int pageNumber, int countPerPage,String type,String title);
/**
* 获取已办数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
public int getPageCount(int count);
/**
* 获取登录人所有记录数
* @return
*/
public int getIndexCount(String title);
}
package com.sinobase.project.module.homepage.mapper;
import java.util.Map;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
/**
* 首页操作层通用
* @author liuhui
*/
@Repository
public interface HomePageMapper {
/**
* 获取通知信息
* @param recordid
* @return
*/
public Map<String, String> getTongZhiById(@Param("recordid") String recordid);
}
package com.sinobase.project.module.homepage.service;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.sinobase.project.module.homepage.mapper.HomePageMapper;
/**
*
* 首页获取信息专用service层,替换原先的service层方法
*
* @author liuhui001
*
*/
@Service
public class HomePageSeriveImpl implements IHomePageSerive{
@Autowired
private HomePageMapper pageMapper;
@Override
public Map<String, String> getTongZhiById(String recordid) {
return pageMapper.getTongZhiById(recordid);
}
}
package com.sinobase.project.module.homepage.service;
import java.util.Map;
/**
*
* 首页获取信息专用service层,替换原先的service层方法
*
* @author liuhui001
*
*/
public interface IHomePageSerive {
/**
* 获取通知信息
* @param recordid
* @return
*/
public Map<String, String> getTongZhiById(String recordid);
}
package com.sinobase.project.module.toberead.comtroller;
import com.github.pagehelper.PageHelper;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.framework.web.controller.BaseController;
import com.sinobase.framework.web.domain.AjaxResult;
import com.sinobase.framework.web.page.PageDomain;
import com.sinobase.framework.web.page.TableDataInfo;
import com.sinobase.framework.web.page.TableSupport;
import com.sinobase.project.module.toberead.service.ITobereadExtranetService;
import com.sinobase.project.module.toberead.service.ITobereadService;
import com.sinobase.project.system.user.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping("/toberead")
public class TobereadController extends BaseController {
@Autowired
ITobereadService tobereadService;
@Autowired
ITobereadExtranetService tobereadExtranetService;
@Value("${sinobase.isIntranet}")
private boolean isIntranet;
/**
* 获取待阅数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
@RequestMapping("/page_count/{count}")
@ResponseBody
public int getPageCount(@PathVariable int count) {
if(isIntranet){
return tobereadService.getPageCount(count);
}else{
return tobereadExtranetService.getPageCount(count);
}
}
/**
* 获取所有待阅数据的数量
* @return 待阅数量
*/
@RequestMapping("/count")
@ResponseBody
public int getCount() {
if(isIntranet){
return tobereadService.getCount();
}else{
return tobereadExtranetService.getCount();
}
}
/**
* 获取待办分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return json型式的整页待阅数据
*/
@RequestMapping("/list/{pageNumber}/{countPerPage}")
@ResponseBody
public Map<String,Object> getDoneList(@PathVariable int pageNumber, @PathVariable int countPerPage){
Map<String,Object> map = new HashMap<String,Object>();
User user = ShiroUtils.getSysUser();
if(isIntranet){
tobereadService.refreshIndex(user.getUserId());
map.put("list",tobereadService.getDoneList(pageNumber, countPerPage));
map.put("count",tobereadService.getCount());
}else{
map.put("list",tobereadExtranetService.getDoneList(pageNumber,countPerPage));
map.put("count",tobereadExtranetService.getCount());
}
return map;
}
/**
* 获取列表信息
* @return
*/
@RequestMapping("/tablelist")
@ResponseBody
public TableDataInfo getDoneTableList(){
PageDomain pageDomain = TableSupport.buildPageRequest();
Integer pageNum = pageDomain.getPageNum();
Integer pageSize = pageDomain.getPageSize();
if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
String orderBy = pageDomain.getOrderBy();
PageHelper.startPage(pageNum, pageSize, orderBy);
}
User user = ShiroUtils.getSysUser();
int indexCount = 0;
List<Object> doneList = null;
if(isIntranet){
tobereadService.refreshIndex(user.getUserId());
indexCount = tobereadService.getCount();
doneList = new ArrayList<Object>(tobereadService.getDoneList(pageNum, pageSize));
}else{
indexCount = tobereadExtranetService.getCount();
doneList = new ArrayList<Object>(tobereadExtranetService.getDoneList(pageNum,pageSize));
}
TableDataInfo rspData = new TableDataInfo();
rspData.setCode(0);
rspData.setRows(doneList);
rspData.setTotal(indexCount);
return rspData;
}
/**
* 批量阅毕
* @param ids
* @param dataSources
* @return
*/
@RequestMapping("/afterReading")
@ResponseBody
public AjaxResult afterReading(String ids,String dataSources){
String[] idArray = ids.split(",");
String[] dataSourceArray = dataSources.split(",");
for(int i=0;i<idArray.length;i++){
String id = idArray[i];
String dataSource = dataSourceArray[i];
if(isIntranet){
tobereadService.afterReading(id,dataSource);
}else{
tobereadExtranetService.afterReading(id,dataSource);
}
}
return super.success();
}
}
package com.sinobase.project.module.toberead.dao;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.module.toberead.model.Toberead;
import com.sinobase.project.system.portal.constant.MessageConstants;
import com.sinobase.project.system.user.domain.User;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
public class LocalTobereadHandler {
public static final String SOURCE = "local";
public static List<Toberead> getTodo(DruidDataSource dataSource,int pageNumber,int countPerPage)
throws SQLException{
User user = ShiroUtils.getSysUser();
List<Toberead> ret = new ArrayList<Toberead>();
String sql = "select id, title, url, receive_time,grant_user_id,from_user_name,0 as leaderInsNum,wait_handle_primary_key_value as relationId,wait_handle_table_name as relationTable from sys_message where grant_user_id LIKE '%"+user.getUserId()+
"%' and message_type='"+ MessageConstants.MESSAGE_TYPE_DOC_SEND_WAIT +"'";
sql += " order by receive_time desc";
if(pageNumber!=0&&countPerPage!=0){
sql += " limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
}
System.out.println("待阅 mysql "+sql);
Connection conn = dataSource.getConnection();
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Toberead cur = new Toberead();
cur.setId(rs.getString("id"));
cur.setTitle(rs.getString("title"));
cur.setUrl(rs.getString("url"));
cur.setFromUserName(rs.getString("from_user_name"));
cur.setLeaderInsNum(rs.getString("leaderInsNum"));
cur.setRelationId(rs.getString("relationId"));
cur.setRelationTable(rs.getString("relationTable"));
Date receiveTime = rs.getTimestamp("receive_time");
//TODO: 因为redis从小到大排序,所以考虑是不是要把时间载戳变成负数
cur.setReceiveTime(0-receiveTime.getTime());
cur.setDataSource(SOURCE);
ret.add(cur);
}
}
}catch(SQLException e) {
e.printStackTrace();
}finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
}
package com.sinobase.project.module.toberead.dao;
import com.sinobase.common.utils.DateUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.common.utils.spring.SpringUtils;
import com.sinobase.datasource.aspectj.lang.enums.DataSourceType;
import com.sinobase.datasource.source.DynamicDataSourceContextHolder;
import com.sinobase.project.module.toberead.model.Toberead;
import com.sinobase.project.system.user.domain.User;
import javax.sql.DataSource;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.Statement;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
public class RemoteTobereadHandler {
public static final String SOURCE = "old";
public static synchronized List<Toberead> getTodo(){
User user = ShiroUtils.getSysUser();
List<Toberead> ret = new ArrayList<Toberead>();
DynamicDataSourceContextHolder.setDataSourceType(DataSourceType.ORACLE.name());
DataSource dataSource = (DataSource) SpringUtils.getBean("dynamicDataSource");
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
String sql = "select send_id,send_title,view_url,cre_time,in_user_id,(select username from flow_user u where u.userid=t.cre_user_id) as fromusername," +
"case when (t.relation_table='YZ_ARCHIVES_IN')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_IN' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.relation_id )" +
" when (t.relation_table='YZ_ARCHIVES_OUT')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_OUT' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.relation_id )" +
" when (t.relation_table='YZ_ARCHIVES_SIGN')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_SIGN' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.relation_id )" +
" when (t.relation_table='YZ_ARCHIVES_SUMMARY')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_SUMMARY' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.relation_id )" +
" end as leaderInsNum,relation_id as relationId,relation_table as relationTable " +
" from doc_send t" +
" where t.is_GONGGAO is null and see_flag='0' and t.flag='1'";
sql += " and t.filing_cabinet_id is null and t.del_flag='1' " +
" and t.in_user_id='" + user.getHistoryId() + "' " +
"and t.relation_id not in (" +
"select t.NOTICE_ID from YZ_SDIC_NOTICEINFO t " +
"where t.USERID = '" + user.getHistoryId() + "' and t.STATUS = '1')" +
"and (case when relation_table = 'YZ_SDIC_WORKNOTICE'" +
" and exists( select 1 from YZ_SDIC_WORKNOTICE w where status = '2' and w.id=relation_id) then '1'" +
"when relation_table != 'YZ_SDIC_WORKNOTICE' then '1' else '0' end) = '1' order by t.cre_time desc";
System.out.println("待阅 oracle "+sql);
Connection conn = null;
Statement stmt = null;
ResultSet rs = null;
try{
conn = dataSource.getConnection();
stmt = conn.createStatement();
rs = stmt.executeQuery(sql);
getValue(conn,stmt,rs,ret);
}catch(Exception e){
e.printStackTrace();
}finally{
DynamicDataSourceContextHolder.clearDataSourceType();
}
return ret;
}
private static void getValue(Connection conn,Statement stmt,ResultSet rs,List<Toberead> ret) throws Exception{
User user = ShiroUtils.getSysUser();
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
if(null != rs) {
while (rs.next()) {
Toberead cur = new Toberead();
String id = parseString(rs.getString("send_id"));
String title = parseString(rs.getString("send_title"));
String url = parseString(rs.getString("view_url"));
Date receivetime = format.parse(parseString(rs.getString("cre_time")));
String userid = parseString(rs.getString("in_user_id"));
String fromusername = parseString(rs.getString("fromusername"));
String leaderInsNum = parseString(rs.getString("leaderInsNum"));
String relationId = parseString(rs.getString("relationId"));
String relationTable = parseString(rs.getString("relationTable"));
cur.setId(id);
cur.setTitle(title);
cur.setUrl(url);
//TODO: 因为redis从小到大排序,所以考虑是不是要把时间载戳变成负数
cur.setReceiveTime(0-receivetime.getTime());
cur.setDataSource(SOURCE);
cur.setFromUserName(fromusername);
cur.setLeaderInsNum(leaderInsNum);
cur.setRelationId(relationId);
cur.setRelationTable(relationTable);
ret.add(cur);
}
}
rs.close();
stmt.close();
conn.close();
DynamicDataSourceContextHolder.clearDataSourceType();
}
private static String parseString(Object obj) {
String ret = "";
if(obj != null)
ret = obj.toString();
return ret;
}
/**
* 阅毕
* @param id
*/
public static void afterReading(String id){
DynamicDataSourceContextHolder.setDataSourceType(DataSourceType.ORACLE.name());
DataSource dataSource = (DataSource) SpringUtils.getBean("dynamicDataSource");
String sql = "update doc_send set see_flag='1' ,notion_date='"+ DateUtils.getNowDate("yyyy-MM-dd HH:mm:ss") +"' where send_id='"+id+"'";
Connection conn = null;
Statement stmt = null;
try{
conn = dataSource.getConnection();
stmt = conn.createStatement();
update(conn,stmt,sql);
}catch(Exception e){
e.printStackTrace();
}finally{
DynamicDataSourceContextHolder.clearDataSourceType();
}
}
private static void update(Connection conn,Statement stmt,String sql) throws Exception{
int i = stmt.executeUpdate(sql);
stmt.close();
conn.close();
DynamicDataSourceContextHolder.clearDataSourceType();
}
}
package com.sinobase.project.module.toberead.model;
import java.io.Serializable;
public class Toberead implements Serializable {
private String id; //数据ID
private String title; //待阅标题
private long receiveTime; //待阅接收到的时候,根据这个字段进行排序
private String url; //待阅url
private String fromUserName; //上一办理人
private String leaderInsNum; //领导批示数
private String relationId; //关联ID
private String relationTable; //关联表
private String dataSource; //数据来源
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getTitle() {
return title;
}
public void setTitle(String title) {
this.title = title;
}
public long getReceiveTime() {
return receiveTime;
}
public void setReceiveTime(long receiveTime) {
this.receiveTime = receiveTime;
}
public String getUrl() {
return url;
}
public void setUrl(String url) {
this.url = url;
}
public String getFromUserName() {
return fromUserName;
}
public void setFromUserName(String fromUserName) {
this.fromUserName = fromUserName;
}
public String getDataSource() {
return dataSource;
}
public void setDataSource(String dataSource) {
this.dataSource = dataSource;
}
public String getLeaderInsNum() {
return leaderInsNum;
}
public void setLeaderInsNum(String leaderInsNum) {
this.leaderInsNum = leaderInsNum;
}
public String getRelationId() {
return relationId;
}
public void setRelationId(String relationId) {
this.relationId = relationId;
}
public String getRelationTable() {
return relationTable;
}
public void setRelationTable(String relationTable) {
this.relationTable = relationTable;
}
}
package com.sinobase.project.module.toberead.service;
import com.sinobase.project.module.toberead.model.Toberead;
import java.util.List;
public interface ITobereadExtranetService {
public int getPageCount(int count);
public int getCount();
public List<Toberead> getDoneList(int pageNumber, int countPerPage);
public void afterReading(String id, String dataSource);
}
package com.sinobase.project.module.toberead.service;
import java.util.Set;
public interface ITobereadService {
public int getPageCount(int count);
public int getCount();
public Set<Object> getDoneList(int pageNumber, int countPerPage);
public void refreshIndex(String userId);
public void afterReading(String id, String dataSource);
}
package com.sinobase.project.module.toberead.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.DateUtils;
import com.sinobase.common.utils.IdUtils;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.module.toberead.dao.LocalTobereadHandler;
import com.sinobase.project.module.toberead.dao.RemoteTobereadHandler;
import com.sinobase.project.module.toberead.model.Toberead;
import com.sinobase.project.system.portal.domain.Message;
import com.sinobase.project.system.portal.service.IMessageService;
import com.sinobase.project.system.readingmanagement.domain.DocSend;
import com.sinobase.project.system.readingmanagement.service.IDocSendService;
import com.sinobase.project.system.user.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.Date;
import java.util.List;
@Service
public class TobereadExtranetServiceImpl implements ITobereadExtranetService {
@Autowired
private DruidDataSource dataSource;
@Autowired
private IMessageService messageService;
@Autowired
IDocSendService docSendService;
@Override
public int getPageCount(int count) {
int itemCount = getCount();
int pageCount = itemCount / count;
if(0 != itemCount % count) {
++ pageCount;
}
return pageCount;
}
@Override
public int getCount() {
int count = 0;
try{
List<Toberead> localTodoList = LocalTobereadHandler.getTodo(dataSource,0,0);
count = localTodoList.size();
}catch(Exception e){
e.printStackTrace();
}
return count;
}
@Override
public List<Toberead> getDoneList(int pageNumber, int countPerPage) {
List<Toberead> localTodoList = null;
try{
localTodoList = LocalTobereadHandler.getTodo(dataSource,pageNumber,countPerPage);
}catch(Exception e){
e.printStackTrace();
}
return localTodoList;
}
/**
* 阅毕
* @param id
* @param dataSource
*/
public void afterReading(String id, String dataSource){
User user = ShiroUtils.getSysUser();
//新老数据判断
if(StringUtils.isNotEmpty(dataSource)&&dataSource.equals(LocalTobereadHandler.SOURCE)){
//获取message信息
Message msg = messageService.getMessage(id);
//向doc_send中插入已阅信息
DocSend doc = new DocSend();
doc.setSendId(IdUtils.getRandomIdByUUID());
doc.setRelationId(msg.getSubordinateId());
doc.setRelationTable(msg.getWaitHandleTableName());
doc.setRelationKey(msg.getWaitHandlePrimaryKeyName());
doc.setViewUrl(msg.getUrl());
doc.setInUserId(user.getUserId());
doc.setCreUserId(user.getUserId());
doc.setCreTime(DateUtils.parseDateToStr("yyyy-MM-dd HH:mm:ss", new Date()));
doc.setNotionDate(DateUtils.parseDateToStr("yyyy-MM-dd HH:mm:ss", new Date()));
doc.setSeeFlag("1");
doc.setKeyWord(msg.getCategoryTypes());
doc.setSendTitle(msg.getTitle());
doc.setNotionDate(DateUtils.parseDateToStr("yyyy-MM-dd HH:mm:ss", new Date()));
docSendService.saveDocSend(doc);
//删除待阅信息
messageService.delMessage(id);
}else if(StringUtils.isNotEmpty(dataSource)&&dataSource.equals(RemoteTobereadHandler.SOURCE)){
// 外网只处理mysql待阅数据 oracle不进行处理
// RemoteTobereadHandler.afterReading(id);
}
}
}
package com.sinobase.project.module.toberead.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.DateUtils;
import com.sinobase.common.utils.IdUtils;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.module.toberead.dao.LocalTobereadHandler;
import com.sinobase.project.module.toberead.dao.RemoteTobereadHandler;
import com.sinobase.project.module.toberead.model.Toberead;
import com.sinobase.project.system.portal.domain.Message;
import com.sinobase.project.system.portal.service.IMessageService;
import com.sinobase.project.system.readingmanagement.domain.DocSend;
import com.sinobase.project.system.readingmanagement.service.IDocSendService;
import com.sinobase.project.system.user.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.DefaultTypedTuple;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.data.redis.core.ZSetOperations;
import org.springframework.stereotype.Service;
import java.sql.SQLException;
import java.util.Date;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
@Service
public class TobereadServiceImpl implements ITobereadService {
@Autowired
private RedisTemplate<Object, Object> redisTemplate;
@Autowired
private DruidDataSource dataSource;
@Autowired
private IMessageService messageService;
@Autowired
IDocSendService docSendService;
@Override
public int getPageCount(int count) {
int itemCount = getCount();
int pageCount = itemCount / count;
if(0 != itemCount % count) {
++ pageCount;
}
return pageCount;
}
@Override
public int getCount() {
User user = ShiroUtils.getSysUser();
String userId = user.getUserId();
int count = redisTemplate.opsForZSet().zCard("toberead"+userId).intValue();
return count;
}
@Override
public Set<Object> getDoneList(int pageNumber, int countPerPage) {
User user = ShiroUtils.getSysUser();
String userId = user.getUserId();
int pageCount = getPageCount(countPerPage);
if(pageNumber > pageCount) { //如果要获取的页数大于实际页数
pageNumber = pageCount;
}
int start = (pageNumber - 1) * countPerPage;
int end = pageNumber * countPerPage - 1;
if(end > getCount()) {
end = -1;
}
Set<Object> ret = redisTemplate.opsForZSet().range("toberead"+userId, start, end);
return ret;
}
//从mysql和oracle中读取待阅数(根据用户ID)并添加到redis中,
public void refreshIndex(String userId) {
try {
List<Toberead> localTodoList = LocalTobereadHandler.getTodo(dataSource,0,0);
List<Toberead> remoteTodoList = RemoteTobereadHandler.getTodo();
localTodoList.addAll(remoteTodoList);
setRedisData(userId, localTodoList);
} catch (SQLException e) {
e.printStackTrace();
}
}
//将待阅数据更新到redis中
private void setRedisData(String userId, List<Toberead> todoList) {
redisTemplate.opsForZSet().removeRange("toberead"+userId, 0, -1);
/*for(Toberead todo : todoList) {
redisTemplate.opsForZSet().add("toberead"+userId, todo, todo.getReceiveTime());
}*/
Set<ZSetOperations.TypedTuple<Object>> tuples = new HashSet<ZSetOperations.TypedTuple<Object>>();
for(Toberead todo : todoList) {
ZSetOperations.TypedTuple<Object> curTuple = new DefaultTypedTuple(todo, (double)todo.getReceiveTime());
tuples.add(curTuple);
}
if(tuples.size()>0){
redisTemplate.opsForZSet().add("toberead" + userId, tuples);
}
}
/**
* 阅毕
* @param id
* @param dataSource
*/
public void afterReading(String id, String dataSource){
User user = ShiroUtils.getSysUser();
//新老数据判断
if(StringUtils.isNotEmpty(dataSource)&&dataSource.equals(LocalTobereadHandler.SOURCE)){
//获取message信息
Message msg = messageService.getMessage(id);
//向doc_send中插入已阅信息
DocSend doc = new DocSend();
doc.setSendId(IdUtils.getRandomIdByUUID());
doc.setRelationId(msg.getSubordinateId());
doc.setRelationTable(msg.getWaitHandleTableName());
doc.setRelationKey(msg.getWaitHandlePrimaryKeyName());
doc.setViewUrl(msg.getUrl());
doc.setInUserId(user.getUserId());
doc.setCreUserId(user.getUserId());
doc.setCreTime(DateUtils.parseDateToStr("yyyy-MM-dd HH:mm:ss", new Date()));
doc.setNotionDate(DateUtils.parseDateToStr("yyyy-MM-dd HH:mm:ss", new Date()));
doc.setSeeFlag("1");
doc.setKeyWord(msg.getCategoryTypes());
doc.setSendTitle(msg.getTitle());
doc.setNotionDate(DateUtils.parseDateToStr("yyyy-MM-dd HH:mm:ss", new Date()));
docSendService.saveDocSend(doc);
//删除待阅信息
messageService.delMessage(id);
}else if(StringUtils.isNotEmpty(dataSource)&&dataSource.equals(RemoteTobereadHandler.SOURCE)){
RemoteTobereadHandler.afterReading(id);
}
}
}
package com.sinobase.project.module.todo.controller;
import com.github.pagehelper.PageHelper;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.framework.web.page.PageDomain;
import com.sinobase.framework.web.page.TableDataInfo;
import com.sinobase.framework.web.page.TableSupport;
import com.sinobase.project.module.todo.model.Todo;
import com.sinobase.project.module.todo.service.IProcessJumpService;
import com.sinobase.project.module.todo.service.ITodoExtranetService;
import com.sinobase.project.module.todo.service.ITodoService;
import com.sinobase.project.system.user.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping("/processJump")
public class ProcessJumpController {
@Autowired
IProcessJumpService processJumpService;
/**
* 获取列表信息(跳节点)
* @return
*/
@RequestMapping("/tablelistAll")
@ResponseBody
public TableDataInfo getDoneTableListAll(String title){
PageDomain pageDomain = TableSupport.buildPageRequest();
Integer pageNum = pageDomain.getPageNum();
Integer pageSize = pageDomain.getPageSize();
if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
String orderBy = pageDomain.getOrderBy();
PageHelper.startPage(pageNum, pageSize, orderBy);
}
int indexCount = processJumpService.getCount("all",title);
List<Object> doneList = new ArrayList<Object>(processJumpService.getTodoList(pageNum, pageSize,"all",title));
TableDataInfo rspData = new TableDataInfo();
rspData.setCode(0);
rspData.setRows(doneList);
rspData.setTotal(indexCount);
return rspData;
}
@RequestMapping("/tablelistAllDone")
@ResponseBody
public TableDataInfo getDoneTableListAllDone(String title){
PageDomain pageDomain = TableSupport.buildPageRequest();
Integer pageNum = pageDomain.getPageNum();
Integer pageSize = pageDomain.getPageSize();
if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
String orderBy = pageDomain.getOrderBy();
PageHelper.startPage(pageNum, pageSize, orderBy);
}
int indexCount = processJumpService.getDoneCount("all",title);
List<Object> doneList = new ArrayList<Object>(processJumpService.getDoneList(pageNum, pageSize,"all",title));
TableDataInfo rspData = new TableDataInfo();
rspData.setCode(0);
rspData.setRows(doneList);
rspData.setTotal(indexCount);
return rspData;
}
}
package com.sinobase.project.module.todo.controller;
import com.github.pagehelper.PageHelper;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.framework.web.page.PageDomain;
import com.sinobase.framework.web.page.TableDataInfo;
import com.sinobase.framework.web.page.TableSupport;
import com.sinobase.project.module.todo.model.Todo;
import com.sinobase.project.module.todo.service.ITodoExtranetService;
import com.sinobase.project.module.todo.service.ITodoService;
import com.sinobase.project.system.user.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping("/todo")
public class TodoController {
@Autowired
ITodoService todoService;
@Autowired
ITodoExtranetService todoExtranetService;
@Value("${sinobase.isIntranet}")
private boolean isIntranet;
/**
* 获取待办数据分页数量(页数)
* @param count 每页的数据条数
* @return 页数
*/
@RequestMapping("/page_count/{count}")
@ResponseBody
public int getPageCount(@PathVariable int count) {
if(isIntranet){
return todoService.getPageCount(count);
}else{
return todoExtranetService.getPageCount(count);
}
}
/**
* 获取所有待办数据的数量
* @return 待办数量
*/
@RequestMapping("/count")
@ResponseBody
public int getCount() {
if(isIntranet){
return todoService.getCount();
}else{
return todoExtranetService.getCount();
}
}
/**
* 获取待办分页数据
* @param pageNumber 第几页数据
* @param countPerPage 每页有几条数据
* @return json型式的整页待办数据
*/
@RequestMapping("/list/{pageNumber}/{countPerPage}")
@ResponseBody
public Map<String,Object> getDoneList(@PathVariable int pageNumber, @PathVariable int countPerPage){
User user = ShiroUtils.getSysUser();
String userId = user.getUserId();
Map<String,Object> map = new HashMap<String,Object>();
if(isIntranet){
todoService.refreshIndex(userId);
map.put("list",todoService.getDoneList(pageNumber, countPerPage));
map.put("count",todoService.getCount());
}else{
map.put("list",todoExtranetService.getDoneList(pageNumber,countPerPage));
map.put("count",todoExtranetService.getCount());
}
return map;
}
/**
* 获取列表信息(更多)
* @return
*/
@RequestMapping("/tablelist")
@ResponseBody
public TableDataInfo getDoneTableList(String title){
User user = ShiroUtils.getSysUser();
String userId = user.getUserId();
PageDomain pageDomain = TableSupport.buildPageRequest();
Integer pageNum = pageDomain.getPageNum();
Integer pageSize = pageDomain.getPageSize();
if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
String orderBy = pageDomain.getOrderBy();
PageHelper.startPage(pageNum, pageSize, orderBy);
}
int indexCount = 0;
List<Object> doneList = null;
if(isIntranet){
todoService.refreshIndex(userId);
indexCount = todoService.getCount();
doneList = new ArrayList<Object>(todoService.getDoneList(pageNum, pageSize));
}else{
indexCount = todoExtranetService.getCount();
doneList = new ArrayList<Object>(todoExtranetService.getDoneList(pageNum, pageSize));
}
TableDataInfo rspData = new TableDataInfo();
rspData.setCode(0);
rspData.setRows(doneList);
rspData.setTotal(indexCount);
return rspData;
}
/**
* 根据sendclass获取待办列表信息
* @return
*/
@RequestMapping("/tablelistBySendclass")
@ResponseBody
public Map<String,List<Todo>> getDoneListBySendclass(){
Map<String,List<Todo>> map = null;
if(isIntranet){
map = todoService.getDoneList();
}else{
map = todoExtranetService.getDoneList();
}
return map;
}
}
package com.sinobase.project.module.todo.dao;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.module.todo.model.Todo;
import com.sinobase.project.system.portal.constant.MessageConstants;
import com.sinobase.project.system.user.domain.User;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
public class LocalTodoHandler {
public static final String SOURCE = "local";
public static List<Todo> getTodo(DruidDataSource dataSource,int pageNumber,int countPerPage)
throws SQLException{
User user = ShiroUtils.getSysUser();
List<Todo> ret = new ArrayList<Todo>();
String sql = "select id, title, url, receive_time,grant_user_id,from_user_name,subordinate_id,level,'' as sendclass,'' as filetypename,'' as wflevename,0 as leaderInsNum from sys_message where grant_user_id = '"+user.getUserId()
+"' and message_type='"+ MessageConstants.MESSAGE_TYPE_WORK_FLOW_WRITE +"'";
if(pageNumber!=0&&countPerPage!=0){
sql += " order by receive_time desc limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
}
System.out.println("LocalTodoHandler mysql "+sql);
Connection conn = dataSource.getConnection();
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Todo cur = new Todo();
cur.setId(rs.getString("id"));
cur.setTitle(rs.getString("title"));
cur.setUrl(rs.getString("url"));
cur.setFromUserName(rs.getString("from_user_name"));
Date receiveTime = rs.getTimestamp("receive_time");
//TODO: 因为redis从小到大排序,所以考虑是不是要把时间载戳变成负数
cur.setReceiveTime(0-receiveTime.getTime());
cur.setDataSource(SOURCE);
cur.setUrgency(rs.getString("level"));
cur.setSendclass(rs.getString("sendclass"));
cur.setFiletypename(rs.getString("filetypename"));
cur.setWflevename(rs.getString("wflevename"));
cur.setLeaderInsNum(rs.getString("leaderInsNum"));
cur.setRecordId(rs.getString("subordinate_id"));
cur.setTypeSort("");
cur.setLimitTime("");
cur.setFlowSort("");
cur.setFlowSort2("");
ret.add(cur);
}
}
}catch(SQLException e) {
e.printStackTrace();
}finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
}
package com.sinobase.project.module.todo.dao;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.module.done.dao.LocalSysHandler;
import com.sinobase.project.module.todo.model.Todo;
import com.sinobase.project.system.portal.constant.MessageConstants;
import com.sinobase.project.system.user.domain.User;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.*;
public class ProcessJumpHandler {
public static final String SOURCE = "local";
public static List<Todo> getTodo(DruidDataSource dataSource,int pageNumber,int countPerPage,String isSelf,String title)
throws SQLException{
User user = ShiroUtils.getSysUser();
List<Todo> ret = new ArrayList<Todo>();
String sql = "select id, title, url, receive_time,grant_user_id,from_user_name,level,'' as sendclass from sys_message where 1=1 ";
if(StringUtils.isNotEmpty(isSelf)&&isSelf.equals("self")){
sql += " and grant_user_id = '"+user.getUserId()+"' ";
}else{
sql += " and url not like '%/questionnaire/%' ";
}
if(StringUtils.isNotEmpty(title)){
sql += " and title like '%"+title+"%' ";
}
sql += "and message_type='"+ MessageConstants.MESSAGE_TYPE_WORK_FLOW_WRITE +"'";
if(pageNumber!=0&&countPerPage!=0){
sql += " order by receive_time desc limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
}
System.out.println("LocalTodoHandler mysql "+sql);
Connection conn = dataSource.getConnection();
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Todo cur = new Todo();
cur.setId(rs.getString("id"));
cur.setTitle(rs.getString("title"));
cur.setUrl(rs.getString("url"));
cur.setFromUserName(rs.getString("from_user_name"));
Date receiveTime = rs.getTimestamp("receive_time");
//TODO: 因为redis从小到大排序,所以考虑是不是要把时间载戳变成负数
cur.setReceiveTime(0-receiveTime.getTime());
cur.setDataSource(SOURCE);
cur.setUrgency(rs.getString("level"));
cur.setSendclass(rs.getString("sendclass"));
ret.add(cur);
}
}
}catch(SQLException e) {
e.printStackTrace();
}finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
public static List<Map<String, Object>> getDone(DruidDataSource dataSource,int pageNumber,int countPerPage,String isSelf,String title)
throws SQLException{
User user = ShiroUtils.getSysUser();
List<Map<String, Object>> ret = new ArrayList<Map<String, Object>>();
String sql = "select id, title, filetypeid, filetypename,recordid,readtime,docid,userid from flow_read_new where 1=1 ";
if(StringUtils.isNotEmpty(isSelf)&&isSelf.equals("self")){
sql += " and userid = '"+user.getUserId()+"' ";
}else{
sql += " and handdoneurl not like '%/questionnaire/%' ";
}
if(StringUtils.isNotEmpty(title)){
sql += " and title like '%"+title+"%' ";
}
if(pageNumber!=0&&countPerPage!=0){
sql += " order by readtime desc limit "+ (pageNumber-1)*countPerPage +","+ countPerPage;
}
System.out.println("LocalDoneHandler mysql "+sql);
Connection conn = dataSource.getConnection();
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if(null != rs) {
while(rs.next()) {
Map<String, Object> temp = new HashMap<String, Object>();
String id = rs.getString("id");
String userid = rs.getString("userid");
String til = rs.getString("title");
String recordid = rs.getString("recordid");
String docid = rs.getString("docid");
String filetypeid = rs.getString("filetypeid");
String filetypename = rs.getString("filetypename");
Date receiveTime = rs.getTimestamp("readtime");
temp.put("id", id);
temp.put("title", til);
temp.put("filetypeid", filetypeid);
temp.put("filetypename", filetypename);
temp.put("recordid", recordid);
temp.put("readtime", receiveTime);
temp.put("docid", docid);
temp.put("userid", userid);
ret.add(temp);
}
}
}catch(SQLException e) {
e.printStackTrace();
}finally {
rs.close();
pstmt.close();
conn.close();
}
return ret;
}
}
package com.sinobase.project.module.todo.dao;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.common.utils.spring.SpringUtils;
import com.sinobase.datasource.aspectj.lang.enums.DataSourceType;
import com.sinobase.datasource.source.DynamicDataSourceContextHolder;
import com.sinobase.project.module.todo.model.Todo;
import com.sinobase.project.system.user.domain.User;
import javax.sql.DataSource;
import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.Statement;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
public class RemoteTodoHandler {
public static final String SOURCE = "old";
public static synchronized List<Todo> getTodo(){
User user = ShiroUtils.getSysUser();
List<Todo> ret = new ArrayList<Todo>();
DynamicDataSourceContextHolder.setDataSourceType(DataSourceType.ORACLE.name());
DataSource dataSource = (DataSource) SpringUtils.getBean("dynamicDataSource");
String sql = "select t.id,t.title,t.recordid,t.url,t.createtime,t.userid,t.preusername,t.deptid,t.hj,t.sendclass,t.filetypename,t.wflevename,t.typesort,t.flowsort,t.flowsort2," +
"case when (t.sendclass='SW')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_IN' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.recordid )" +
" when (t.sendclass='FW')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_OUT' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.recordid )" +
" when (t.sendclass='QB')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_SIGN' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.recordid )" +
" when (t.sendclass='HYJY')" +
" then (select count(*) from flow_idea a where tablename like 'YZ_ARCHIVES_SUMMARY' and a.stattag ='1' and a.wfisvisible ='1' and a.recordid =t.recordid )" +
" end as leaderInsNum" +
" from oa_db t where (userid='"+user.getUserId()+"' or userid='"+user.getHistoryId()+"')";
System.out.println("RemoteTodoHandler oracle "+sql);
Connection conn = null;
Statement stmt = null;
ResultSet rs = null;
try{
conn = dataSource.getConnection();
stmt = conn.createStatement();
rs = stmt.executeQuery(sql);
getValue(conn,stmt,rs,ret);
}catch(Exception e){
e.printStackTrace();
}finally{
DynamicDataSourceContextHolder.clearDataSourceType();
}
return ret;
}
private static void getValue(Connection conn,Statement stmt,ResultSet rs,List<Todo> ret) throws Exception{
User user = ShiroUtils.getSysUser();
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
if(null != rs) {
while (rs.next()) {
Todo cur = new Todo();
String id = parseString(rs.getString("id"));
String title = parseString(rs.getString("title"));
String recordid = parseString(rs.getString("recordid"));
String url = parseString(rs.getString("url"));
String creTime = parseString(rs.getString("createtime"));
String deptid = parseString(rs.getString("deptid"));
String wflevename =parseString(rs.getString("wflevename"));
String filetypename = parseString(rs.getString("filetypename"));
String leaderInsNum = parseString(rs.getString("leaderInsNum"));
String typesort = parseString(rs.getString("typesort"));
String flowsort = parseString(rs.getString("flowsort"));
String flowsort2 = parseString(rs.getString("flowsort2"));
if(creTime.length()==10){
creTime += " 00:00:00";
}else if(creTime.length()==16){
creTime += ":00";
}else if(creTime.length()<10) {
creTime = format.format(new Date());
}
Date receivetime = format.parse(creTime);
String userid = parseString(rs.getString("userid"));
String fromusername = parseString(rs.getString("preusername"));
String hj = parseString(rs.getString("hj"));
String sendclass = parseString(rs.getString("sendclass"));
cur.setId(id);
cur.setTitle(title);
cur.setRecordId(recordid);
cur.setUrl(url);
//TODO: 因为redis从小到大排序,所以考虑是不是要把时间载戳变成负数
cur.setReceiveTime(0-receivetime.getTime());
cur.setDataSource(SOURCE);
cur.setFromUserName(fromusername);
cur.setFiletypename(filetypename);
cur.setWflevename(wflevename);
if(deptid!=null && !deptid.equals("")) {
cur.setDeptId(deptid);
}else {
cur.setDeptId(user.getDept().getHistoryId());
}
cur.setUrgency(hj);
cur.setSendclass(sendclass);
cur.setLeaderInsNum(leaderInsNum);
cur.setTypeSort(typesort);
cur.setFlowSort(flowsort);
cur.setFlowSort2(flowsort2);
ret.add(cur);
}
}
rs.close();
stmt.close();
conn.close();
DynamicDataSourceContextHolder.clearDataSourceType();
}
private static String parseString(Object obj) {
String ret = "";
if(obj != null)
ret = obj.toString();
return ret;
}
}
package com.sinobase.project.module.todo.model;
import java.io.Serializable;
public class Todo implements Serializable {
private String id; //数据ID
private String title; //待办标题
private String recordId; //业务ID
private long receiveTime; //待办接收到的时候,根据这个字段进行排序
private String url; //待办url
private String fromUserName; //上一办理人
private String dataSource; //数据来源
private String deptId;
private String urgency; //缓急
private String sendclass;
private String wflevename;
private String filetypename;
private String leaderInsNum; //领导批示数
private String typeSort; //类型
private String limitTime; //反馈结束时间
private String showLimitPNG; //显示反馈结束时间PNG图片
private String flowSort; //
private String flowSort2; //
public String getWflevename() {
return wflevename;
}
public void setWflevename(String wflevename) {
this.wflevename = wflevename;
}
public String getFiletypename() {
return filetypename;
}
public void setFiletypename(String filetypename) {
this.filetypename = filetypename;
}
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getTitle() {
return title;
}
public void setTitle(String title) {
this.title = title;
}
public long getReceiveTime() {
return receiveTime;
}
public void setReceiveTime(long receiveTime) {
this.receiveTime = receiveTime;
}
public String getUrl() {
return url;
}
public void setUrl(String url) {
this.url = url;
}
public String getFromUserName() {
return fromUserName;
}
public void setFromUserName(String fromUserName) {
this.fromUserName = fromUserName;
}
public String getDataSource() {
return dataSource;
}
public void setDataSource(String dataSource) {
this.dataSource = dataSource;
}
public String getDeptId() {
return deptId;
}
public void setDeptId(String deptId) {
this.deptId = deptId;
}
public String getUrgency() {
return urgency;
}
public void setUrgency(String urgency) {
this.urgency = urgency;
}
public String getSendclass() {
return sendclass;
}
public void setSendclass(String sendclass) {
this.sendclass = sendclass;
}
public String getLeaderInsNum() {
return leaderInsNum;
}
public void setLeaderInsNum(String leaderInsNum) {
this.leaderInsNum = leaderInsNum;
}
public String getTypeSort() {
return typeSort;
}
public void setTypeSort(String typeSort) {
this.typeSort = typeSort;
}
public String getLimitTime() {
return limitTime;
}
public void setLimitTime(String limitTime) {
this.limitTime = limitTime;
}
public String getShowLimitPNG() {
return showLimitPNG;
}
public void setShowLimitPNG(String showLimitPNG) {
this.showLimitPNG = showLimitPNG;
}
public String getRecordId() {
return recordId;
}
public void setRecordId(String recordId) {
this.recordId = recordId;
}
public String getFlowSort() {
return flowSort;
}
public void setFlowSort(String flowSort) {
this.flowSort = flowSort;
}
public String getFlowSort2() {
return flowSort2;
}
public void setFlowSort2(String flowSort2) {
this.flowSort2 = flowSort2;
}
}
package com.sinobase.project.module.todo.service;
import com.sinobase.project.module.todo.model.Todo;
import java.util.List;
import java.util.Map;
public interface IProcessJumpService {
public int getCount(String isSelf, String title);
public List<Todo> getTodoList(int pageNumber, int countPerPage, String isSelf, String title);
public int getDoneCount(String isSelf, String title);
public List<Map<String, Object>> getDoneList(int pageNumber, int countPerPage,String isSelf,String title);
}
package com.sinobase.project.module.todo.service;
import com.sinobase.project.module.todo.model.Todo;
import java.util.List;
import java.util.Map;
public interface ITodoExtranetService {
public int getPageCount(int count);
public int getCount();
public List<Todo> getDoneList(int pageNumber, int countPerPage);
public Map<String, List<Todo>> getDoneList();
}
package com.sinobase.project.module.todo.service;
import com.sinobase.project.module.todo.model.Todo;
import java.util.List;
import java.util.Map;
import java.util.Set;
public interface ITodoService {
public int getPageCount(int count);
public int getCount();
public Set<Object> getDoneList(int pageNumber, int countPerPage);
public void refreshIndex(String userId);
public Map<String, List<Todo>> getDoneList();
}
package com.sinobase.project.module.todo.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.project.module.todo.dao.LocalTodoHandler;
import com.sinobase.project.module.todo.dao.ProcessJumpHandler;
import com.sinobase.project.module.todo.model.Todo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.*;
@Service
public class ProcessJumpServiceImpl implements IProcessJumpService {
@Autowired
private DruidDataSource dataSource;
@Override
public int getCount(String isSelf,String title) {
int count = 0;
try{
List<Todo> localTodoList = new ArrayList<>();
if(StringUtils.isNotEmpty(isSelf)&&isSelf.equals("all")){
localTodoList = ProcessJumpHandler.getTodo(dataSource,0,0,isSelf,title);
}else{
localTodoList = ProcessJumpHandler.getTodo(dataSource,0,0,"self",title);
}
count = localTodoList.size();
}catch(Exception e){
e.printStackTrace();
}
return count;
}
@Override
public List<Todo> getTodoList(int pageNumber, int countPerPage,String isSelf,String title) {
List<Todo> localTodoList = null;
try{
localTodoList = ProcessJumpHandler.getTodo(dataSource,pageNumber,countPerPage,isSelf,title);
}catch(Exception e){
e.printStackTrace();
}
return localTodoList;
}
@Override
public int getDoneCount(String isSelf,String title) {
int count = 0;
try{
List<Map<String, Object>> localTodoList = new ArrayList<>();
if(StringUtils.isNotEmpty(isSelf)&&isSelf.equals("all")){
localTodoList = ProcessJumpHandler.getDone(dataSource,0,0,isSelf,title);
}else{
localTodoList = ProcessJumpHandler.getDone(dataSource,0,0,"self",title);
}
count = localTodoList.size();
}catch(Exception e){
e.printStackTrace();
}
return count;
}
@Override
public List<Map<String, Object>> getDoneList(int pageNumber, int countPerPage,String isSelf,String title) {
List<Map<String, Object>> localTodoList = null;
try{
localTodoList = ProcessJumpHandler.getDone(dataSource,pageNumber,countPerPage,isSelf,title);
}catch(Exception e){
e.printStackTrace();
}
return localTodoList;
}
}
package com.sinobase.project.module.todo.service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.project.module.todo.dao.LocalTodoHandler;
import com.sinobase.project.module.todo.model.Todo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.*;
@Service
public class TodoExtranetServiceImpl implements ITodoExtranetService {
@Autowired
private DruidDataSource dataSource;
@Override
public int getPageCount(int count) {
int itemCount = getCount();
int pageCount = itemCount / count;
if(0 != itemCount % count) {
++ pageCount;
}
return pageCount;
}
@Override
public int getCount() {
int count = 0;
try{
List<Todo> localTodoList = LocalTodoHandler.getTodo(dataSource,0,0);
count = localTodoList.size();
}catch(Exception e){
e.printStackTrace();
}
return count;
}
@Override
public List<Todo> getDoneList(int pageNumber, int countPerPage) {
List<Todo> localTodoList = null;
try{
localTodoList = LocalTodoHandler.getTodo(dataSource,pageNumber,countPerPage);
}catch(Exception e){
e.printStackTrace();
}
return localTodoList;
}
public Map<String,List<Todo>> getDoneList(){
Set<String> keySet = new HashSet<String>();
Map<String,List<Todo>> map = new HashMap<String,List<Todo>>();
try{
List<Todo> localTodoList = LocalTodoHandler.getTodo(dataSource,0,0);
for(Todo todo : localTodoList){
if(StringUtils.isNotEmpty(todo.getSendclass())){
if(keySet.contains(todo.getSendclass())){
List<Todo> list = new ArrayList<Todo>();
list = map.get(todo.getSendclass());
list.add(todo);
map.put(todo.getSendclass(),list);
}else{
keySet.add(todo.getSendclass());
List<Todo> list = new ArrayList<Todo>();
list.add(todo);
map.put(todo.getSendclass(),list);
}
}
}
}catch(Exception e){
e.printStackTrace();
}
return map;
}
}
package com.sinobase.project.module.todo.service;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.LinkedHashMap;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.DefaultTypedTuple;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.data.redis.core.ZSetOperations;
import org.springframework.stereotype.Service;
import com.alibaba.druid.pool.DruidDataSource;
import com.sinobase.common.utils.StringUtils;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.project.module.homepage.service.IHomePageSerive;
import com.sinobase.project.module.todo.dao.LocalTodoHandler;
import com.sinobase.project.module.todo.dao.RemoteTodoHandler;
import com.sinobase.project.module.todo.model.Todo;
import com.sinobase.project.system.user.domain.User;
@Service
public class TodoServiceImpl implements ITodoService {
@Autowired
private RedisTemplate<Object, Object> redisTemplate;
private Map<String,Set<Object>> todoMap = new LinkedHashMap<>();
@Autowired
private IHomePageSerive homepageservice;
@Autowired
private DruidDataSource dataSource;
@Override
public int getPageCount(int count) {
int itemCount = getCount();
int pageCount = itemCount / count;
if(0 != itemCount % count) {
++ pageCount;
}
return pageCount;
}
@Override
public int getCount() {
User user = ShiroUtils.getSysUser();
String userId = user.getUserId();
int count = redisTemplate.opsForZSet().zCard("todo"+userId).intValue();
return count;
}
@Override
public Set<Object> getDoneList(int pageNumber, int countPerPage) {
User user = ShiroUtils.getSysUser();
String userId = user.getUserId();
int pageCount = getPageCount(countPerPage);
if(pageNumber > pageCount) { //如果要获取的页数大于实际页数
pageNumber = pageCount;
}
int start = (pageNumber - 1) * countPerPage;
int end = pageNumber * countPerPage - 1;
int maxIndex = getCount();
if(end > getCount()) {
end = maxIndex;
}
//获取临时存储的首页待办信息
Set<Object> ret = todoMap.get("sortedtodo"+userId);
//返回结果集
Set<Object> result = new LinkedHashSet<>();
//对工作通知进行处理
int num = 0;
if(ret!=null){
for(Object obj : ret){
if(num>=start&&num<=end){
Todo todo = (Todo) obj;
if(StringUtils.isNotEmpty(todo.getTypeSort())&&todo.getTypeSort().equals("worknotice")){
//通过ID获取通知信息,将反馈结束时间存入待办中
if(StringUtils.isNotEmpty(todo.getRecordId())){
Map<String,String> tongzhi = homepageservice.getTongZhiById(todo.getRecordId());
String limitTime = tongzhi.get("LIMIT_TIME");
if(StringUtils.isNotEmpty(limitTime)){
todo.setLimitTime(limitTime);
todo.setShowLimitPNG("true");
}else{
todo.setShowLimitPNG("false");
}
}
}
result.add(todo);
}
num++;
}
}
return result;
}
//从mysql和oracle中读取待办数(根据用户ID)并添加到redis中,
public void refreshIndex(String userId) {
try {
List<Todo> localTodoList = LocalTodoHandler.getTodo(dataSource,0,0);
List<Todo> remoteTodoList = RemoteTodoHandler.getTodo();
localTodoList.addAll(remoteTodoList);
setRedisData(userId, localTodoList);
} catch (SQLException e) {
e.printStackTrace();
}
}
//将待办数据更新到redis中
private void setRedisData(String userId, List<Todo> todoList) {
redisTemplate.opsForZSet().removeRange("todo"+userId, 0, redisTemplate.opsForZSet().size("todo"+userId));
redisTemplate.opsForZSet().removeRange("sortedtodo"+userId, 0, redisTemplate.opsForZSet().size("sortedtodo"+userId));
/*for(Todo todo : todoList) {
redisTemplate.opsForZSet().add("todo"+userId, todo, todo.getReceiveTime());
}*/
Set<ZSetOperations.TypedTuple<Object>> tuples = new HashSet<ZSetOperations.TypedTuple<Object>>();
for(Todo todo : todoList) {
ZSetOperations.TypedTuple<Object> curTuple = new DefaultTypedTuple(todo, (double)todo.getReceiveTime());
tuples.add(curTuple);
}
if(tuples.size()>0){
redisTemplate.opsForZSet().add("todo" + userId, tuples);
}
//获取redis中所有待办
Set<Object> retAll = redisTemplate.opsForZSet().range("todo"+userId, 0, redisTemplate.opsForZSet().size("todo"+userId));
//急文集合
Set<Object> urgencySet = new LinkedHashSet<>();
//其他集合
Set<Object> othersSet = new LinkedHashSet<>();
//遍历获取所有急文
for(Object obj : retAll){
Todo todo = (Todo) obj;
ZSetOperations.TypedTuple<Object> curTuple = new DefaultTypedTuple(todo, (double)todo.getReceiveTime());
if(StringUtils.isNotEmpty(todo.getUrgency())&&(todo.getUrgency().equals("特急")||todo.getUrgency().equals("加急")||todo.getUrgency().equals("是"))){
urgencySet.add(obj);
}else{
othersSet.add(obj);
}
}
urgencySet.addAll(othersSet);
if(urgencySet.size()>0){
todoMap.put("sortedtodo"+userId,urgencySet);
}
}
public Map<String,List<Todo>> getDoneList(){
User user = ShiroUtils.getSysUser();
String userId = user.getUserId();
Set<String> keySet = new HashSet<String>();
Map<String,List<Todo>> map = new HashMap<String,List<Todo>>();
Set<Object> ret = redisTemplate.opsForZSet().range("todo"+userId, 0, redisTemplate.opsForZSet().size("todo"+userId));
for(Object obj : ret){
Todo todo = (Todo) obj;
//将待办数据根据流程类型sendclass进行分类
if(StringUtils.isNotEmpty(todo.getSendclass())){
if(keySet.contains(todo.getSendclass())){
List<Todo> list = new ArrayList<Todo>();
list = map.get(todo.getSendclass());
list.add(todo);
map.put(todo.getSendclass(),list);
}else{
keySet.add(todo.getSendclass());
List<Todo> list = new ArrayList<Todo>();
list.add(todo);
map.put(todo.getSendclass(),list);
}
}
}
return map;
}
}
package com.sinobase.project.system.menu.controller;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.sinobase.common.utils.security.ShiroUtils;
import com.sinobase.framework.aspectj.lang.annotation.Log;
import com.sinobase.framework.aspectj.lang.enums.BusinessType;
import com.sinobase.framework.config.SinoBaseConfig;
import com.sinobase.framework.web.controller.BaseController;
import com.sinobase.framework.web.domain.AjaxResult;
import com.sinobase.project.system.menu.domain.Menu;
import com.sinobase.project.system.menu.service.IMenuService;
import com.sinobase.project.system.role.domain.Role;
import com.sinobase.project.system.sino.service.PlatformService;
import com.sinobase.project.system.user.domain.User;
/**
* 菜单信息
*
* @author sinobase
*/
@Controller
@RequestMapping("/system/menu")
public class MenuController extends BaseController {
private String prefix = "system/menu";
@Autowired
private IMenuService menuService;
@Autowired
private PlatformService platformService;
@RequiresPermissions("system:menu:view")
@GetMapping()
public String menu() {
return prefix + "/menu";
}
/**
* 标签页面解析服务
* @param menuId 上组节点ID
* @return
*/
@GetMapping("/tab/{parentId}")
@ResponseBody
public List<Menu> tab(@PathVariable("parentId") String parentId) {
List<Menu> list = new ArrayList<Menu>();
User user = ShiroUtils.getSysUser();
if (SinoBaseConfig.isPlatform()) {
list = platformService.getTabs(user.getMenus(), parentId);
} else {
list = menuService.selectMenusByUser(user, Menu.TYPE_TAB, parentId);
}
return list;
}
@RequiresPermissions("system:menu:list")
@GetMapping("/list")
@ResponseBody
public List<Menu> list(Menu menu) {
List<Menu> menuList = menuService.selectMenuList(menu);
return menuList;
}
/**
* 删除菜单
*/
@Log(title = "菜单管理", businessType = BusinessType.DELETE)
@RequiresPermissions("system:menu:remove")
@PostMapping("/remove/{menuId}")
@ResponseBody
public AjaxResult remove(@PathVariable("menuId") String menuId) {
if (menuService.selectCountMenuByParentId(menuId) > 0) {
return error(1, "存在子菜单,不允许删除");
}
if (menuService.selectCountRoleMenuByMenuId(menuId) > 0) {
return error(1, "菜单已分配,不允许删除");
}
return toAjax(menuService.deleteMenuById(menuId));
}
/**
* 新增
*/
@GetMapping("/add/{parentId}")
public String add(@PathVariable("parentId") String parentId, ModelMap mmap) {
Menu menu = null;
if (!parentId.equals("0".toString())) {
menu = menuService.selectMenuById(parentId);
} else {
menu = new Menu();
menu.setMenuId("0");
menu.setMenuName("主目录");
}
mmap.put("menu", menu);
return prefix + "/add";
}
/**
* 新增保存菜单
*/
@Log(title = "菜单管理", businessType = BusinessType.INSERT)
@RequiresPermissions("system:menu:add")
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(Menu menu) {
return toAjax(menuService.insertMenu(menu));
}
/**
* 修改菜单
*/
@GetMapping("/edit/{menuId}")
public String edit(@PathVariable("menuId") String menuId, ModelMap mmap) {
mmap.put("menu", menuService.selectMenuById(menuId));
return prefix + "/edit";
}
/**
* 修改保存菜单
*/
@Log(title = "菜单管理", businessType = BusinessType.UPDATE)
@RequiresPermissions("system:menu:edit")
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(Menu menu) {
return toAjax(menuService.updateMenu(menu));
}
/**
* 选择菜单图标
*/
@GetMapping("/icon")
public String icon() {
return prefix + "/icon";
}
/**
* 校验菜单名称
*/
@PostMapping("/checkMenuNameUnique")
@ResponseBody
public String checkMenuNameUnique(Menu menu) {
return menuService.checkMenuNameUnique(menu);
}
/**
* 加载角色菜单列表树
*/
@GetMapping("/roleMenuTreeData")
@ResponseBody
public List<Map<String, Object>> roleMenuTreeData(Role role) {
List<Map<String, Object>> tree = menuService.roleMenuTreeData(role);
return tree;
}
/**
* 加载所有菜单列表树
*/
@GetMapping("/menuTreeData")
@ResponseBody
public List<Map<String, Object>> menuTreeData(Role role) {
List<Map<String, Object>> tree = menuService.menuTreeData();
return tree;
}
/**
* 选择菜单树
*/
@GetMapping("/selectMenuTree/{menuId}")
public String selectMenuTree(@PathVariable("menuId") String menuId, ModelMap mmap) {
mmap.put("menu", menuService.selectMenuById(menuId));
return prefix + "/tree";
}
}
\ No newline at end of file
...@@ -151,6 +151,20 @@ public class PlatformService { ...@@ -151,6 +151,20 @@ public class PlatformService {
} }
/** /**
* 设置用户登录后的相关信息
*
* @param loginName
* @return
*/
public User setLoginUserInfo(String loginName) {
User user = getUserByLoginname(loginName);
// 设置用户资源菜单 和 标签页面
user.setMenus(getResourceList(user.getUserId() + "",user.getDept().getParentId(),user));
return user;
}
/**
* 获取用户所有资源目录和标签 * 获取用户所有资源目录和标签
* *
* @param userID 登录后的用户ID * @param userID 登录后的用户ID
......
spring: spring:
redis: redis:
host: 152.136.74.6 host: 172.30.13.53
port: 6379 port: 6379
password: bug48625
#连接超时时间(毫秒) #连接超时时间(毫秒)
timeout: 2000 timeout: 2000
password:
pool: pool:
#最大连接数(负数表示没有限制) #最大连接数(负数表示没有限制)
max-active: 1000 max-active: 1000
......
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.sinobase.project.module.homepage.mapper.HomePageMapper">
<!--通过ID获取公文详情信息 -->
<select id="getTongZhiById" resultType="java.util.HashMap"
parameterType="String">
select * from yz_tongzhi_info where id=#{recordid}
</select>
</mapper>
\ No newline at end of file
/*!
* jQuery blockUI plugin
* Version 2.70.0-2014.11.23
* Requires jQuery v1.7 or later
*
* Examples at: http://malsup.com/jquery/block/
* Copyright (c) 2007-2013 M. Alsup
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
* Thanks to Amir-Hossein Sobhi for some excellent contributions!
*/
;(function() {
/*jshint eqeqeq:false curly:false latedef:false */
"use strict";
function setup($) {
$.fn._fadeIn = $.fn.fadeIn;
var noOp = $.noop || function() {};
// this bit is to ensure we don't call setExpression when we shouldn't (with extra muscle to handle
// confusing userAgent strings on Vista)
var msie = /MSIE/.test(navigator.userAgent);
var ie6 = /MSIE 6.0/.test(navigator.userAgent) && ! /MSIE 8.0/.test(navigator.userAgent);
var mode = document.documentMode || 0;
var setExpr = $.isFunction( document.createElement('div').style.setExpression );
// global $ methods for blocking/unblocking the entire page
$.blockUI = function(opts) { install(window, opts); };
$.unblockUI = function(opts) { remove(window, opts); };
// convenience method for quick growl-like notifications (http://www.google.com/search?q=growl)
$.growlUI = function(title, message, timeout, onClose) {
var $m = $('<div class="growlUI"></div>');
if (title) $m.append('<h1>'+title+'</h1>');
if (message) $m.append('<h2>'+message+'</h2>');
if (timeout === undefined) timeout = 3000;
// Added by konapun: Set timeout to 30 seconds if this growl is moused over, like normal toast notifications
var callBlock = function(opts) {
opts = opts || {};
$.blockUI({
message: $m,
fadeIn : typeof opts.fadeIn !== 'undefined' ? opts.fadeIn : 700,
fadeOut: typeof opts.fadeOut !== 'undefined' ? opts.fadeOut : 1000,
timeout: typeof opts.timeout !== 'undefined' ? opts.timeout : timeout,
centerY: false,
showOverlay: false,
onUnblock: onClose,
css: $.blockUI.defaults.growlCSS
});
};
callBlock();
var nonmousedOpacity = $m.css('opacity');
$m.mouseover(function() {
callBlock({
fadeIn: 0,
timeout: 30000
});
var displayBlock = $('.blockMsg');
displayBlock.stop(); // cancel fadeout if it has started
displayBlock.fadeTo(300, 1); // make it easier to read the message by removing transparency
}).mouseout(function() {
$('.blockMsg').fadeOut(1000);
});
// End konapun additions
};
// plugin method for blocking element content
$.fn.block = function(opts) {
if ( this[0] === window ) {
$.blockUI( opts );
return this;
}
var fullOpts = $.extend({}, $.blockUI.defaults, opts || {});
this.each(function() {
var $el = $(this);
if (fullOpts.ignoreIfBlocked && $el.data('blockUI.isBlocked'))
return;
$el.unblock({ fadeOut: 0 });
});
return this.each(function() {
if ($.css(this,'position') == 'static') {
this.style.position = 'relative';
$(this).data('blockUI.static', true);
}
this.style.zoom = 1; // force 'hasLayout' in ie
install(this, opts);
});
};
// plugin method for unblocking element content
$.fn.unblock = function(opts) {
if ( this[0] === window ) {
$.unblockUI( opts );
return this;
}
return this.each(function() {
remove(this, opts);
});
};
$.blockUI.version = 2.70; // 2nd generation blocking at no extra cost!
// override these in your code to change the default behavior and style
$.blockUI.defaults = {
// message displayed when blocking (use null for no message)
message: '<div class="loaderbox"><div class="loading-activity"></div> 加载中......</div>',
title: null, // title string; only used when theme == true
draggable: true, // only used when theme == true (requires jquery-ui.js to be loaded)
theme: false, // set to true to use with jQuery UI themes
// styles for the message when blocking; if you wish to disable
// these and use an external stylesheet then do this in your code:
// $.blockUI.defaults.css = {};
css: {
padding: 0,
margin: 0,
width: '30%',
top: '40%',
left: '35%',
textAlign: 'center',
color: '#000',
border: '0px',
backgroundColor:'transparent',
cursor: 'wait'
},
// minimal style set used when themes are used
themedCSS: {
width: '30%',
top: '40%',
left: '35%'
},
// styles for the overlay
overlayCSS: {
backgroundColor: '#000',
opacity: 0.6,
cursor: 'wait'
},
// style to replace wait cursor before unblocking to correct issue
// of lingering wait cursor
cursorReset: 'default',
// styles applied when using $.growlUI
growlCSS: {
width: '350px',
top: '10px',
left: '',
right: '10px',
border: 'none',
padding: '5px',
opacity: 0.6,
cursor: 'default',
color: '#fff',
backgroundColor: '#000',
'-webkit-border-radius':'10px',
'-moz-border-radius': '10px',
'border-radius': '10px'
},
// IE issues: 'about:blank' fails on HTTPS and javascript:false is s-l-o-w
// (hat tip to Jorge H. N. de Vasconcelos)
/*jshint scripturl:true */
iframeSrc: /^https/i.test(window.location.href || '') ? 'javascript:false' : 'about:blank',
// force usage of iframe in non-IE browsers (handy for blocking applets)
forceIframe: false,
// z-index for the blocking overlay
baseZ: 1000,
// set these to true to have the message automatically centered
centerX: true, // <-- only effects element blocking (page block controlled via css above)
centerY: true,
// allow body element to be stetched in ie6; this makes blocking look better
// on "short" pages. disable if you wish to prevent changes to the body height
allowBodyStretch: true,
// enable if you want key and mouse events to be disabled for content that is blocked
bindEvents: true,
// be default blockUI will supress tab navigation from leaving blocking content
// (if bindEvents is true)
constrainTabKey: true,
// fadeIn time in millis; set to 0 to disable fadeIn on block
fadeIn: 200,
// fadeOut time in millis; set to 0 to disable fadeOut on unblock
fadeOut: 400,
// time in millis to wait before auto-unblocking; set to 0 to disable auto-unblock
timeout: 0,
// disable if you don't want to show the overlay
showOverlay: true,
// if true, focus will be placed in the first available input field when
// page blocking
focusInput: true,
// elements that can receive focus
focusableElements: ':input:enabled:visible',
// suppresses the use of overlay styles on FF/Linux (due to performance issues with opacity)
// no longer needed in 2012
// applyPlatformOpacityRules: true,
// callback method invoked when fadeIn has completed and blocking message is visible
onBlock: null,
// callback method invoked when unblocking has completed; the callback is
// passed the element that has been unblocked (which is the window object for page
// blocks) and the options that were passed to the unblock call:
// onUnblock(element, options)
onUnblock: null,
// callback method invoked when the overlay area is clicked.
// setting this will turn the cursor to a pointer, otherwise cursor defined in overlayCss will be used.
onOverlayClick: null,
// don't ask; if you really must know: http://groups.google.com/group/jquery-en/browse_thread/thread/36640a8730503595/2f6a79a77a78e493#2f6a79a77a78e493
quirksmodeOffsetHack: 4,
// class name of the message block
blockMsgClass: 'blockMsg',
// if it is already blocked, then ignore it (don't unblock and reblock)
ignoreIfBlocked: false
};
// private data and functions follow...
var pageBlock = null;
var pageBlockEls = [];
function install(el, opts) {
var css, themedCSS;
var full = (el == window);
var msg = (opts && opts.message !== undefined ? opts.message : undefined);
opts = $.extend({}, $.blockUI.defaults, opts || {});
if (opts.ignoreIfBlocked && $(el).data('blockUI.isBlocked'))
return;
opts.overlayCSS = $.extend({}, $.blockUI.defaults.overlayCSS, opts.overlayCSS || {});
css = $.extend({}, $.blockUI.defaults.css, opts.css || {});
if (opts.onOverlayClick)
opts.overlayCSS.cursor = 'pointer';
themedCSS = $.extend({}, $.blockUI.defaults.themedCSS, opts.themedCSS || {});
msg = msg === undefined ? opts.message : msg;
// remove the current block (if there is one)
if (full && pageBlock)
remove(window, {fadeOut:0});
// if an existing element is being used as the blocking content then we capture
// its current place in the DOM (and current display style) so we can restore
// it when we unblock
if (msg && typeof msg != 'string' && (msg.parentNode || msg.jquery)) {
var node = msg.jquery ? msg[0] : msg;
var data = {};
$(el).data('blockUI.history', data);
data.el = node;
data.parent = node.parentNode;
data.display = node.style.display;
data.position = node.style.position;
if (data.parent)
data.parent.removeChild(node);
}
$(el).data('blockUI.onUnblock', opts.onUnblock);
var z = opts.baseZ;
// blockUI uses 3 layers for blocking, for simplicity they are all used on every platform;
// layer1 is the iframe layer which is used to supress bleed through of underlying content
// layer2 is the overlay layer which has opacity and a wait cursor (by default)
// layer3 is the message content that is displayed while blocking
var lyr1, lyr2, lyr3, s;
if (msie || opts.forceIframe)
lyr1 = $('<iframe class="blockUI" style="z-index:'+ (z++) +';display:none;border:none;margin:0;padding:0;position:absolute;width:100%;height:100%;top:0;left:0" src="'+opts.iframeSrc+'"></iframe>');
else
lyr1 = $('<div class="blockUI" style="display:none"></div>');
if (opts.theme)
lyr2 = $('<div class="blockUI blockOverlay ui-widget-overlay" style="z-index:'+ (z++) +';display:none"></div>');
else
lyr2 = $('<div class="blockUI blockOverlay" style="z-index:'+ (z++) +';display:none;border:none;margin:0;padding:0;width:100%;height:100%;top:0;left:0"></div>');
if (opts.theme && full) {
s = '<div class="blockUI ' + opts.blockMsgClass + ' blockPage ui-dialog ui-widget ui-corner-all" style="z-index:'+(z+10)+';display:none;position:fixed">';
if ( opts.title ) {
s += '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">'+(opts.title || '&nbsp;')+'</div>';
}
s += '<div class="ui-widget-content ui-dialog-content"></div>';
s += '</div>';
}
else if (opts.theme) {
s = '<div class="blockUI ' + opts.blockMsgClass + ' blockElement ui-dialog ui-widget ui-corner-all" style="z-index:'+(z+10)+';display:none;position:absolute">';
if ( opts.title ) {
s += '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">'+(opts.title || '&nbsp;')+'</div>';
}
s += '<div class="ui-widget-content ui-dialog-content"></div>';
s += '</div>';
}
else if (full) {
s = '<div class="blockUI ' + opts.blockMsgClass + ' blockPage" style="z-index:'+(z+10)+';display:none;position:fixed"></div>';
}
else {
s = '<div class="blockUI ' + opts.blockMsgClass + ' blockElement" style="z-index:'+(z+10)+';display:none;position:absolute"></div>';
}
lyr3 = $(s);
// if we have a message, style it
if (msg) {
if (opts.theme) {
lyr3.css(themedCSS);
lyr3.addClass('ui-widget-content');
}
else
lyr3.css(css);
}
// style the overlay
if (!opts.theme /*&& (!opts.applyPlatformOpacityRules)*/)
lyr2.css(opts.overlayCSS);
lyr2.css('position', full ? 'fixed' : 'absolute');
// make iframe layer transparent in IE
if (msie || opts.forceIframe)
lyr1.css('opacity',0.0);
//$([lyr1[0],lyr2[0],lyr3[0]]).appendTo(full ? 'body' : el);
var layers = [lyr1,lyr2,lyr3], $par = full ? $('body') : $(el);
$.each(layers, function() {
this.appendTo($par);
});
if (opts.theme && opts.draggable && $.fn.draggable) {
lyr3.draggable({
handle: '.ui-dialog-titlebar',
cancel: 'li'
});
}
// ie7 must use absolute positioning in quirks mode and to account for activex issues (when scrolling)
var expr = setExpr && (!$.support.boxModel || $('object,embed', full ? null : el).length > 0);
if (ie6 || expr) {
// give body 100% height
if (full && opts.allowBodyStretch && $.support.boxModel)
$('html,body').css('height','100%');
// fix ie6 issue when blocked element has a border width
if ((ie6 || !$.support.boxModel) && !full) {
var t = sz(el,'borderTopWidth'), l = sz(el,'borderLeftWidth');
var fixT = t ? '(0 - '+t+')' : 0;
var fixL = l ? '(0 - '+l+')' : 0;
}
// simulate fixed position
$.each(layers, function(i,o) {
var s = o[0].style;
s.position = 'absolute';
if (i < 2) {
if (full)
s.setExpression('height','Math.max(document.body.scrollHeight, document.body.offsetHeight) - (jQuery.support.boxModel?0:'+opts.quirksmodeOffsetHack+') + "px"');
else
s.setExpression('height','this.parentNode.offsetHeight + "px"');
if (full)
s.setExpression('width','jQuery.support.boxModel && document.documentElement.clientWidth || document.body.clientWidth + "px"');
else
s.setExpression('width','this.parentNode.offsetWidth + "px"');
if (fixL) s.setExpression('left', fixL);
if (fixT) s.setExpression('top', fixT);
}
else if (opts.centerY) {
if (full) s.setExpression('top','(document.documentElement.clientHeight || document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "px"');
s.marginTop = 0;
}
else if (!opts.centerY && full) {
var top = (opts.css && opts.css.top) ? parseInt(opts.css.top, 10) : 0;
var expression = '((document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + '+top+') + "px"';
s.setExpression('top',expression);
}
});
}
// show the message
if (msg) {
if (opts.theme)
lyr3.find('.ui-widget-content').append(msg);
else
lyr3.append(msg);
if (msg.jquery || msg.nodeType)
$(msg).show();
}
if ((msie || opts.forceIframe) && opts.showOverlay)
lyr1.show(); // opacity is zero
if (opts.fadeIn) {
var cb = opts.onBlock ? opts.onBlock : noOp;
var cb1 = (opts.showOverlay && !msg) ? cb : noOp;
var cb2 = msg ? cb : noOp;
if (opts.showOverlay)
lyr2._fadeIn(opts.fadeIn, cb1);
if (msg)
lyr3._fadeIn(opts.fadeIn, cb2);
}
else {
if (opts.showOverlay)
lyr2.show();
if (msg)
lyr3.show();
if (opts.onBlock)
opts.onBlock.bind(lyr3)();
}
// bind key and mouse events
bind(1, el, opts);
if (full) {
pageBlock = lyr3[0];
pageBlockEls = $(opts.focusableElements,pageBlock);
if (opts.focusInput)
setTimeout(focus, 20);
}
else
center(lyr3[0], opts.centerX, opts.centerY);
if (opts.timeout) {
// auto-unblock
var to = setTimeout(function() {
if (full)
$.unblockUI(opts);
else
$(el).unblock(opts);
}, opts.timeout);
$(el).data('blockUI.timeout', to);
}
}
// remove the block
function remove(el, opts) {
var count;
var full = (el == window);
var $el = $(el);
var data = $el.data('blockUI.history');
var to = $el.data('blockUI.timeout');
if (to) {
clearTimeout(to);
$el.removeData('blockUI.timeout');
}
opts = $.extend({}, $.blockUI.defaults, opts || {});
bind(0, el, opts); // unbind events
if (opts.onUnblock === null) {
opts.onUnblock = $el.data('blockUI.onUnblock');
$el.removeData('blockUI.onUnblock');
}
var els;
if (full) // crazy selector to handle odd field errors in ie6/7
els = $('body').children().filter('.blockUI').add('body > .blockUI');
else
els = $el.find('>.blockUI');
// fix cursor issue
if ( opts.cursorReset ) {
if ( els.length > 1 )
els[1].style.cursor = opts.cursorReset;
if ( els.length > 2 )
els[2].style.cursor = opts.cursorReset;
}
if (full)
pageBlock = pageBlockEls = null;
if (opts.fadeOut) {
count = els.length;
els.stop().fadeOut(opts.fadeOut, function() {
if ( --count === 0)
reset(els,data,opts,el);
});
}
else
reset(els, data, opts, el);
}
// move blocking element back into the DOM where it started
function reset(els,data,opts,el) {
var $el = $(el);
if ( $el.data('blockUI.isBlocked') )
return;
els.each(function(i,o) {
// remove via DOM calls so we don't lose event handlers
if (this.parentNode)
this.parentNode.removeChild(this);
});
if (data && data.el) {
data.el.style.display = data.display;
data.el.style.position = data.position;
data.el.style.cursor = 'default'; // #59
if (data.parent)
data.parent.appendChild(data.el);
$el.removeData('blockUI.history');
}
if ($el.data('blockUI.static')) {
$el.css('position', 'static'); // #22
}
if (typeof opts.onUnblock == 'function')
opts.onUnblock(el,opts);
// fix issue in Safari 6 where block artifacts remain until reflow
var body = $(document.body), w = body.width(), cssW = body[0].style.width;
body.width(w-1).width(w);
body[0].style.width = cssW;
}
// bind/unbind the handler
function bind(b, el, opts) {
var full = el == window, $el = $(el);
// don't bother unbinding if there is nothing to unbind
if (!b && (full && !pageBlock || !full && !$el.data('blockUI.isBlocked')))
return;
$el.data('blockUI.isBlocked', b);
// don't bind events when overlay is not in use or if bindEvents is false
if (!full || !opts.bindEvents || (b && !opts.showOverlay))
return;
// bind anchors and inputs for mouse and key events
var events = 'mousedown mouseup keydown keypress keyup touchstart touchend touchmove';
if (b)
$(document).bind(events, opts, handler);
else
$(document).unbind(events, handler);
// former impl...
// var $e = $('a,:input');
// b ? $e.bind(events, opts, handler) : $e.unbind(events, handler);
}
// event handler to suppress keyboard/mouse events when blocking
function handler(e) {
// allow tab navigation (conditionally)
if (e.type === 'keydown' && e.keyCode && e.keyCode == 9) {
if (pageBlock && e.data.constrainTabKey) {
var els = pageBlockEls;
var fwd = !e.shiftKey && e.target === els[els.length-1];
var back = e.shiftKey && e.target === els[0];
if (fwd || back) {
setTimeout(function(){focus(back);},10);
return false;
}
}
}
var opts = e.data;
var target = $(e.target);
if (target.hasClass('blockOverlay') && opts.onOverlayClick)
opts.onOverlayClick(e);
// allow events within the message content
if (target.parents('div.' + opts.blockMsgClass).length > 0)
return true;
// allow events for content that is not being blocked
return target.parents().children().filter('div.blockUI').length === 0;
}
function focus(back) {
if (!pageBlockEls)
return;
var e = pageBlockEls[back===true ? pageBlockEls.length-1 : 0];
if (e)
e.focus();
}
function center(el, x, y) {
var p = el.parentNode, s = el.style;
var l = ((p.offsetWidth - el.offsetWidth)/2) - sz(p,'borderLeftWidth');
var t = ((p.offsetHeight - el.offsetHeight)/2) - sz(p,'borderTopWidth');
if (x) s.left = l > 0 ? (l+'px') : '0';
if (y) s.top = t > 0 ? (t+'px') : '0';
}
function sz(el, p) {
return parseInt($.css(el,p),10)||0;
}
}
/*global define:true */
if (typeof define === 'function' && define.amd && define.amd.jQuery) {
define(['jquery'], setup);
} else {
setup(jQuery);
}
})();
\ No newline at end of file
/**
* @name jQuery FullScreen Plugin
* @author Martin Angelov, Morten Sjøgren
* @version 1.2
* @url http://tutorialzine.com/2012/02/enhance-your-website-fullscreen-api/
* @license MIT License
*/
/*jshint browser: true, jquery: true */
(function($){
"use strict";
// These helper functions available only to our plugin scope.
function supportFullScreen(){
var doc = document.documentElement;
return ('requestFullscreen' in doc) ||
('mozRequestFullScreen' in doc && document.mozFullScreenEnabled) ||
('webkitRequestFullScreen' in doc);
}
function requestFullScreen(elem){
if (elem.requestFullscreen) {
elem.requestFullscreen();
} else if (elem.mozRequestFullScreen) {
elem.mozRequestFullScreen();
} else if (elem.webkitRequestFullScreen) {
elem.webkitRequestFullScreen(Element.ALLOW_KEYBOARD_INPUT);
}
}
function fullScreenStatus(){
return document.fullscreen ||
document.mozFullScreen ||
document.webkitIsFullScreen ||
false;
}
function cancelFullScreen(){
if (document.exitFullscreen) {
document.exitFullscreen();
} else if (document.mozCancelFullScreen) {
document.mozCancelFullScreen();
} else if (document.webkitCancelFullScreen) {
document.webkitCancelFullScreen();
}
}
function onFullScreenEvent(callback){
$(document).on("fullscreenchange mozfullscreenchange webkitfullscreenchange", function(){
// The full screen status is automatically
// passed to our callback as an argument.
callback(fullScreenStatus());
});
}
// Adding a new test to the jQuery support object
$.support.fullscreen = supportFullScreen();
// Creating the plugin
$.fn.fullScreen = function(props){
if(!$.support.fullscreen || this.length !== 1) {
// The plugin can be called only
// on one element at a time
return this;
}
if(fullScreenStatus()){
// if we are already in fullscreen, exit
cancelFullScreen();
return this;
}
// You can potentially pas two arguments a color
// for the background and a callback function
var options = $.extend({
'background' : '#111',
'callback' : $.noop( ),
'fullscreenClass' : 'fullScreen'
}, props),
elem = this,
// This temporary div is the element that is
// actually going to be enlarged in full screen
fs = $('<div>', {
'css' : {
'overflow-y' : 'auto',
'background' : options.background,
'width' : '100%',
'height' : '100%'
}
})
.insertBefore(elem)
.append(elem);
// You can use the .fullScreen class to
// apply styling to your element
elem.addClass( options.fullscreenClass );
// Inserting our element in the temporary
// div, after which we zoom it in fullscreen
requestFullScreen(fs.get(0));
fs.click(function(e){
if(e.target == this){
// If the black bar was clicked
cancelFullScreen();
}
});
elem.cancel = function(){
cancelFullScreen();
return elem;
};
onFullScreenEvent(function(fullScreen){
if(!fullScreen){
// We have exited full screen.
// Detach event listener
$(document).off( 'fullscreenchange mozfullscreenchange webkitfullscreenchange' );
// Remove the class and destroy
// the temporary div
elem.removeClass( options.fullscreenClass ).insertBefore(fs);
fs.remove();
}
// Calling the facultative user supplied callback
if(options.callback) {
options.callback(fullScreen);
}
});
return elem;
};
$.fn.cancelFullScreen = function( ) {
cancelFullScreen();
return this;
};
}(jQuery));
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
/*!
* Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome
* License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License)
*/@font-face{font-family:'FontAwesome';src:url('../fonts/fontawesome-webfont.eot?v=4.7.0');src:url('../fonts/fontawesome-webfont.eot?#iefix&v=4.7.0') format('embedded-opentype'),url('../fonts/fontawesome-webfont.woff2?v=4.7.0') format('woff2'),url('../fonts/fontawesome-webfont.woff?v=4.7.0') format('woff'),url('../fonts/fontawesome-webfont.ttf?v=4.7.0') format('truetype'),url('../fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular') format('svg');font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{left:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left{margin-right:.3em}.fa.fa-pull-right{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);-ms-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);-ms-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:"\f000"}.fa-music:before{content:"\f001"}.fa-search:before{content:"\f002"}.fa-envelope-o:before{content:"\f003"}.fa-heart:before{content:"\f004"}.fa-star:before{content:"\f005"}.fa-star-o:before{content:"\f006"}.fa-user:before{content:"\f007"}.fa-film:before{content:"\f008"}.fa-th-large:before{content:"\f009"}.fa-th:before{content:"\f00a"}.fa-th-list:before{content:"\f00b"}.fa-check:before{content:"\f00c"}.fa-remove:before,.fa-close:before,.fa-times:before{content:"\f00d"}.fa-search-plus:before{content:"\f00e"}.fa-search-minus:before{content:"\f010"}.fa-power-off:before{content:"\f011"}.fa-signal:before{content:"\f012"}.fa-gear:before,.fa-cog:before{content:"\f013"}.fa-trash-o:before{content:"\f014"}.fa-home:before{content:"\f015"}.fa-file-o:before{content:"\f016"}.fa-clock-o:before{content:"\f017"}.fa-road:before{content:"\f018"}.fa-download:before{content:"\f019"}.fa-arrow-circle-o-down:before{content:"\f01a"}.fa-arrow-circle-o-up:before{content:"\f01b"}.fa-inbox:before{content:"\f01c"}.fa-play-circle-o:before{content:"\f01d"}.fa-rotate-right:before,.fa-repeat:before{content:"\f01e"}.fa-refresh:before{content:"\f021"}.fa-list-alt:before{content:"\f022"}.fa-lock:before{content:"\f023"}.fa-flag:before{content:"\f024"}.fa-headphones:before{content:"\f025"}.fa-volume-off:before{content:"\f026"}.fa-volume-down:before{content:"\f027"}.fa-volume-up:before{content:"\f028"}.fa-qrcode:before{content:"\f029"}.fa-barcode:before{content:"\f02a"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-book:before{content:"\f02d"}.fa-bookmark:before{content:"\f02e"}.fa-print:before{content:"\f02f"}.fa-camera:before{content:"\f030"}.fa-font:before{content:"\f031"}.fa-bold:before{content:"\f032"}.fa-italic:before{content:"\f033"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-align-left:before{content:"\f036"}.fa-align-center:before{content:"\f037"}.fa-align-right:before{content:"\f038"}.fa-align-justify:before{content:"\f039"}.fa-list:before{content:"\f03a"}.fa-dedent:before,.fa-outdent:before{content:"\f03b"}.fa-indent:before{content:"\f03c"}.fa-video-camera:before{content:"\f03d"}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:"\f03e"}.fa-pencil:before{content:"\f040"}.fa-map-marker:before{content:"\f041"}.fa-adjust:before{content:"\f042"}.fa-tint:before{content:"\f043"}.fa-edit:before,.fa-pencil-square-o:before{content:"\f044"}.fa-share-square-o:before{content:"\f045"}.fa-check-square-o:before{content:"\f046"}.fa-arrows:before{content:"\f047"}.fa-step-backward:before{content:"\f048"}.fa-fast-backward:before{content:"\f049"}.fa-backward:before{content:"\f04a"}.fa-play:before{content:"\f04b"}.fa-pause:before{content:"\f04c"}.fa-stop:before{content:"\f04d"}.fa-forward:before{content:"\f04e"}.fa-fast-forward:before{content:"\f050"}.fa-step-forward:before{content:"\f051"}.fa-eject:before{content:"\f052"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-plus-circle:before{content:"\f055"}.fa-minus-circle:before{content:"\f056"}.fa-times-circle:before{content:"\f057"}.fa-check-circle:before{content:"\f058"}.fa-question-circle:before{content:"\f059"}.fa-info-circle:before{content:"\f05a"}.fa-crosshairs:before{content:"\f05b"}.fa-times-circle-o:before{content:"\f05c"}.fa-check-circle-o:before{content:"\f05d"}.fa-ban:before{content:"\f05e"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrow-down:before{content:"\f063"}.fa-mail-forward:before,.fa-share:before{content:"\f064"}.fa-expand:before{content:"\f065"}.fa-compress:before{content:"\f066"}.fa-plus:before{content:"\f067"}.fa-minus:before{content:"\f068"}.fa-asterisk:before{content:"\f069"}.fa-exclamation-circle:before{content:"\f06a"}.fa-gift:before{content:"\f06b"}.fa-leaf:before{content:"\f06c"}.fa-fire:before{content:"\f06d"}.fa-eye:before{content:"\f06e"}.fa-eye-slash:before{content:"\f070"}.fa-warning:before,.fa-exclamation-triangle:before{content:"\f071"}.fa-plane:before{content:"\f072"}.fa-calendar:before{content:"\f073"}.fa-random:before{content:"\f074"}.fa-comment:before{content:"\f075"}.fa-magnet:before{content:"\f076"}.fa-chevron-up:before{content:"\f077"}.fa-chevron-down:before{content:"\f078"}.fa-retweet:before{content:"\f079"}.fa-shopping-cart:before{content:"\f07a"}.fa-folder:before{content:"\f07b"}.fa-folder-open:before{content:"\f07c"}.fa-arrows-v:before{content:"\f07d"}.fa-arrows-h:before{content:"\f07e"}.fa-bar-chart-o:before,.fa-bar-chart:before{content:"\f080"}.fa-twitter-square:before{content:"\f081"}.fa-facebook-square:before{content:"\f082"}.fa-camera-retro:before{content:"\f083"}.fa-key:before{content:"\f084"}.fa-gears:before,.fa-cogs:before{content:"\f085"}.fa-comments:before{content:"\f086"}.fa-thumbs-o-up:before{content:"\f087"}.fa-thumbs-o-down:before{content:"\f088"}.fa-star-half:before{content:"\f089"}.fa-heart-o:before{content:"\f08a"}.fa-sign-out:before{content:"\f08b"}.fa-linkedin-square:before{content:"\f08c"}.fa-thumb-tack:before{content:"\f08d"}.fa-external-link:before{content:"\f08e"}.fa-sign-in:before{content:"\f090"}.fa-trophy:before{content:"\f091"}.fa-github-square:before{content:"\f092"}.fa-upload:before{content:"\f093"}.fa-lemon-o:before{content:"\f094"}.fa-phone:before{content:"\f095"}.fa-square-o:before{content:"\f096"}.fa-bookmark-o:before{content:"\f097"}.fa-phone-square:before{content:"\f098"}.fa-twitter:before{content:"\f099"}.fa-facebook-f:before,.fa-facebook:before{content:"\f09a"}.fa-github:before{content:"\f09b"}.fa-unlock:before{content:"\f09c"}.fa-credit-card:before{content:"\f09d"}.fa-feed:before,.fa-rss:before{content:"\f09e"}.fa-hdd-o:before{content:"\f0a0"}.fa-bullhorn:before{content:"\f0a1"}.fa-bell:before{content:"\f0f3"}.fa-certificate:before{content:"\f0a3"}.fa-hand-o-right:before{content:"\f0a4"}.fa-hand-o-left:before{content:"\f0a5"}.fa-hand-o-up:before{content:"\f0a6"}.fa-hand-o-down:before{content:"\f0a7"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-globe:before{content:"\f0ac"}.fa-wrench:before{content:"\f0ad"}.fa-tasks:before{content:"\f0ae"}.fa-filter:before{content:"\f0b0"}.fa-briefcase:before{content:"\f0b1"}.fa-arrows-alt:before{content:"\f0b2"}.fa-group:before,.fa-users:before{content:"\f0c0"}.fa-chain:before,.fa-link:before{content:"\f0c1"}.fa-cloud:before{content:"\f0c2"}.fa-flask:before{content:"\f0c3"}.fa-cut:before,.fa-scissors:before{content:"\f0c4"}.fa-copy:before,.fa-files-o:before{content:"\f0c5"}.fa-paperclip:before{content:"\f0c6"}.fa-save:before,.fa-floppy-o:before{content:"\f0c7"}.fa-square:before{content:"\f0c8"}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:"\f0c9"}.fa-list-ul:before{content:"\f0ca"}.fa-list-ol:before{content:"\f0cb"}.fa-strikethrough:before{content:"\f0cc"}.fa-underline:before{content:"\f0cd"}.fa-table:before{content:"\f0ce"}.fa-magic:before{content:"\f0d0"}.fa-truck:before{content:"\f0d1"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-square:before{content:"\f0d3"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-plus:before{content:"\f0d5"}.fa-money:before{content:"\f0d6"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-up:before{content:"\f0d8"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-columns:before{content:"\f0db"}.fa-unsorted:before,.fa-sort:before{content:"\f0dc"}.fa-sort-down:before,.fa-sort-desc:before{content:"\f0dd"}.fa-sort-up:before,.fa-sort-asc:before{content:"\f0de"}.fa-envelope:before{content:"\f0e0"}.fa-linkedin:before{content:"\f0e1"}.fa-rotate-left:before,.fa-undo:before{content:"\f0e2"}.fa-legal:before,.fa-gavel:before{content:"\f0e3"}.fa-dashboard:before,.fa-tachometer:before{content:"\f0e4"}.fa-comment-o:before{content:"\f0e5"}.fa-comments-o:before{content:"\f0e6"}.fa-flash:before,.fa-bolt:before{content:"\f0e7"}.fa-sitemap:before{content:"\f0e8"}.fa-umbrella:before{content:"\f0e9"}.fa-paste:before,.fa-clipboard:before{content:"\f0ea"}.fa-lightbulb-o:before{content:"\f0eb"}.fa-exchange:before{content:"\f0ec"}.fa-cloud-download:before{content:"\f0ed"}.fa-cloud-upload:before{content:"\f0ee"}.fa-user-md:before{content:"\f0f0"}.fa-stethoscope:before{content:"\f0f1"}.fa-suitcase:before{content:"\f0f2"}.fa-bell-o:before{content:"\f0a2"}.fa-coffee:before{content:"\f0f4"}.fa-cutlery:before{content:"\f0f5"}.fa-file-text-o:before{content:"\f0f6"}.fa-building-o:before{content:"\f0f7"}.fa-hospital-o:before{content:"\f0f8"}.fa-ambulance:before{content:"\f0f9"}.fa-medkit:before{content:"\f0fa"}.fa-fighter-jet:before{content:"\f0fb"}.fa-beer:before{content:"\f0fc"}.fa-h-square:before{content:"\f0fd"}.fa-plus-square:before{content:"\f0fe"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angle-down:before{content:"\f107"}.fa-desktop:before{content:"\f108"}.fa-laptop:before{content:"\f109"}.fa-tablet:before{content:"\f10a"}.fa-mobile-phone:before,.fa-mobile:before{content:"\f10b"}.fa-circle-o:before{content:"\f10c"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-spinner:before{content:"\f110"}.fa-circle:before{content:"\f111"}.fa-mail-reply:before,.fa-reply:before{content:"\f112"}.fa-github-alt:before{content:"\f113"}.fa-folder-o:before{content:"\f114"}.fa-folder-open-o:before{content:"\f115"}.fa-smile-o:before{content:"\f118"}.fa-frown-o:before{content:"\f119"}.fa-meh-o:before{content:"\f11a"}.fa-gamepad:before{content:"\f11b"}.fa-keyboard-o:before{content:"\f11c"}.fa-flag-o:before{content:"\f11d"}.fa-flag-checkered:before{content:"\f11e"}.fa-terminal:before{content:"\f120"}.fa-code:before{content:"\f121"}.fa-mail-reply-all:before,.fa-reply-all:before{content:"\f122"}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:"\f123"}.fa-location-arrow:before{content:"\f124"}.fa-crop:before{content:"\f125"}.fa-code-fork:before{content:"\f126"}.fa-unlink:before,.fa-chain-broken:before{content:"\f127"}.fa-question:before{content:"\f128"}.fa-info:before{content:"\f129"}.fa-exclamation:before{content:"\f12a"}.fa-superscript:before{content:"\f12b"}.fa-subscript:before{content:"\f12c"}.fa-eraser:before{content:"\f12d"}.fa-puzzle-piece:before{content:"\f12e"}.fa-microphone:before{content:"\f130"}.fa-microphone-slash:before{content:"\f131"}.fa-shield:before{content:"\f132"}.fa-calendar-o:before{content:"\f133"}.fa-fire-extinguisher:before{content:"\f134"}.fa-rocket:before{content:"\f135"}.fa-maxcdn:before{content:"\f136"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-html5:before{content:"\f13b"}.fa-css3:before{content:"\f13c"}.fa-anchor:before{content:"\f13d"}.fa-unlock-alt:before{content:"\f13e"}.fa-bullseye:before{content:"\f140"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-rss-square:before{content:"\f143"}.fa-play-circle:before{content:"\f144"}.fa-ticket:before{content:"\f145"}.fa-minus-square:before{content:"\f146"}.fa-minus-square-o:before{content:"\f147"}.fa-level-up:before{content:"\f148"}.fa-level-down:before{content:"\f149"}.fa-check-square:before{content:"\f14a"}.fa-pencil-square:before{content:"\f14b"}.fa-external-link-square:before{content:"\f14c"}.fa-share-square:before{content:"\f14d"}.fa-compass:before{content:"\f14e"}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:"\f150"}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:"\f151"}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:"\f152"}.fa-euro:before,.fa-eur:before{content:"\f153"}.fa-gbp:before{content:"\f154"}.fa-dollar:before,.fa-usd:before{content:"\f155"}.fa-rupee:before,.fa-inr:before{content:"\f156"}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:"\f157"}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:"\f158"}.fa-won:before,.fa-krw:before{content:"\f159"}.fa-bitcoin:before,.fa-btc:before{content:"\f15a"}.fa-file:before{content:"\f15b"}.fa-file-text:before{content:"\f15c"}.fa-sort-alpha-asc:before{content:"\f15d"}.fa-sort-alpha-desc:before{content:"\f15e"}.fa-sort-amount-asc:before{content:"\f160"}.fa-sort-amount-desc:before{content:"\f161"}.fa-sort-numeric-asc:before{content:"\f162"}.fa-sort-numeric-desc:before{content:"\f163"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbs-down:before{content:"\f165"}.fa-youtube-square:before{content:"\f166"}.fa-youtube:before{content:"\f167"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-youtube-play:before{content:"\f16a"}.fa-dropbox:before{content:"\f16b"}.fa-stack-overflow:before{content:"\f16c"}.fa-instagram:before{content:"\f16d"}.fa-flickr:before{content:"\f16e"}.fa-adn:before{content:"\f170"}.fa-bitbucket:before{content:"\f171"}.fa-bitbucket-square:before{content:"\f172"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-long-arrow-down:before{content:"\f175"}.fa-long-arrow-up:before{content:"\f176"}.fa-long-arrow-left:before{content:"\f177"}.fa-long-arrow-right:before{content:"\f178"}.fa-apple:before{content:"\f179"}.fa-windows:before{content:"\f17a"}.fa-android:before{content:"\f17b"}.fa-linux:before{content:"\f17c"}.fa-dribbble:before{content:"\f17d"}.fa-skype:before{content:"\f17e"}.fa-foursquare:before{content:"\f180"}.fa-trello:before{content:"\f181"}.fa-female:before{content:"\f182"}.fa-male:before{content:"\f183"}.fa-gittip:before,.fa-gratipay:before{content:"\f184"}.fa-sun-o:before{content:"\f185"}.fa-moon-o:before{content:"\f186"}.fa-archive:before{content:"\f187"}.fa-bug:before{content:"\f188"}.fa-vk:before{content:"\f189"}.fa-weibo:before{content:"\f18a"}.fa-renren:before{content:"\f18b"}.fa-pagelines:before{content:"\f18c"}.fa-stack-exchange:before{content:"\f18d"}.fa-arrow-circle-o-right:before{content:"\f18e"}.fa-arrow-circle-o-left:before{content:"\f190"}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:"\f191"}.fa-dot-circle-o:before{content:"\f192"}.fa-wheelchair:before{content:"\f193"}.fa-vimeo-square:before{content:"\f194"}.fa-turkish-lira:before,.fa-try:before{content:"\f195"}.fa-plus-square-o:before{content:"\f196"}.fa-space-shuttle:before{content:"\f197"}.fa-slack:before{content:"\f198"}.fa-envelope-square:before{content:"\f199"}.fa-wordpress:before{content:"\f19a"}.fa-openid:before{content:"\f19b"}.fa-institution:before,.fa-bank:before,.fa-university:before{content:"\f19c"}.fa-mortar-board:before,.fa-graduation-cap:before{content:"\f19d"}.fa-yahoo:before{content:"\f19e"}.fa-google:before{content:"\f1a0"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-square:before{content:"\f1a2"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-stumbleupon:before{content:"\f1a4"}.fa-delicious:before{content:"\f1a5"}.fa-digg:before{content:"\f1a6"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-drupal:before{content:"\f1a9"}.fa-joomla:before{content:"\f1aa"}.fa-language:before{content:"\f1ab"}.fa-fax:before{content:"\f1ac"}.fa-building:before{content:"\f1ad"}.fa-child:before{content:"\f1ae"}.fa-paw:before{content:"\f1b0"}.fa-spoon:before{content:"\f1b1"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-recycle:before{content:"\f1b8"}.fa-automobile:before,.fa-car:before{content:"\f1b9"}.fa-cab:before,.fa-taxi:before{content:"\f1ba"}.fa-tree:before{content:"\f1bb"}.fa-spotify:before{content:"\f1bc"}.fa-deviantart:before{content:"\f1bd"}.fa-soundcloud:before{content:"\f1be"}.fa-database:before{content:"\f1c0"}.fa-file-pdf-o:before{content:"\f1c1"}.fa-file-word-o:before{content:"\f1c2"}.fa-file-excel-o:before{content:"\f1c3"}.fa-file-powerpoint-o:before{content:"\f1c4"}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:"\f1c5"}.fa-file-zip-o:before,.fa-file-archive-o:before{content:"\f1c6"}.fa-file-sound-o:before,.fa-file-audio-o:before{content:"\f1c7"}.fa-file-movie-o:before,.fa-file-video-o:before{content:"\f1c8"}.fa-file-code-o:before{content:"\f1c9"}.fa-vine:before{content:"\f1ca"}.fa-codepen:before{content:"\f1cb"}.fa-jsfiddle:before{content:"\f1cc"}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:"\f1cd"}.fa-circle-o-notch:before{content:"\f1ce"}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:"\f1d0"}.fa-ge:before,.fa-empire:before{content:"\f1d1"}.fa-git-square:before{content:"\f1d2"}.fa-git:before{content:"\f1d3"}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:"\f1d4"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-qq:before{content:"\f1d6"}.fa-wechat:before,.fa-weixin:before{content:"\f1d7"}.fa-send:before,.fa-paper-plane:before{content:"\f1d8"}.fa-send-o:before,.fa-paper-plane-o:before{content:"\f1d9"}.fa-history:before{content:"\f1da"}.fa-circle-thin:before{content:"\f1db"}.fa-header:before{content:"\f1dc"}.fa-paragraph:before{content:"\f1dd"}.fa-sliders:before{content:"\f1de"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-bomb:before{content:"\f1e2"}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:"\f1e3"}.fa-tty:before{content:"\f1e4"}.fa-binoculars:before{content:"\f1e5"}.fa-plug:before{content:"\f1e6"}.fa-slideshare:before{content:"\f1e7"}.fa-twitch:before{content:"\f1e8"}.fa-yelp:before{content:"\f1e9"}.fa-newspaper-o:before{content:"\f1ea"}.fa-wifi:before{content:"\f1eb"}.fa-calculator:before{content:"\f1ec"}.fa-paypal:before{content:"\f1ed"}.fa-google-wallet:before{content:"\f1ee"}.fa-cc-visa:before{content:"\f1f0"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-bell-slash:before{content:"\f1f6"}.fa-bell-slash-o:before{content:"\f1f7"}.fa-trash:before{content:"\f1f8"}.fa-copyright:before{content:"\f1f9"}.fa-at:before{content:"\f1fa"}.fa-eyedropper:before{content:"\f1fb"}.fa-paint-brush:before{content:"\f1fc"}.fa-birthday-cake:before{content:"\f1fd"}.fa-area-chart:before{content:"\f1fe"}.fa-pie-chart:before{content:"\f200"}.fa-line-chart:before{content:"\f201"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-bicycle:before{content:"\f206"}.fa-bus:before{content:"\f207"}.fa-ioxhost:before{content:"\f208"}.fa-angellist:before{content:"\f209"}.fa-cc:before{content:"\f20a"}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:"\f20b"}.fa-meanpath:before{content:"\f20c"}.fa-buysellads:before{content:"\f20d"}.fa-connectdevelop:before{content:"\f20e"}.fa-dashcube:before{content:"\f210"}.fa-forumbee:before{content:"\f211"}.fa-leanpub:before{content:"\f212"}.fa-sellsy:before{content:"\f213"}.fa-shirtsinbulk:before{content:"\f214"}.fa-simplybuilt:before{content:"\f215"}.fa-skyatlas:before{content:"\f216"}.fa-cart-plus:before{content:"\f217"}.fa-cart-arrow-down:before{content:"\f218"}.fa-diamond:before{content:"\f219"}.fa-ship:before{content:"\f21a"}.fa-user-secret:before{content:"\f21b"}.fa-motorcycle:before{content:"\f21c"}.fa-street-view:before{content:"\f21d"}.fa-heartbeat:before{content:"\f21e"}.fa-venus:before{content:"\f221"}.fa-mars:before{content:"\f222"}.fa-mercury:before{content:"\f223"}.fa-intersex:before,.fa-transgender:before{content:"\f224"}.fa-transgender-alt:before{content:"\f225"}.fa-venus-double:before{content:"\f226"}.fa-mars-double:before{content:"\f227"}.fa-venus-mars:before{content:"\f228"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-v:before{content:"\f22a"}.fa-mars-stroke-h:before{content:"\f22b"}.fa-neuter:before{content:"\f22c"}.fa-genderless:before{content:"\f22d"}.fa-facebook-official:before{content:"\f230"}.fa-pinterest-p:before{content:"\f231"}.fa-whatsapp:before{content:"\f232"}.fa-server:before{content:"\f233"}.fa-user-plus:before{content:"\f234"}.fa-user-times:before{content:"\f235"}.fa-hotel:before,.fa-bed:before{content:"\f236"}.fa-viacoin:before{content:"\f237"}.fa-train:before{content:"\f238"}.fa-subway:before{content:"\f239"}.fa-medium:before{content:"\f23a"}.fa-yc:before,.fa-y-combinator:before{content:"\f23b"}.fa-optin-monster:before{content:"\f23c"}.fa-opencart:before{content:"\f23d"}.fa-expeditedssl:before{content:"\f23e"}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:"\f240"}.fa-battery-3:before,.fa-battery-three-quarters:before{content:"\f241"}.fa-battery-2:before,.fa-battery-half:before{content:"\f242"}.fa-battery-1:before,.fa-battery-quarter:before{content:"\f243"}.fa-battery-0:before,.fa-battery-empty:before{content:"\f244"}.fa-mouse-pointer:before{content:"\f245"}.fa-i-cursor:before{content:"\f246"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-sticky-note:before{content:"\f249"}.fa-sticky-note-o:before{content:"\f24a"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-diners-club:before{content:"\f24c"}.fa-clone:before{content:"\f24d"}.fa-balance-scale:before{content:"\f24e"}.fa-hourglass-o:before{content:"\f250"}.fa-hourglass-1:before,.fa-hourglass-start:before{content:"\f251"}.fa-hourglass-2:before,.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-3:before,.fa-hourglass-end:before{content:"\f253"}.fa-hourglass:before{content:"\f254"}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:"\f255"}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:"\f256"}.fa-hand-scissors-o:before{content:"\f257"}.fa-hand-lizard-o:before{content:"\f258"}.fa-hand-spock-o:before{content:"\f259"}.fa-hand-pointer-o:before{content:"\f25a"}.fa-hand-peace-o:before{content:"\f25b"}.fa-trademark:before{content:"\f25c"}.fa-registered:before{content:"\f25d"}.fa-creative-commons:before{content:"\f25e"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-tripadvisor:before{content:"\f262"}.fa-odnoklassniki:before{content:"\f263"}.fa-odnoklassniki-square:before{content:"\f264"}.fa-get-pocket:before{content:"\f265"}.fa-wikipedia-w:before{content:"\f266"}.fa-safari:before{content:"\f267"}.fa-chrome:before{content:"\f268"}.fa-firefox:before{content:"\f269"}.fa-opera:before{content:"\f26a"}.fa-internet-explorer:before{content:"\f26b"}.fa-tv:before,.fa-television:before{content:"\f26c"}.fa-contao:before{content:"\f26d"}.fa-500px:before{content:"\f26e"}.fa-amazon:before{content:"\f270"}.fa-calendar-plus-o:before{content:"\f271"}.fa-calendar-minus-o:before{content:"\f272"}.fa-calendar-times-o:before{content:"\f273"}.fa-calendar-check-o:before{content:"\f274"}.fa-industry:before{content:"\f275"}.fa-map-pin:before{content:"\f276"}.fa-map-signs:before{content:"\f277"}.fa-map-o:before{content:"\f278"}.fa-map:before{content:"\f279"}.fa-commenting:before{content:"\f27a"}.fa-commenting-o:before{content:"\f27b"}.fa-houzz:before{content:"\f27c"}.fa-vimeo:before{content:"\f27d"}.fa-black-tie:before{content:"\f27e"}.fa-fonticons:before{content:"\f280"}.fa-reddit-alien:before{content:"\f281"}.fa-edge:before{content:"\f282"}.fa-credit-card-alt:before{content:"\f283"}.fa-codiepie:before{content:"\f284"}.fa-modx:before{content:"\f285"}.fa-fort-awesome:before{content:"\f286"}.fa-usb:before{content:"\f287"}.fa-product-hunt:before{content:"\f288"}.fa-mixcloud:before{content:"\f289"}.fa-scribd:before{content:"\f28a"}.fa-pause-circle:before{content:"\f28b"}.fa-pause-circle-o:before{content:"\f28c"}.fa-stop-circle:before{content:"\f28d"}.fa-stop-circle-o:before{content:"\f28e"}.fa-shopping-bag:before{content:"\f290"}.fa-shopping-basket:before{content:"\f291"}.fa-hashtag:before{content:"\f292"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-percent:before{content:"\f295"}.fa-gitlab:before{content:"\f296"}.fa-wpbeginner:before{content:"\f297"}.fa-wpforms:before{content:"\f298"}.fa-envira:before{content:"\f299"}.fa-universal-access:before{content:"\f29a"}.fa-wheelchair-alt:before{content:"\f29b"}.fa-question-circle-o:before{content:"\f29c"}.fa-blind:before{content:"\f29d"}.fa-audio-description:before{content:"\f29e"}.fa-volume-control-phone:before{content:"\f2a0"}.fa-braille:before{content:"\f2a1"}.fa-assistive-listening-systems:before{content:"\f2a2"}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:"\f2a3"}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:"\f2a4"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-signing:before,.fa-sign-language:before{content:"\f2a7"}.fa-low-vision:before{content:"\f2a8"}.fa-viadeo:before{content:"\f2a9"}.fa-viadeo-square:before{content:"\f2aa"}.fa-snapchat:before{content:"\f2ab"}.fa-snapchat-ghost:before{content:"\f2ac"}.fa-snapchat-square:before{content:"\f2ad"}.fa-pied-piper:before{content:"\f2ae"}.fa-first-order:before{content:"\f2b0"}.fa-yoast:before{content:"\f2b1"}.fa-themeisle:before{content:"\f2b2"}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:"\f2b3"}.fa-fa:before,.fa-font-awesome:before{content:"\f2b4"}.fa-handshake-o:before{content:"\f2b5"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-open-o:before{content:"\f2b7"}.fa-linode:before{content:"\f2b8"}.fa-address-book:before{content:"\f2b9"}.fa-address-book-o:before{content:"\f2ba"}.fa-vcard:before,.fa-address-card:before{content:"\f2bb"}.fa-vcard-o:before,.fa-address-card-o:before{content:"\f2bc"}.fa-user-circle:before{content:"\f2bd"}.fa-user-circle-o:before{content:"\f2be"}.fa-user-o:before{content:"\f2c0"}.fa-id-badge:before{content:"\f2c1"}.fa-drivers-license:before,.fa-id-card:before{content:"\f2c2"}.fa-drivers-license-o:before,.fa-id-card-o:before{content:"\f2c3"}.fa-quora:before{content:"\f2c4"}.fa-free-code-camp:before{content:"\f2c5"}.fa-telegram:before{content:"\f2c6"}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:"\f2c7"}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-thermometer-2:before,.fa-thermometer-half:before{content:"\f2c9"}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:"\f2ca"}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:"\f2cb"}.fa-shower:before{content:"\f2cc"}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:"\f2cd"}.fa-podcast:before{content:"\f2ce"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-times-rectangle:before,.fa-window-close:before{content:"\f2d3"}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:"\f2d4"}.fa-bandcamp:before{content:"\f2d5"}.fa-grav:before{content:"\f2d6"}.fa-etsy:before{content:"\f2d7"}.fa-imdb:before{content:"\f2d8"}.fa-ravelry:before{content:"\f2d9"}.fa-eercast:before{content:"\f2da"}.fa-microchip:before{content:"\f2db"}.fa-snowflake-o:before{content:"\f2dc"}.fa-superpowers:before{content:"\f2dd"}.fa-wpexplorer:before{content:"\f2de"}.fa-meetup:before{content:"\f2e0"}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}
.toast-title {
font-weight: 700
}
.toast-message {
-ms-word-wrap: break-word;
word-wrap: break-word
}
.toast-message a, .toast-message label {
color: #fff
}
.toast-message a:hover {
color: #ccc;
text-decoration: none
}
.toast-close-button {
position: relative;
right: -.3em;
top: -.3em;
float: right;
font-size: 20px;
font-weight: 700;
color: #fff;
-webkit-text-shadow: 0 1px 0 #fff;
text-shadow: 0 1px 0 #fff;
opacity: .8;
-ms-filter: alpha(Opacity=80);
filter: alpha(opacity=80)
}
.toast-close-button:focus, .toast-close-button:hover {
color: #000;
text-decoration: none;
cursor: pointer;
opacity: .4;
-ms-filter: alpha(Opacity=40);
filter: alpha(opacity=40)
}
button.toast-close-button {
padding: 0;
cursor: pointer;
background: 0 0;
border: 0;
-webkit-appearance: none
}
.toast-top-center {
top: 0;
right: 0;
width: 100%
}
.toast-bottom-center {
bottom: 0;
right: 0;
width: 100%
}
.toast-top-full-width {
top: 0;
right: 0;
width: 100%
}
.toast-bottom-full-width {
bottom: 0;
right: 0;
width: 100%
}
.toast-top-left {
top: 12px;
left: 12px
}
.toast-top-right {
top: 12px;
right: 12px
}
.toast-bottom-right {
right: 12px;
bottom: 12px
}
.toast-bottom-left {
bottom: 12px;
left: 12px
}
#toast-container {
position: fixed;
z-index: 999999
}
#toast-container * {
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box
}
#toast-container > div {
position: relative;
overflow: hidden;
margin: 0 0 6px;
padding: 15px 15px 15px 50px;
width: 300px;
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
background-position: 15px center;
background-repeat: no-repeat;
-moz-box-shadow: 0 0 12px #999;
-webkit-box-shadow: 0 0 12px #999;
box-shadow: 0 0 12px #999;
color: #fff;
opacity: .8;
-ms-filter: alpha(Opacity=80);
filter: alpha(opacity=80)
}
#toast-container > :hover {
-moz-box-shadow: 0 0 12px #000;
-webkit-box-shadow: 0 0 12px #000;
box-shadow: 0 0 12px #000;
opacity: 1;
-ms-filter: alpha(Opacity=100);
filter: alpha(opacity=100);
cursor: pointer
}
#toast-container > .toast-info {
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=) !important
}
#toast-container > .toast-error {
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHOSURBVEhLrZa/SgNBEMZzh0WKCClSCKaIYOED+AAKeQQLG8HWztLCImBrYadgIdY+gIKNYkBFSwu7CAoqCgkkoGBI/E28PdbLZmeDLgzZzcx83/zZ2SSXC1j9fr+I1Hq93g2yxH4iwM1vkoBWAdxCmpzTxfkN2RcyZNaHFIkSo10+8kgxkXIURV5HGxTmFuc75B2RfQkpxHG8aAgaAFa0tAHqYFfQ7Iwe2yhODk8+J4C7yAoRTWI3w/4klGRgR4lO7Rpn9+gvMyWp+uxFh8+H+ARlgN1nJuJuQAYvNkEnwGFck18Er4q3egEc/oO+mhLdKgRyhdNFiacC0rlOCbhNVz4H9FnAYgDBvU3QIioZlJFLJtsoHYRDfiZoUyIxqCtRpVlANq0EU4dApjrtgezPFad5S19Wgjkc0hNVnuF4HjVA6C7QrSIbylB+oZe3aHgBsqlNqKYH48jXyJKMuAbiyVJ8KzaB3eRc0pg9VwQ4niFryI68qiOi3AbjwdsfnAtk0bCjTLJKr6mrD9g8iq/S/B81hguOMlQTnVyG40wAcjnmgsCNESDrjme7wfftP4P7SP4N3CJZdvzoNyGq2c/HWOXJGsvVg+RA/k2MC/wN6I2YA2Pt8GkAAAAASUVORK5CYII=) !important
}
#toast-container > .toast-success {
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAADsSURBVEhLY2AYBfQMgf///3P8+/evAIgvA/FsIF+BavYDDWMBGroaSMMBiE8VC7AZDrIFaMFnii3AZTjUgsUUWUDA8OdAH6iQbQEhw4HyGsPEcKBXBIC4ARhex4G4BsjmweU1soIFaGg/WtoFZRIZdEvIMhxkCCjXIVsATV6gFGACs4Rsw0EGgIIH3QJYJgHSARQZDrWAB+jawzgs+Q2UO49D7jnRSRGoEFRILcdmEMWGI0cm0JJ2QpYA1RDvcmzJEWhABhD/pqrL0S0CWuABKgnRki9lLseS7g2AlqwHWQSKH4oKLrILpRGhEQCw2LiRUIa4lwAAAABJRU5ErkJggg==) !important
}
#toast-container > .toast-warning {
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGYSURBVEhL5ZSvTsNQFMbXZGICMYGYmJhAQIJAICYQPAACiSDB8AiICQQJT4CqQEwgJvYASAQCiZiYmJhAIBATCARJy+9rTsldd8sKu1M0+dLb057v6/lbq/2rK0mS/TRNj9cWNAKPYIJII7gIxCcQ51cvqID+GIEX8ASG4B1bK5gIZFeQfoJdEXOfgX4QAQg7kH2A65yQ87lyxb27sggkAzAuFhbbg1K2kgCkB1bVwyIR9m2L7PRPIhDUIXgGtyKw575yz3lTNs6X4JXnjV+LKM/m3MydnTbtOKIjtz6VhCBq4vSm3ncdrD2lk0VgUXSVKjVDJXJzijW1RQdsU7F77He8u68koNZTz8Oz5yGa6J3H3lZ0xYgXBK2QymlWWA+RWnYhskLBv2vmE+hBMCtbA7KX5drWyRT/2JsqZ2IvfB9Y4bWDNMFbJRFmC9E74SoS0CqulwjkC0+5bpcV1CZ8NMej4pjy0U+doDQsGyo1hzVJttIjhQ7GnBtRFN1UarUlH8F3xict+HY07rEzoUGPlWcjRFRr4/gChZgc3ZL2d8oAAAAASUVORK5CYII=) !important
}
#toast-container.toast-bottom-center > div, #toast-container.toast-top-center > div {
width: 300px;
margin: auto
}
#toast-container.toast-bottom-full-width > div, #toast-container.toast-top-full-width > div {
width: 96%;
margin: auto
}
.toast {
background-color: #030303
}
.toast-success {
background-color: #51a351
}
.toast-error {
background-color: #bd362f
}
.toast-info {
background-color: #2f96b4
}
.toast-warning {
background-color: #f89406
}
.toast-progress {
position: absolute;
left: 0;
bottom: 0;
height: 4px;
background-color: #000;
opacity: .4;
-ms-filter: alpha(Opacity=40);
filter: alpha(opacity=40)
}
@media all and (max-width: 240px) {
#toast-container > div {
padding: 8px 8px 8px 50px;
width: 11em
}
#toast-container .toast-close-button {
right: -.2em;
top: -.2em
}
}
@media all and (min-width: 241px) and (max-width: 480px) {
#toast-container > div {
padding: 8px 8px 8px 50px;
width: 18em
}
#toast-container .toast-close-button {
right: -.2em;
top: -.2em
}
}
@media all and (min-width: 481px) and (max-width: 768px) {
#toast-container > div {
padding: 15px 15px 15px 50px;
width: 25em
}
}
No preview for this file type
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
No preview for this file type
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
<!--
2013-9-30: Created.
-->
<svg>
<metadata>
Created by iconfont
</metadata>
<defs>
<font id="iconfont" horiz-adv-x="1024" >
<font-face
font-family="iconfont"
font-weight="500"
font-stretch="normal"
units-per-em="1024"
ascent="896"
descent="-128"
/>
<missing-glyph />
<glyph glyph-name="homefill" unicode="&#59067;" d="M947.2 473.6l-374.4 307.2c-32 25.6-86.4 25.6-118.4 0l-377.6-310.4c-12.8-6.4-16-22.4-9.6-35.2 3.2-12.8 16-19.2 28.8-19.2h32v-364.8c0-48 35.2-83.2 83.2-83.2h204.8c19.2 0 32 12.8 32 32v147.2c0 22.4 35.2 44.8 64 44.8s67.2-22.4 67.2-44.8v-147.2c0-19.2 12.8-32 32-32h208c48 0 80 32 80 83.2v364.8h32c12.8 0 25.6 9.6 28.8 22.4 3.2 12.8 0 25.6-12.8 35.2z" horiz-adv-x="1024" />
<glyph glyph-name="dianziping" unicode="&#58886;" d="M338.292364-45.381818V56.785455h0.884363v8.610909h342.341818v-110.778182h228.026182v-54.178909h-0.884363v-8.610909H119.156364V-53.992727h0.884363v8.610909h218.298182zM0 896h1022.603636v-737.931636H0V896z" horiz-adv-x="1024" />
<glyph glyph-name="chewei" unicode="&#58887;" d="M1687.04 115.456a223.616 223.616 0 1 0-447.232 0 223.616 223.616 0 0 0 447.232 0z m-1025.152 0a223.616 223.616 0 1 0-447.232 0 223.616 223.616 0 0 0 447.232 0zM38.08 421.632l75.712 227.072s29.76 42.24 65.344 82.56c43.52 49.28 63.872 76.608 93.312 93.376C321.536 852.608 409.6 886.08 464.64 892.928c55.04 6.912 474.752 0 474.752 0S1018.496 889.6 1059.776 872.32c41.28-17.28 116.992-48.192 161.728-82.56 44.672-34.432 144.448-120.448 175.424-141.056 30.976-20.672 47.616-39.424 85.504-49.792 37.824-10.24 196.608-43.072 234.432-60.288 37.824-17.216 106.624-30.976 127.296-68.8 20.608-37.888 72.256-116.992 72.256-209.92v-147.84s-6.912-30.976-17.28-41.344c-10.24-10.24-51.52-13.76-51.52-13.76h-120.448s30.976 313.088-272.128 315.84c-282.112 2.56-257.664-315.84-257.664-315.84h-495.36s41.28 320-264.896 316.672c-295.808-3.2-257.92-316.672-257.92-316.672H86.208s-37.824 10.368-58.496 34.432C7.104 115.456 0.256 170.496 0.256 170.496V373.632l37.824 48z m748.8 113.536h595.2v30.976s-31.04 41.28-75.712 75.648c-44.8 34.432-116.992 86.016-165.12 120.448-48.192 34.368-141.056 68.8-141.056 68.8H786.816v-295.872z m-92.864 0V831.04H399.296s-111.232-79.168-149.12-116.992c-37.76-37.824-74.496-178.88-74.496-178.88h518.336z" horiz-adv-x="1920" />
<glyph glyph-name="kuangquanshui" unicode="&#58888;" d="M428.330806 769.875837h176.895705a17.834637 17.834637 0 0 1 18.04797 17.493304V878.462323c0 9.685317-8.106653 17.535971-18.04797 17.53597H428.373473a17.79197 17.79197 0 0 1-18.04797-17.493304v-91.178515c0-9.599984 8.106653-17.450638 18.04797-17.450637z m339.370101-139.391768S657.194425 701.438618 606.890509 722.259916H413.86683S292.949698 666.878675 258.560422 628.478739v-227.540954s86.655856-68.010553-2.559995-135.765107v-330.580782l58.794568-54.613243h381.780697l71.125215 56.575906v324.479459c-62.29323 24.703959-70.143883 113.322478 0 141.909097V630.484069zM300.501686 542.761549V610.132103c18.986635 39.466601 91.86118 69.845217 127.573121 69.845217L599.039855 680.10532c36.522606-0.639999 107.263821-35.327941 127.402454-69.973217v-67.413221c-7.039988 0-19.967967 24.917292-106.367822 24.917292-89.898517 0-131.797114-51.029248-211.967647-51.029248-76.543872 0-99.157168 26.154623-107.690487 26.154623z" horiz-adv-x="1024" />
<glyph glyph-name="dianhua" unicode="&#58889;" d="M592.341803 819.990353a39.30447 39.30447 0 0 0-0.393832-0.039384h-0.787665A38.20174 38.20174 0 0 0 551.383237 856.380464a38.20174 38.20174 0 0 0 36.114428 39.462003c1.023964 0 101.648135 5.553036 205.895563-46.944818a387.649202 387.649202 0 0 0 148.080971-129.531467c46.157154-68.054233 73.922336-153.673391 82.350349-254.730777a38.08359 38.08359 0 0 0-35.051081-40.958566c-1.142114-0.275683-2.126695-0.275683-3.150659-0.275683a38.241123 38.241123 0 0 0-38.241123 34.775399c-13.075235 156.745283-75.733965 264.891652-186.243328 321.682279-81.523301 41.903764-161.786337 40.328435-168.75717 40.092135zM383.413731 255.234734c89.675631-89.557481 193.45046-175.176638 234.56656-134.296838 58.720406 58.838556 94.952984 109.957998 224.405684 5.946869 129.492083-104.089895 30.010027-173.483159-26.898751-230.391936-65.612473-65.691239-310.458057-3.386958-552.507431 238.504883C21.048568 376.928937-41.09818 621.695754 24.47491 687.386994c56.869394 57.026927 126.420191 156.4696 230.391936 26.898751 104.011129-129.57085 52.852304-165.803428-5.868102-224.484451-40.958566-41.116099 44.660591-144.890929 134.375604-234.56656z m287.103798 128.783185c-20.282367 0-37.177776 16.54096-38.20174 37.650375-4.607839 93.81087-63.288862 115.195968-88.336601 119.96134l-0.905814 0.118149c-20.873116 4.214006-34.381566 24.968972-30.325092 46.47222 4.095857 21.582014 24.181308 35.563063 45.015039 31.349057h0.275683c27.489499-5.277354 55.136532-18.116289 77.74251-36.075045 31.073374-24.69329 68.920665-72.110707 73.134671-157.729864 1.023964-21.77893-15.241313-40.407201-36.311345-41.628082-0.787665-0.11815-1.417797-0.11815-2.047928-0.11815zM628.180549 859.13729c0-0.393832 0-0.393832 0 0 0-0.393832 0-0.393832 0 0zM831.004219 384.017919c-17.958756 0-33.318218 14.886864-35.208613 34.775399-13.74475 145.481677-85.264708 226.965595-212.748247 242.206907-19.494702 2.362994-33.593901 21.503247-31.467206 42.848962 2.126695 21.306331 19.652235 36.705177 39.146938 34.381566 22.448445-2.717443 90.581445-10.869773 153.043259-58.208425A280.487414 280.487414 0 0 0 822.73374 585.26626c23.196727-44.227375 37.847291-97.473512 43.518477-158.399379 2.008545-21.345714-12.208803-40.367818-31.703506-42.533896-1.063347-0.275683-2.362994-0.275683-3.544492-0.275682z" horiz-adv-x="1024" />
<glyph glyph-name="maike" unicode="&#58890;" d="M891.259259 360.106667v26.055111h-77.482666v-26.093037c0-156.520296-116.167111-284.823704-265.746963-303.255704v128.265482c94.701037 17.370074 166.798222 101.072593 166.798222 200.021333V691.579259C714.827852 804.67437 624.45037 896 512.530963 896c-111.881481 0-202.258963-91.32563-202.258963-204.382815v-306.517333c0-101.110519 70.997333-184.813037 166.760296-200.021333v-130.465186c-150.641778 17.408-267.908741 146.773333-267.90874 303.29363V384H132.740741v-26.093037c0-198.921481 151.703704-363.064889 344.291555-381.534815v-27.192889H274.773333V-128h512.113778v77.179259h-239.919407v27.192889C739.555556-2.996148 891.259259 160.085333 891.259259 360.068741z" horiz-adv-x="1024" />
<glyph glyph-name="dianxin" unicode="&#58891;" d="M23.272727-82.757818l977.454546 97.745454v146.478546l-977.454546-97.745455v-146.478545zM658.478545 652.288l-103.470545-47.941818c3.630545-16.709818 5.725091-33.885091 5.725091-51.898182 0-134.749091-109.707636-244.503273-244.224-244.503273-73.541818 0-138.938182 33.373091-183.761455 84.992L23.272727 338.199273v-176.733091l977.454546 96.954182v173.614545l-342.248728 220.253091zM316.509091 405.969455a146.525091 146.525091 0 0 1 59.438545 280.482909l37.236364 147.549091A49.058909 49.058909 0 0 1 377.809455 893.346909a48.733091 48.733091 0 0 1-59.438546-35.467636l-41.704727-164.724364c-61.486545-17.454545-107.101091-73.216-107.101091-140.474182A147.269818 147.269818 0 0 1 316.509091 405.969455z" horiz-adv-x="1024" />
<glyph glyph-name="tiaofu" unicode="&#58892;" d="M1160.030316 799.366737A45.648842 45.648842 0 0 0 1185.684211 758.029474v-750.915369a46.187789 46.187789 0 0 0-17.946948-36.432842c-66.775579-51.307789-167.666526-79.656421-284.402526-79.656421-111.023158 0-203.344842 25.438316-281.923369 77.824-75.237053 50.122105-149.072842 83.536842-265.269894 83.536842-108.220632 0-197.470316-32.875789-243.334737-66.937263 0 0-92.16-70.224842-92.16 68.985263V758.029474c0 12.503579 5.173895 24.576 14.22821 33.253052C69.146947 843.021474 189.493895 895.245474 336.087579 895.245474c147.402105 0 239.130947-47.427368 316.362105-98.950737 63.973053-42.576842 137.269895-62.356211 230.885053-62.356211 95.178105 0 178.283789 22.096842 228.136421 60.52379 14.012632 10.778947 32.714105 12.611368 48.505263 4.904421zM422.211368 566.703158a26.947368 26.947368 0 0 1-26.947368-26.947369v-12.018526a26.947368 26.947368 0 0 1 26.947368-26.947368h407.336421a26.947368 26.947368 0 0 1 26.947369 26.947368V539.755789a26.947368 26.947368 0 0 1-26.947369 26.947369H422.157474z m0-263.545263a26.947368 26.947368 0 0 1-26.947368-26.947369v-12.018526a26.947368 26.947368 0 0 1 26.947368-26.947368h407.336421a26.947368 26.947368 0 0 1 26.947369 26.947368v11.964632a26.947368 26.947368 0 0 1-26.947369 26.947368H422.157474z" horiz-adv-x="1185" />
<glyph glyph-name="chashui" unicode="&#58893;" d="M1378.49344 612.693333c-33.735111 0-65.877333-6.826667-95.402667-17.749333a498.574222 498.574222 0 0 1-78.563555 58.254222c-4.209778 2.56-7.623111 5.12-11.832889 7.623111h-608.142222c-6.826667-3.413333-12.686222-7.623111-19.456-11.832889C494.155662 604.16 437.551218 546.702222 401.995662 479.175111a375.466667 375.466667 0 0 1-25.315555-59.960889 350.776889 350.776889 0 0 1-18.602667-111.502222c0-37.148444 5.916444-72.647111 16.896-106.382222 9.272889-28.728889 21.959111-56.604444 38.001778-82.830222 40.561778-67.527111 102.229333-124.984889 178.232889-167.253334h-0.853334v-44.771555c0-16.042667 13.539556-29.582222 29.582223-29.582223h537.201777c16.042667 0 29.582222 13.539556 29.582223 29.582223v44.771555h-0.853334c58.311111 32.142222 108.942222 74.353778 147.000889 122.481778 15.189333-2.503111 30.378667-4.209778 45.568-4.209778a271.473778 271.473778 0 0 1 271.189333 271.132445c0.796444 150.357333-121.628444 271.985778-271.189333 271.985777z m2.56-463.758222c24.462222 48.981333 38.001778 103.025778 38.001778 158.776889 0 81.123556-27.875556 157.127111-76.003556 222.151111 11.832889 2.56 23.665778 3.413333 36.295111 3.413333a192.512 192.512 0 0 0 192.625778-192.625777c-0.853333-104.675556-86.186667-190.862222-190.919111-191.715556zM1195.19744 728.405333c0 31.232-115.712 56.547556-266.069333 60.814223a60.586667 60.586667 0 0 1-39.708445 106.382222 60.586667 60.586667 0 0 1-39.651555-106.382222c-150.357333-4.266667-266.126222-29.582222-266.126223-60.871112v-15.189333h612.408889v15.246222h-0.853333zM331.96544 307.768889c0 48.924444 9.272889 96.256 27.022222 140.174222 6.769778 18.602667 16.042667 35.498667 25.315556 53.191111-104.675556 130.958222-232.277333 150.357333-238.193778 151.210667a27.192889 27.192889 0 0 1-19.399111-5.063111L10.998329 561.152c-9.329778-6.826667-12.686222-18.602667-9.329778-29.582222a25.6 25.6 0 0 1 25.372445-17.749334c114.858667 0 207.758222-151.210667 239.843555-247.466666 22.016-66.730667 69.290667-105.585778 104.789333-127.544889a361.813333 361.813333 0 0 0-32.995555 102.172444 350.549333 350.549333 0 0 0-6.712889 66.730667z" horiz-adv-x="1650" />
<glyph glyph-name="lvzhi" unicode="&#58894;" d="M464.34181 538.31867c30.207698 30.165032 10.111899 164.051693-84.905818 259.026743C284.546275 892.320463 152.323597 914.165578 120.494582 882.251231c-31.957014-31.914348-10.111899-164.094359 84.863151-259.069409s228.861711-115.070849 259.026743-84.905818zM848.039306 623.181822c94.97505 94.97505 116.820165 227.155062 84.905818 259.069409-31.914348 31.914348-164.094359 10.069233-259.069409-84.905818s-115.070849-228.861711-84.905818-259.026743c30.207698-30.207698 164.094359-10.111899 259.069409 84.905818zM462.592494 426.66112H114.222644A50.346163 50.346163 0 0 1 64.00448 376.442956v-148.179852h534.394656l-346.449869-42.367576a40.532928 40.532928 0 0 1-31.957014-46.378203l36.99163-223.229768a40.532928 40.532928 0 0 1 40.020934-33.919661h434.043659a40.532928 40.532928 0 0 1 40.191598 35.028983l42.66624 310.866225h95.31638a50.346163 50.346163 0 0 1 50.175499 50.218165V426.66112H462.592494z" horiz-adv-x="1024" />
<glyph glyph-name="zhuoqian" unicode="&#58895;" d="M365.714286 896h1082.294857L1682.285714-128H599.990857L365.714286 896z m402.285714-292.571429a36.571429 36.571429 0 0 1 0-73.142857h438.857143a36.571429 36.571429 0 0 1 0 73.142857h-438.857143z m146.285714-292.571428a36.571429 36.571429 0 0 1 0-73.142857h438.857143a36.571429 36.571429 0 0 1 0 73.142857h-438.857143zM219.428571 896l219.428572-1024H0L219.428571 896z" horiz-adv-x="1682" />
<glyph glyph-name="xuanzhuanmen" unicode="&#58896;" d="M734.117647 463.345269h-64.040921C664.961637 650.88491 600.347826 896 488.347826 896c-49.923274 0-118.424552-37.769821-161.923274-216.306905a47.099744 47.099744 0 1 1 91.498722-22.424553c25.616368 105.575448 57.616368 138.230179 67.846547 143.386189 26.230179-21.769821 86.383632-160.654731 90.230179-339.846547h-80a15.345269 15.345269 0 0 1-10.230179-26.2711l122.230179-114.578005a15.345269 15.345269 0 0 1 21.769821 0l115.805627 119.693095a15.345269 15.345269 0 0 1-11.457801 23.734015z m-245.769821-591.345269c-40.347826 0-99.232737 26.189258-142.731458 151.652174a47.058824 47.058824 0 0 0 88.961637 30.731458c25.575448-72.961637 49.923274-88.306905 53.769821-88.306906 3.805627 0 42.84399 27.498721 71.652174 149.769821a47.058824 47.058824 0 1 0 91.539642-21.769821c-34.578005-145.268542-90.88491-222.076726-163.191816-222.076726zM810.230179 518.383632a47.099744 47.099744 0 0 1-22.383632-91.498722c115.846547-28.808184 142.076726-64 142.076727-69.76982 0-25.616368-143.345269-101.11509-417.923274-101.11509-45.421995 0-89.616368 0-132.460358 7.038363l4.501279 76.808184a15.345269 15.345269 0 0 1-26.2711 11.498722L234.88491 237.421995a15.345269 15.345269 0 0 1 0-21.769821l113.923274-120.961637a15.345269 15.345269 0 0 1 26.884911 10.230179v64.040921c44.153453-3.846547 88.961637-7.038363 135.038363-7.038363 246.383632 0 512 60.767263 512 192 1.268542 52.460358-35.846547 120.306905-212.460358 164.501278zM148.542199 218.84399a47.345269 47.345269 0 0 0-20.460358 3.232736C22.997442 264.961637 0 320 0 357.074169c0 128 234.88491 181.769821 436.501279 192a47.058824 47.058824 0 1 0 4.501279-94.117647c-242.618926-12.112532-346.925831-78.035806-346.925832-97.882353 0 0 12.153453-24.306905 71.693095-47.345269a46.731458 46.731458 0 0 0-17.268542-90.88491z" horiz-adv-x="1024" />
<glyph glyph-name="xianhua" unicode="&#58897;" d="M92.387413 266.282667a300.629333 300.629333 0 0 0 144.256-3.669334c47.914667-12.928 90.752-37.589333 128.554667-73.984 18.176-18.176 33.578667-38.613333 46.165333-61.354666 12.586667-22.741333 22.186667-46.336 28.842667-70.826667 6.656-24.490667 10.154667-49.322667 10.496-74.496a326.272 326.272 0 0 0-6.826667-72.405333c-47.573333-10.496-95.488-7.68-143.744 8.405333a323.84 323.84 0 0 0-128 79.744c-37.76 36.352-63.146667 78.506667-76.074666 126.421333a292.437333 292.437333 0 0 0-3.669334 142.165334z m838.314667 0a292.437333 292.437333 0 0 0-3.669333-142.165334c-12.928-47.914667-37.973333-90.026667-75.008-126.421333a243.925333 243.925333 0 0 0-64-45.653333 413.312 413.312 0 0 0-77.653334-29.354667c-27.306667-7.381333-55.466667-12.245333-84.48-14.72-29.013333-2.432-57.514667-2.986667-85.504-1.578667H479.587413v394.496a313.173333 313.173333 0 0 0-113.322666 33.578667 336.554667 336.554667 0 0 0-75.008 52.48 338.645333 338.645333 0 0 0-58.24 70.314667 350.122667 350.122667 0 0 0-37.76 83.925333 324.608 324.608 0 0 0-13.653334 94.421333c0 44.074667 8.746667 86.741333 26.24 128a335.274667 335.274667 0 0 0 92.842667-38.314666c28.330667-17.109333 53.717333-37.930667 76.074667-62.421334a321.962667 321.962667 0 0 0 46.677333 130.645334A343.253333 343.253333 0 0 0 517.304747 892.672a325.973333 325.973333 0 0 0 96-100.736c24.832-40.533333 40.064-84.992 45.653333-133.248a363.093333 363.093333 0 0 0 76.586667 63.488 324.821333 324.821333 0 0 0 93.397333 39.338667 333.226667 333.226667 0 0 0 24.106667-125.909334 332.8 332.8 0 0 0-13.098667-93.397333c-8.746667-30.08-21.333333-58.026667-37.76-83.925333a362.112 362.112 0 0 0-58.24-70.272 325.717333 325.717333 0 0 0-74.496-52.48v-1.066667a353.706667 353.706667 0 0 0-60.330667-23.594667c-20.650667-5.973333-42.154667-9.6-64.512-11.008v-282.24c8.362667 28.672 21.333333 56.149333 38.826667 82.346667 17.493333 26.24 37.76 50.56 60.842667 72.96a319.061333 319.061333 0 0 0 62.421333 48.213333 370.602667 370.602667 0 0 0 72.96 33.621334 324.48 324.48 0 0 0 76.544 15.701333 262.570667 262.570667 0 0 0 74.496-4.181333z" horiz-adv-x="1024" />
<glyph glyph-name="touying" unicode="&#58898;" d="M170.666667-39.025778c0-45.112889 36.579556-81.692444 81.692444-81.692444h54.442667c45.112889 0 81.692444 36.579556 81.692444 81.692444V42.666667H170.666667v-81.692445zM910.222222-39.025778c0-45.112889 36.579556-81.692444 81.692445-81.692444h54.442666c45.112889 0 81.692444 36.579556 81.692445 81.692444V42.666667H910.222222v-81.692445zM1143.694222 896H163.384889A163.384889 163.384889 0 0 1 0 732.615111v-490.154667a163.441778 163.441778 0 0 1 163.384889-163.384888h980.309333a163.441778 163.441778 0 0 1 163.441778 163.384888V732.615111A163.384889 163.384889 0 0 1 1143.694222 896zM490.154667 296.96H108.942222v54.385778h381.212445v-54.442667z m0 163.328H108.942222v54.442667h381.212445v-54.442667z m0 163.384889H108.942222v54.499555h381.212445v-54.499555z m408.462222-435.712a299.576889 299.576889 0 1 0 0.056889 599.153778 299.576889 299.576889 0 0 0 0-599.153778zM873.244444 725.333333a190.577778 190.577778 0 1 1 0-381.212444 190.577778 190.577778 0 1 1 0 381.212444z" horiz-adv-x="1308" />
<glyph glyph-name="kafei" unicode="&#58899;" d="M533.113705 895.683839a21.851713 21.851713 0 0 1-21.418616-22.12732c0-66.460705-25.395234-86.225677-57.877509-115.400666-32.482276-29.056872-72.3272-67.563133-72.327201-145.678085a21.851713 21.851713 0 0 1 32.71851-19.135013 21.930458 21.930458 0 0 1 10.788053 19.135013c0 64.925179 25.237744 84.060192 57.87751 113.274554 32.679138 29.253734 72.3272 68.429327 72.3272 147.804197A21.81234 21.81234 0 0 1 533.113705 895.683839z m108.943584-108.786094a21.851713 21.851713 0 0 1-21.379244-22.12732c0-42.482879-14.646553-52.6016-36.301404-71.894103s-50.908585-48.034396-50.908584-102.171522a21.891085 21.891085 0 0 1 10.788052-19.095641c6.811435-3.937246 15.119023-3.937246 21.930458 0a21.930458 21.930458 0 0 1 10.788053 19.095641c0 40.789864 14.370946 50.160508 36.301404 69.689246 21.930458 19.489365 50.908585 48.979334 50.908584 104.376379a21.81234 21.81234 0 0 1-22.127319 22.12732zM207.070402 525.464641a21.772968 21.772968 0 0 1-21.733596-21.772967v-261.118124a216.942229 216.942229 0 0 1 87.603714-174.026253h434.002575a217.454071 217.454071 0 0 1 83.036508 131.385884c49.688039 4.055363 86.068187 25.749586 106.817472 59.058683 22.363555 36.222659 27.718209 82.170314 27.954443 132.173332 0.078745 0.15749 0.078745 0.31498 0.078745 0.511842A20.670539 20.670539 0 0 1 925.10587 394.866207c0 35.789562-29.489969 65.240159-65.279531 65.240159h-65.279531V503.691674a21.772968 21.772968 0 0 1-21.733595 21.733595H207.070402z m587.476406-108.825466h65.279531c12.323579 0 21.772968-9.449389 21.772968-21.733595 0-48.191885-6.299593-87.997438-21.772968-112.998947-12.99291-20.867401-31.340474-34.135919-65.279531-37.99442v172.726962zM120.057276 25.001362a21.772968 21.772968 0 0 1-21.772968-21.772968c0-60.239857 83.272743-108.786094 152.292657-108.786094h478.690312c70.476695 0 152.33203 47.522554 152.33203 108.786094a21.772968 21.772968 0 0 1-21.772968 21.772968H120.017903z" horiz-adv-x="1024" />
<glyph glyph-name="zhibi" unicode="&#58900;" d="M779.527682 570.12131l-174.541964 174.495419L139.633571 279.218037V104.722618h174.541964l465.352147 465.398692z m137.77179 137.77179a46.358346 46.358346 0 0 1 0 65.581234l-108.914185 108.914186a46.358346 46.358346 0 0 1-65.627779 0l-91.227266-91.227267 174.541964-174.541964 91.227266 91.227267zM0 11.633571h1023.97952v-139.633571H0z" horiz-adv-x="1024" />
<glyph glyph-name="zhuangang" unicode="&#58901;" d="M247.1936 628.24448V609.28h557.79328V658.71872s35.88096 12.65664 64.14336 25.31328c49.80736 25.31328 64.14336 76.30848 43.008 76.30848-26.99264 6.9632-53.57568 15.44192-79.6672 25.31328C782.66368 806.62528 654.00832 889.69216 619.3152 896H440.03328C397.43488 883.34336 311.33696 806.62528 240.8448 787.61984c-64.14336-12.61568-92.85632-18.96448-92.85632-18.96448-14.336-12.65664 7.168-44.68736 28.672-63.65184a340.29568 340.29568 0 0 1 71.35232-32.07168v-44.6464h-0.8192z m323.66592 150.3232l-38.37952 11.01824-38.42048-16.46592 7.70048 27.77088-30.72 21.9136 38.42048 5.48864 15.7696 26.74688 23.01952-27.77088L593.92 821.78048l-30.72-16.42496 7.70048-26.74688zM266.6496 565.57568C280.90368 300.35968 401.32608 199.68 401.32608 199.68h255.5904C770.53952 300.72832 798.72 565.53472 798.72 565.53472c0 6.26688-532.48 0-532.48 0h0.4096zM652.0832 240.64H444.74368C381.58336 307.56864 347.29984 392.68352 348.16 480.4608l29.9008-5.98016 7.41376-65.90464h133.9392l22.36416 37.2736h37.2736l14.9504-37.2736h118.9888l29.85984 71.8848L757.76 486.4s-7.45472-156.0576-104.0384-245.76h-1.6384z m-194.23232-260.3008s14.49984 0 36.2496 56.1152a166.2976 166.2976 0 0 1 14.45888 59.96544h-36.20864l28.99968 56.1152h72.00768l28.99968-49.93024h-36.20864s-7.24992-93.63456 43.4176-112.2304c0 0 36.2496-38.66624 115.5072 168.3456h36.2496s144.09728-99.81952 201.23648-112.2304V-128H61.44v163.30752a596.45952 596.45952 0 0 1 223.35488 112.18944h43.49952c7.20896 0 64.75776-168.3456 129.55648-168.3456v1.2288z" horiz-adv-x="1024" />
<glyph glyph-name="shuipai" unicode="&#58902;" d="M625.225143 761.856l340.455619-347.574857c21.455238-21.455238 33.304381-52.370286 33.304381-83.334095s-11.897905-61.927619-33.304381-83.334096l-309.49181-302.323809c-42.861714-40.472381-123.806476-42.861714-166.619428 0l-380.928 378.538667C41.984 388.096 25.35619 414.232381 25.35619 502.345143V669.013333C25.35619 826.12419 56.271238 895.171048 244.345905 895.171048h154.721524c95.232-2.438095 149.991619-57.148952 226.157714-133.315048zM401.456762 614.253714c0 61.927619-52.370286 111.85981-111.85981 111.85981a111.762286 111.762286 0 0 1-111.908571-111.85981 111.762286 111.762286 0 0 1 111.908571-111.908571 111.762286 111.762286 0 0 1 111.85981 111.908571z" horiz-adv-x="1024" />
<glyph glyph-name="guopan" unicode="&#58903;" d="M263.471407 175.407407L474.074074 782.222222 132.740741 224.180148zM559.028148 886.442667S555.045926 896 549.546667 896c-6.447407 0-9.178074-10.088296-9.178074-10.088296L322.37037 145.028741s103.461926-87.267556 279.627852-83.247408c188.22637 4.28563 289.261037 133.12 289.261037 133.12L559.028148 886.442667z m-23.324444-439.561482c-2.465185-34.512593-29.961481-31.099259-36.067556-6.181926-2.844444 11.567407 0.493037 38.684444 14.260148 65.687704 10.42963 20.404148 23.134815-40.618667 21.807408-59.505778z m19.835259 226.645334c-5.082074 6.219852-1.782519 28.292741 4.93037 44.259555 5.992296 14.260148 18.469926-29.089185 16.952889-39.253333-1.061926-7.433481-12.09837-16.914963-21.883259-5.006222z m48.014222-121.325038c-0.379259-10.619259-13.274074-25.031111-28.065185-12.136296-8.571259 7.509333-4.323556 37.243259 3.223704 62.767408 6.295704 21.200593 25.334519-38.836148 24.841481-50.631112z m50.062222-92.653037c-6.826667 7.812741-7.698963 28.709926-3.185777 54.46163 3.413333 19.797333 27.799704-29.051259 29.165037-46.004148 0.758519-9.671111-14.411852-21.617778-25.97926-8.457482zM284.444444-76.420741c135.395556-61.705481 283.875556-66.635852 414.189037-22.300444 151.703704 51.617185 224.293926 152.234667 230.551704 179.048296l-19.26637 37.69837s-117.418667-149.048889-323.053037-154.699851c-216.822519-5.95437-342.774519 103.537778-342.774519 103.537777L94.814815 137.481481s13.236148-133.575111 189.629629-213.902222z" horiz-adv-x="1024" />
<glyph glyph-name="liyi" unicode="&#58904;" d="M376.742957 217.755826c41.894957-41.627826 92.026435-60.950261 141.490086-57.878261 42.74087 2.671304 85.036522 21.949217 121.188174 57.878261 31.120696 29.829565 56.676174 75.464348 73.594435 130.715826 16.918261 9.037913 38.64487 25.778087 58.546087 56.854261 68.919652 107.297391 8.503652 241.307826-92.293565 318.642087 2.137043 8.993391 3.250087 18.298435 3.250087 27.870609C682.518261 831.443478 605.273043 896 509.996522 896 414.72 896 337.474783 831.443478 337.474783 751.838609c0-7.657739 0.75687-15.181913 2.137043-22.572522C233.249391 650.818783 177.819826 508.66087 244.157217 405.370435c20.658087-32.233739 43.319652-49.107478 60.460522-57.833739 14.692174-50.220522 36.997565-93.718261 72.125218-129.736348z m299.008 508.883478c-49.107478 36.730435-107.297391 60.015304-164.730435 60.594087-58.546087 0.623304-113.797565-18.69913-160.322783-50.086956 25.377391 53.203478 87.618783 90.824348 160.278261 90.824348 77.378783 0 142.914783-42.651826 164.730435-101.286957zM216.598261 106.629565h124.349217a153.243826 153.243826 0 0 1-1.691826-22.706087c0-84.680348 68.786087-154.35687 156.538435-161.836521 2.404174 25.021217-1.246609 32.278261-15.760696 67.138782 5.030957 1.825391 10.017391 3.695304 15.003826 5.387131 11.753739-13.57913 18.565565-23.151304 22.438957-31.47687 3.917913 8.325565 10.685217 17.897739 22.438956 31.47687 5.030957-1.691826 10.017391-3.561739 15.048348-5.342609-14.246957-34.192696-17.986783-41.939478-15.849739-65.803131 82.053565 12.421565 144.829217 79.560348 144.829218 160.456348 0 7.702261-0.578783 15.315478-1.691827 22.706087h120.742957C861.584696 42.340174 887.407304-37.442783 890.212174-128H133.342609c0.75687 85.926957 26.713043 164.59687 83.255652 234.585043z m258.270609 381.284174l8.102956-8.414609a318.642087 318.642087 0 0 1 119.051131 71.590957l82.899478-50.576696c-4.897391-89.933913-22.038261-161.52487-52.802783-211.656348-28.538435-46.614261-69.542957-74.351304-124.037565-80.183652-54.494609 5.787826-95.454609 33.569391-123.993044 80.139131-29.250783 47.727304-46.258087 114.866087-52.001391 198.745043 43.542261-1.29113 85.570783 2.80487 125.595826 13.890783a326.255304 326.255304 0 0 1 86.906435 37.843478c-22.26087-19.144348-45.768348-35.706435-69.721043-51.378087z m-116.557913 58.323478c46.970435 23.462957 93.94087 47.014957 140.82226 70.522435l16.473044-20.48c-47.905391-36.507826-100.574609-52.402087-157.295304-50.086956zM284.716522 605.718261c20.658087 50.576696 59.481043 91.046957 115.044174 122.345739l13.623652-20.702609c-51.734261-28.271304-95.053913-61.885217-128.667826-101.64313z" horiz-adv-x="1024" />
<glyph glyph-name="shensuomen" unicode="&#58905;" d="M1023.832603-127.832603h-71.668282V800.52761a20.476652 20.476652 0 0 1-20.118311 20.579035H91.786593c-11.262159 0-20.118311-9.214493-20.118311-20.579035V-127.832603H0V800.52761C0 853.408564 41.311646 896 91.786593 896h840.259417C982.520958 896 1023.832603 853.408564 1023.832603 800.52761V-127.832603zM403.390046-21.609971l-289.949394-105.761908c-5.528696-2.098857-11.057392 3.225073-11.057392 10.34071V782.917689c0 7.166828 5.170355 12.132416 10.750243 10.340709l289.898201-100.745128c3.788181-1.433366 6.245379-5.682271 6.245379-10.699051v-693.134672c0.30715-4.607247-2.047665-9.214493-5.887037-10.289518z m165.860881 0l289.949394-105.761908c5.528696-2.098857 11.057392 3.225073 11.057392 10.34071V782.917689c0 7.166828-5.170355 12.132416-10.750242 10.340709l-289.898202-100.745128c-3.788181-1.433366-6.245379-5.682271-6.245379-10.699051v-693.134672c-0.30715-4.607247 2.457198-9.214493 5.887037-10.289518z" horiz-adv-x="1024" />
<glyph glyph-name="zhuanti" unicode="&#58906;" d="M250.831238 416.329143l82.066286 79.286857v-250.587429c0-19.017143 13.165714-31.695238 32.816762-31.695238 19.69981 0 32.816762 12.678095 32.816762 31.695238V495.664762l82.066285-79.286857c13.116952-12.678095 32.816762-12.678095 45.933715 0 13.165714 12.678095 13.165714 31.695238 0 44.373333L388.681143 593.92a32.475429 32.475429 0 0 1-45.933714 0L204.897524 460.702476c-13.165714-12.678095-13.165714-31.695238 0-44.373333s32.816762-12.678095 45.933714 0z m246.832762-106.691048l137.216-135.411809a33.206857 33.206857 0 0 1 46.811429 0l137.216 135.411809a30.378667 30.378667 0 0 1 0 45.153524c-13.360762 12.873143-36.815238 12.873143-46.811429 0l-80.359619-80.603429v248.198096A32.914286 32.914286 0 0 1 658.285714 554.666667c-16.725333 0-33.450667-12.873143-33.450666-32.231619v-248.246858L544.52419 354.742857a33.206857 33.206857 0 0 1-46.86019 0 30.378667 30.378667 0 0 1 0-45.153524z m462.360381-245.613714V703.975619c25.84381 0 63.975619 35.449905 63.975619 89.916952C1024 848.408381 999.619048 896 960.024381 896H64.024381C24.33219 896 0 831.975619 0 794.331429c0-37.595429 42.666667-90.35581 64.024381-90.35581 0-17.798095-0.536381-630.979048 0-640-39.69219 0-61.927619-58.514286-61.927619-101.961143C2.096762-81.432381 31.744-128 67.193905-128h890.684952c41.788952 0 66.121143 30.134857 66.121143 85.430857 0 55.247238-20.089905 106.593524-63.975619 106.593524zM926.47619 67.047619H146.285714V700.952381h780.190476v-633.904762z" horiz-adv-x="1024" />
</font>
</defs></svg>
No preview for this file type
/*!
* Bootstrap v3.3.6 (http://getbootstrap.com)
* Copyright 2011-2015 Twitter, Inc.
* Licensed under the MIT license
*/
if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";var b=a.fn.jquery.split(" ")[0].split(".");if(b[0]<2&&b[1]<9||1==b[0]&&9==b[1]&&b[2]<1||b[0]>2)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3")}(jQuery),+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){return a(b.target).is(this)?b.handleObj.handler.apply(this,arguments):void 0}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.3.6",d.TRANSITION_DURATION=150,d.prototype.close=function(b){function c(){g.detach().trigger("closed.bs.alert").remove()}var e=a(this),f=e.attr("data-target");f||(f=e.attr("href"),f=f&&f.replace(/.*(?=#[^\s]*$)/,""));var g=a(f);b&&b.preventDefault(),g.length||(g=e.closest(".alert")),g.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(g.removeClass("in"),a.support.transition&&g.hasClass("fade")?g.one("bsTransitionEnd",c).emulateTransitionEnd(d.TRANSITION_DURATION):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.3.6",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),setTimeout(a.proxy(function(){d[e](null==f[b]?this.options[b]:f[b]),"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")?(c.prop("checked")&&(a=!1),b.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==c.prop("type")&&(c.prop("checked")!==this.$element.hasClass("active")&&(a=!1),this.$element.toggleClass("active")),c.prop("checked",this.$element.hasClass("active")),a&&c.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target);d.hasClass("btn")||(d=d.closest(".btn")),b.call(d,"toggle"),a(c.target).is('input[type="radio"]')||a(c.target).is('input[type="checkbox"]')||c.preventDefault()}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(b){a(b.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(b.type))})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",a.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.3.6",c.TRANSITION_DURATION=600,c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},c.prototype.keydown=function(a){if(!/input|textarea/i.test(a.target.tagName)){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()}},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.getItemForDirection=function(a,b){var c=this.getItemIndex(b),d="prev"==a&&0===c||"next"==a&&c==this.$items.length-1;if(d&&!this.options.wrap)return b;var e="prev"==a?-1:1,f=(c+e)%this.$items.length;return this.$items.eq(f)},c.prototype.to=function(a){var b=this,c=this.getItemIndex(this.$active=this.$element.find(".item.active"));return a>this.$items.length-1||0>a?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){b.to(a)}):c==a?this.pause().cycle():this.slide(a>c?"next":"prev",this.$items.eq(a))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){return this.sliding?void 0:this.slide("next")},c.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},c.prototype.slide=function(b,d){var e=this.$element.find(".item.active"),f=d||this.getItemForDirection(b,e),g=this.interval,h="next"==b?"left":"right",i=this;if(f.hasClass("active"))return this.sliding=!1;var j=f[0],k=a.Event("slide.bs.carousel",{relatedTarget:j,direction:h});if(this.$element.trigger(k),!k.isDefaultPrevented()){if(this.sliding=!0,g&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var l=a(this.$indicators.children()[this.getItemIndex(f)]);l&&l.addClass("active")}var m=a.Event("slid.bs.carousel",{relatedTarget:j,direction:h});return a.support.transition&&this.$element.hasClass("slide")?(f.addClass(b),f[0].offsetWidth,e.addClass(h),f.addClass(h),e.one("bsTransitionEnd",function(){f.removeClass([b,h].join(" ")).addClass("active"),e.removeClass(["active",h].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger(m)},0)}).emulateTransitionEnd(c.TRANSITION_DURATION)):(e.removeClass("active"),f.addClass("active"),this.sliding=!1,this.$element.trigger(m)),g&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this};var e=function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}};a(document).on("click.bs.carousel.data-api","[data-slide]",e).on("click.bs.carousel.data-api","[data-slide-to]",e),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){var c,d=b.attr("data-target")||(c=b.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"");return a(d)}function c(b){return this.each(function(){var c=a(this),e=c.data("bs.collapse"),f=a.extend({},d.DEFAULTS,c.data(),"object"==typeof b&&b);!e&&f.toggle&&/show|hide/.test(b)&&(f.toggle=!1),e||c.data("bs.collapse",e=new d(this,f)),"string"==typeof b&&e[b]()})}var d=function(b,c){this.$element=a(b),this.options=a.extend({},d.DEFAULTS,c),this.$trigger=a('[data-toggle="collapse"][href="#'+b.id+'"],[data-toggle="collapse"][data-target="#'+b.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};d.VERSION="3.3.6",d.TRANSITION_DURATION=350,d.DEFAULTS={toggle:!0},d.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},d.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b,e=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing");if(!(e&&e.length&&(b=e.data("bs.collapse"),b&&b.transitioning))){var f=a.Event("show.bs.collapse");if(this.$element.trigger(f),!f.isDefaultPrevented()){e&&e.length&&(c.call(e,"hide"),b||e.data("bs.collapse",null));var g=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[g](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var h=function(){this.$element.removeClass("collapsing").addClass("collapse in")[g](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return h.call(this);var i=a.camelCase(["scroll",g].join("-"));this.$element.one("bsTransitionEnd",a.proxy(h,this)).emulateTransitionEnd(d.TRANSITION_DURATION)[g](this.$element[0][i])}}}},d.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var e=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(e,this)).emulateTransitionEnd(d.TRANSITION_DURATION):e.call(this)}}},d.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},d.prototype.getParent=function(){return a(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(a.proxy(function(c,d){var e=a(d);this.addAriaAndCollapsedClass(b(e),e)},this)).end()},d.prototype.addAriaAndCollapsedClass=function(a,b){var c=a.hasClass("in");a.attr("aria-expanded",c),b.toggleClass("collapsed",!c).attr("aria-expanded",c)};var e=a.fn.collapse;a.fn.collapse=c,a.fn.collapse.Constructor=d,a.fn.collapse.noConflict=function(){return a.fn.collapse=e,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(d){var e=a(this);e.attr("data-target")||d.preventDefault();var f=b(e),g=f.data("bs.collapse"),h=g?"toggle":e.data();c.call(f,h)})}(jQuery),+function(a){"use strict";function b(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function c(c){c&&3===c.which||(a(e).remove(),a(f).each(function(){var d=a(this),e=b(d),f={relatedTarget:this};e.hasClass("open")&&(c&&"click"==c.type&&/input|textarea/i.test(c.target.tagName)&&a.contains(e[0],c.target)||(e.trigger(c=a.Event("hide.bs.dropdown",f)),c.isDefaultPrevented()||(d.attr("aria-expanded","false"),e.removeClass("open").trigger(a.Event("hidden.bs.dropdown",f)))))}))}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.3.6",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=b(e),g=f.hasClass("open");if(c(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(a(this)).on("click",c);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus").attr("aria-expanded","true"),f.toggleClass("open").trigger(a.Event("shown.bs.dropdown",h))}return!1}},g.prototype.keydown=function(c){if(/(38|40|27|32)/.test(c.which)&&!/input|textarea/i.test(c.target.tagName)){var d=a(this);if(c.preventDefault(),c.stopPropagation(),!d.is(".disabled, :disabled")){var e=b(d),g=e.hasClass("open");if(!g&&27!=c.which||g&&27==c.which)return 27==c.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.disabled):visible a",i=e.find(".dropdown-menu"+h);if(i.length){var j=i.index(c.target);38==c.which&&j>0&&j--,40==c.which&&j<i.length-1&&j++,~j||(j=0),i.eq(j).trigger("focus")}}}};var h=a.fn.dropdown;a.fn.dropdown=d,a.fn.dropdown.Constructor=g,a.fn.dropdown.noConflict=function(){return a.fn.dropdown=h,this},a(document).on("click.bs.dropdown.data-api",c).on("click.bs.dropdown.data-api",".dropdown form",function(a){a.stopPropagation()}).on("click.bs.dropdown.data-api",f,g.prototype.toggle).on("keydown.bs.dropdown.data-api",f,g.prototype.keydown).on("keydown.bs.dropdown.data-api",".dropdown-menu",g.prototype.keydown)}(jQuery),+function(a){"use strict";function b(b,d){return this.each(function(){var e=a(this),f=e.data("bs.modal"),g=a.extend({},c.DEFAULTS,e.data(),"object"==typeof b&&b);f||e.data("bs.modal",f=new c(this,g)),"string"==typeof b?f[b](d):g.show&&f.show(d)})}var c=function(b,c){this.options=c,this.$body=a(document.body),this.$element=a(b),this.$dialog=this.$element.find(".modal-dialog"),this.$backdrop=null,this.isShown=null,this.originalBodyPad=null,this.scrollbarWidth=0,this.ignoreBackdropClick=!1,this.options.remote&&this.$element.find(".modal-content").load(this.options.remote,a.proxy(function(){this.$element.trigger("loaded.bs.modal")},this))};c.VERSION="3.3.6",c.TRANSITION_DURATION=300,c.BACKDROP_TRANSITION_DURATION=150,c.DEFAULTS={backdrop:!0,keyboard:!0,show:!0},c.prototype.toggle=function(a){return this.isShown?this.hide():this.show(a)},c.prototype.show=function(b){var d=this,e=a.Event("show.bs.modal",{relatedTarget:b});this.$element.trigger(e),this.isShown||e.isDefaultPrevented()||(this.isShown=!0,this.checkScrollbar(),this.setScrollbar(),this.$body.addClass("modal-open"),this.escape(),this.resize(),this.$element.on("click.dismiss.bs.modal",'[data-dismiss="modal"]',a.proxy(this.hide,this)),this.$dialog.on("mousedown.dismiss.bs.modal",function(){d.$element.one("mouseup.dismiss.bs.modal",function(b){a(b.target).is(d.$element)&&(d.ignoreBackdropClick=!0)})}),this.backdrop(function(){var e=a.support.transition&&d.$element.hasClass("fade");d.$element.parent().length||d.$element.appendTo(d.$body),d.$element.show().scrollTop(0),d.adjustDialog(),e&&d.$element[0].offsetWidth,d.$element.addClass("in"),d.enforceFocus();var f=a.Event("shown.bs.modal",{relatedTarget:b});e?d.$dialog.one("bsTransitionEnd",function(){d.$element.trigger("focus").trigger(f)}).emulateTransitionEnd(c.TRANSITION_DURATION):d.$element.trigger("focus").trigger(f)}))},c.prototype.hide=function(b){b&&b.preventDefault(),b=a.Event("hide.bs.modal"),this.$element.trigger(b),this.isShown&&!b.isDefaultPrevented()&&(this.isShown=!1,this.escape(),this.resize(),a(document).off("focusin.bs.modal"),this.$element.removeClass("in").off("click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"),this.$dialog.off("mousedown.dismiss.bs.modal"),a.support.transition&&this.$element.hasClass("fade")?this.$element.one("bsTransitionEnd",a.proxy(this.hideModal,this)).emulateTransitionEnd(c.TRANSITION_DURATION):this.hideModal())},c.prototype.enforceFocus=function(){a(document).off("focusin.bs.modal").on("focusin.bs.modal",a.proxy(function(a){this.$element[0]===a.target||this.$element.has(a.target).length||this.$element.trigger("focus")},this))},c.prototype.escape=function(){this.isShown&&this.options.keyboard?this.$element.on("keydown.dismiss.bs.modal",a.proxy(function(a){27==a.which&&this.hide()},this)):this.isShown||this.$element.off("keydown.dismiss.bs.modal")},c.prototype.resize=function(){this.isShown?a(window).on("resize.bs.modal",a.proxy(this.handleUpdate,this)):a(window).off("resize.bs.modal")},c.prototype.hideModal=function(){var a=this;this.$element.hide(),this.backdrop(function(){a.$body.removeClass("modal-open"),a.resetAdjustments(),a.resetScrollbar(),a.$element.trigger("hidden.bs.modal")})},c.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},c.prototype.backdrop=function(b){var d=this,e=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var f=a.support.transition&&e;if(this.$backdrop=a(document.createElement("div")).addClass("modal-backdrop "+e).appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",a.proxy(function(a){return this.ignoreBackdropClick?void(this.ignoreBackdropClick=!1):void(a.target===a.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus():this.hide()))},this)),f&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!b)return;f?this.$backdrop.one("bsTransitionEnd",b).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):b()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var g=function(){d.removeBackdrop(),b&&b()};a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",g).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):g()}else b&&b()},c.prototype.handleUpdate=function(){this.adjustDialog()},c.prototype.adjustDialog=function(){var a=this.$element[0].scrollHeight>document.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&a?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!a?this.scrollbarWidth:""})},c.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},c.prototype.checkScrollbar=function(){var a=window.innerWidth;if(!a){var b=document.documentElement.getBoundingClientRect();a=b.right-Math.abs(b.left)}this.bodyIsOverflowing=document.body.clientWidth<a,this.scrollbarWidth=this.measureScrollbar()},c.prototype.setScrollbar=function(){var a=parseInt(this.$body.css("padding-right")||0,10);this.originalBodyPad=document.body.style.paddingRight||"",this.bodyIsOverflowing&&this.$body.css("padding-right",a+this.scrollbarWidth)},c.prototype.resetScrollbar=function(){this.$body.css("padding-right",this.originalBodyPad)},c.prototype.measureScrollbar=function(){var a=document.createElement("div");a.className="modal-scrollbar-measure",this.$body.append(a);var b=a.offsetWidth-a.clientWidth;return this.$body[0].removeChild(a),b};var d=a.fn.modal;a.fn.modal=b,a.fn.modal.Constructor=c,a.fn.modal.noConflict=function(){return a.fn.modal=d,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(c){var d=a(this),e=d.attr("href"),f=a(d.attr("data-target")||e&&e.replace(/.*(?=#[^\s]+$)/,"")),g=f.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(e)&&e},f.data(),d.data());d.is("a")&&c.preventDefault(),f.one("show.bs.modal",function(a){a.isDefaultPrevented()||f.one("hidden.bs.modal",function(){d.is(":visible")&&d.trigger("focus")})}),b.call(f,g,this)})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tooltip"),f="object"==typeof b&&b;(e||!/destroy|hide/.test(b))&&(e||d.data("bs.tooltip",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.type=null,this.options=null,this.enabled=null,this.timeout=null,this.hoverState=null,this.$element=null,this.inState=null,this.init("tooltip",a,b)};c.VERSION="3.3.6",c.TRANSITION_DURATION=150,c.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){if(this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(a.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusin"==b.type?"focus":"hover"]=!0),c.tip().hasClass("in")||"in"==c.hoverState?void(c.hoverState="in"):(clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show())},c.prototype.isInStateTrue=function(){for(var a in this.inState)if(this.inState[a])return!0;return!1},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusout"==b.type?"focus":"hover"]=!1),c.isInStateTrue()?void 0:(clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide())},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var d=a.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!d)return;var e=this,f=this.tip(),g=this.getUID(this.type);this.setContent(),f.attr("id",g),this.$element.attr("aria-describedby",g),this.options.animation&&f.addClass("fade");var h="function"==typeof this.options.placement?this.options.placement.call(this,f[0],this.$element[0]):this.options.placement,i=/\s?auto?\s?/i,j=i.test(h);j&&(h=h.replace(i,"")||"top"),f.detach().css({top:0,left:0,display:"block"}).addClass(h).data("bs."+this.type,this),this.options.container?f.appendTo(this.options.container):f.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var k=this.getPosition(),l=f[0].offsetWidth,m=f[0].offsetHeight;if(j){var n=h,o=this.getPosition(this.$viewport);h="bottom"==h&&k.bottom+m>o.bottom?"top":"top"==h&&k.top-m<o.top?"bottom":"right"==h&&k.right+l>o.width?"left":"left"==h&&k.left-l<o.left?"right":h,f.removeClass(n).addClass(h)}var p=this.getCalculatedOffset(h,k,l,m);this.applyPlacement(p,h);var q=function(){var a=e.hoverState;e.$element.trigger("shown.bs."+e.type),e.hoverState=null,"out"==a&&e.leave(e)};a.support.transition&&this.$tip.hasClass("fade")?f.one("bsTransitionEnd",q).emulateTransitionEnd(c.TRANSITION_DURATION):q()}},c.prototype.applyPlacement=function(b,c){var d=this.tip(),e=d[0].offsetWidth,f=d[0].offsetHeight,g=parseInt(d.css("margin-top"),10),h=parseInt(d.css("margin-left"),10);isNaN(g)&&(g=0),isNaN(h)&&(h=0),b.top+=g,b.left+=h,a.offset.setOffset(d[0],a.extend({using:function(a){d.css({top:Math.round(a.top),left:Math.round(a.left)})}},b),0),d.addClass("in");var i=d[0].offsetWidth,j=d[0].offsetHeight;"top"==c&&j!=f&&(b.top=b.top+f-j);var k=this.getViewportAdjustedDelta(c,b,i,j);k.left?b.left+=k.left:b.top+=k.top;var l=/top|bottom/.test(c),m=l?2*k.left-e+i:2*k.top-f+j,n=l?"offsetWidth":"offsetHeight";d.offset(b),this.replaceArrow(m,d[0][n],l)},c.prototype.replaceArrow=function(a,b,c){this.arrow().css(c?"left":"top",50*(1-a/b)+"%").css(c?"top":"left","")},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle();a.find(".tooltip-inner")[this.options.html?"html":"text"](b),a.removeClass("fade in top bottom left right")},c.prototype.hide=function(b){function d(){"in"!=e.hoverState&&f.detach(),e.$element.removeAttr("aria-describedby").trigger("hidden.bs."+e.type),b&&b()}var e=this,f=a(this.$tip),g=a.Event("hide.bs."+this.type);return this.$element.trigger(g),g.isDefaultPrevented()?void 0:(f.removeClass("in"),a.support.transition&&f.hasClass("fade")?f.one("bsTransitionEnd",d).emulateTransitionEnd(c.TRANSITION_DURATION):d(),this.hoverState=null,this)},c.prototype.fixTitle=function(){var a=this.$element;(a.attr("title")||"string"!=typeof a.attr("data-original-title"))&&a.attr("data-original-title",a.attr("title")||"").attr("title","")},c.prototype.hasContent=function(){return this.getTitle()},c.prototype.getPosition=function(b){b=b||this.$element;var c=b[0],d="BODY"==c.tagName,e=c.getBoundingClientRect();null==e.width&&(e=a.extend({},e,{width:e.right-e.left,height:e.bottom-e.top}));var f=d?{top:0,left:0}:b.offset(),g={scroll:d?document.documentElement.scrollTop||document.body.scrollTop:b.scrollTop()},h=d?{width:a(window).width(),height:a(window).height()}:null;return a.extend({},e,g,h,f)},c.prototype.getCalculatedOffset=function(a,b,c,d){return"bottom"==a?{top:b.top+b.height,left:b.left+b.width/2-c/2}:"top"==a?{top:b.top-d,left:b.left+b.width/2-c/2}:"left"==a?{top:b.top+b.height/2-d/2,left:b.left-c}:{top:b.top+b.height/2-d/2,left:b.left+b.width}},c.prototype.getViewportAdjustedDelta=function(a,b,c,d){var e={top:0,left:0};if(!this.$viewport)return e;var f=this.options.viewport&&this.options.viewport.padding||0,g=this.getPosition(this.$viewport);if(/right|left/.test(a)){var h=b.top-f-g.scroll,i=b.top+f-g.scroll+d;h<g.top?e.top=g.top-h:i>g.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;j<g.left?e.left=g.left-j:k>g.right&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){if(!this.$tip&&(this.$tip=a(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),b?(c.inState.click=!c.inState.click,c.isInStateTrue()?c.enter(c):c.leave(c)):c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){var a=this;clearTimeout(this.timeout),this.hide(function(){a.$element.off("."+a.type).removeData("bs."+a.type),a.$tip&&a.$tip.detach(),a.$tip=null,a.$arrow=null,a.$viewport=null})};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b;(e||!/destroy|hide/.test(b))&&(e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.3.6",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){this.$body=a(document.body),this.$scrollElement=a(a(c).is(document.body)?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",a.proxy(this.process,this)),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.3.6",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b=this,c="offset",d=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),a.isWindow(this.$scrollElement[0])||(c="position",d=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var b=a(this),e=b.data("target")||b.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[c]().top+d,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){b.offsets.push(this[0]),b.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b<e[0])return this.activeTarget=null,this.clear();for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(void 0===e[a+1]||b<e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,this.clear();var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");
d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate.bs.scrollspy")},b.prototype.clear=function(){a(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var d=a.fn.scrollspy;a.fn.scrollspy=c,a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=d,this},a(window).on("load.bs.scrollspy.data-api",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);c.call(b,b.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new c(this)),"string"==typeof b&&e[b]()})}var c=function(b){this.element=a(b)};c.VERSION="3.3.6",c.TRANSITION_DURATION=150,c.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.data("target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a"),f=a.Event("hide.bs.tab",{relatedTarget:b[0]}),g=a.Event("show.bs.tab",{relatedTarget:e[0]});if(e.trigger(f),b.trigger(g),!g.isDefaultPrevented()&&!f.isDefaultPrevented()){var h=a(d);this.activate(b.closest("li"),c),this.activate(h,h.parent(),function(){e.trigger({type:"hidden.bs.tab",relatedTarget:b[0]}),b.trigger({type:"shown.bs.tab",relatedTarget:e[0]})})}}},c.prototype.activate=function(b,d,e){function f(){g.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),b.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),h?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu").length&&b.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),e&&e()}var g=d.find("> .active"),h=e&&a.support.transition&&(g.length&&g.hasClass("fade")||!!d.find("> .fade").length);g.length&&h?g.one("bsTransitionEnd",f).emulateTransitionEnd(c.TRANSITION_DURATION):f(),g.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this};var e=function(c){c.preventDefault(),b.call(a(this),"show")};a(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',e).on("click.bs.tab.data-api",'[data-toggle="pill"]',e)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.3.6",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getState=function(a,b,c,d){var e=this.$target.scrollTop(),f=this.$element.offset(),g=this.$target.height();if(null!=c&&"top"==this.affixed)return c>e?"top":!1;if("bottom"==this.affixed)return null!=c?e+this.unpin<=f.top?!1:"bottom":a-d>=e+g?!1:"bottom";var h=null==this.affixed,i=h?e:f.top,j=h?g:b;return null!=c&&c>=e?"top":null!=d&&i+j>=a-d?"bottom":!1},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=this.$element.height(),d=this.options.offset,e=d.top,f=d.bottom,g=Math.max(a(document).height(),a(document.body).height());"object"!=typeof d&&(f=e=d),"function"==typeof e&&(e=d.top(this.$element)),"function"==typeof f&&(f=d.bottom(this.$element));var h=this.getState(g,b,e,f);if(this.affixed!=h){null!=this.unpin&&this.$element.css("top","");var i="affix"+(h?"-"+h:""),j=a.Event(i+".bs.affix");if(this.$element.trigger(j),j.isDefaultPrevented())return;this.affixed=h,this.unpin="bottom"==h?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(i).trigger(i.replace("affix","affixed")+".bs.affix")}"bottom"==h&&this.$element.offset({top:g-b-f})}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},null!=d.offsetBottom&&(d.offset.bottom=d.offsetBottom),null!=d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery);
/*! jQuery v2.1.4 | (c) 2005, 2015 jQuery Foundation, Inc. | jquery.org/license */
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k={},l=a.document,m="2.1.4",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){return!n.isArray(a)&&a-parseFloat(a)+1>=0},isPlainObject:function(a){return"object"!==n.type(a)||a.nodeType||n.isWindow(a)?!1:a.constructor&&!j.call(a.constructor.prototype,"isPrototypeOf")?!1:!0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=l.createElement("script"),b.text=a,l.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:g.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(e=d.call(arguments,2),f=function(){return a.apply(b||this,e.concat(d.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:k}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b="length"in a&&a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ha(),z=ha(),A=ha(),B=function(a,b){return a===b&&(l=!0),0},C=1<<31,D={}.hasOwnProperty,E=[],F=E.pop,G=E.push,H=E.push,I=E.slice,J=function(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return c;return-1},K="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",N=M.replace("w","w#"),O="\\["+L+"*("+M+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+N+"))|)"+L+"*\\]",P=":("+M+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+O+")*)|.*)\\)|)",Q=new RegExp(L+"+","g"),R=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),S=new RegExp("^"+L+"*,"+L+"*"),T=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),U=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),V=new RegExp(P),W=new RegExp("^"+N+"$"),X={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M.replace("w","w*")+")"),ATTR:new RegExp("^"+O),PSEUDO:new RegExp("^"+P),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,Z=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,_=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,aa=/[+~]/,ba=/'|\\/g,ca=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),da=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},ea=function(){m()};try{H.apply(E=I.call(v.childNodes),v.childNodes),E[v.childNodes.length].nodeType}catch(fa){H={apply:E.length?function(a,b){G.apply(a,I.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function ga(a,b,d,e){var f,h,j,k,l,o,r,s,w,x;if((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,d=d||[],k=b.nodeType,"string"!=typeof a||!a||1!==k&&9!==k&&11!==k)return d;if(!e&&p){if(11!==k&&(f=_.exec(a)))if(j=f[1]){if(9===k){if(h=b.getElementById(j),!h||!h.parentNode)return d;if(h.id===j)return d.push(h),d}else if(b.ownerDocument&&(h=b.ownerDocument.getElementById(j))&&t(b,h)&&h.id===j)return d.push(h),d}else{if(f[2])return H.apply(d,b.getElementsByTagName(a)),d;if((j=f[3])&&c.getElementsByClassName)return H.apply(d,b.getElementsByClassName(j)),d}if(c.qsa&&(!q||!q.test(a))){if(s=r=u,w=b,x=1!==k&&a,1===k&&"object"!==b.nodeName.toLowerCase()){o=g(a),(r=b.getAttribute("id"))?s=r.replace(ba,"\\$&"):b.setAttribute("id",s),s="[id='"+s+"'] ",l=o.length;while(l--)o[l]=s+ra(o[l]);w=aa.test(a)&&pa(b.parentNode)||b,x=o.join(",")}if(x)try{return H.apply(d,w.querySelectorAll(x)),d}catch(y){}finally{r||b.removeAttribute("id")}}}return i(a.replace(R,"$1"),b,d,e)}function ha(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ia(a){return a[u]=!0,a}function ja(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ka(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function la(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||C)-(~a.sourceIndex||C);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function na(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function oa(a){return ia(function(b){return b=+b,ia(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function pa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=ga.support={},f=ga.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=ga.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=g.documentElement,e=g.defaultView,e&&e!==e.top&&(e.addEventListener?e.addEventListener("unload",ea,!1):e.attachEvent&&e.attachEvent("onunload",ea)),p=!f(g),c.attributes=ja(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ja(function(a){return a.appendChild(g.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=$.test(g.getElementsByClassName),c.getById=ja(function(a){return o.appendChild(a).id=u,!g.getElementsByName||!g.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ca,da);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ca,da);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=$.test(g.querySelectorAll))&&(ja(function(a){o.appendChild(a).innerHTML="<a id='"+u+"'></a><select id='"+u+"-\f]' msallowcapture=''><option selected=''></option></select>",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+L+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+L+"*(?:value|"+K+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ja(function(a){var b=g.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+L+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=$.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ja(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",P)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=$.test(o.compareDocumentPosition),t=b||$.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===g||a.ownerDocument===v&&t(v,a)?-1:b===g||b.ownerDocument===v&&t(v,b)?1:k?J(k,a)-J(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,h=[a],i=[b];if(!e||!f)return a===g?-1:b===g?1:e?-1:f?1:k?J(k,a)-J(k,b):0;if(e===f)return la(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)i.unshift(c);while(h[d]===i[d])d++;return d?la(h[d],i[d]):h[d]===v?-1:i[d]===v?1:0},g):n},ga.matches=function(a,b){return ga(a,null,null,b)},ga.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(U,"='$1']"),!(!c.matchesSelector||!p||r&&r.test(b)||q&&q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return ga(b,n,null,[a]).length>0},ga.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},ga.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&D.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},ga.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},ga.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=ga.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=ga.selectors={cacheLength:50,createPseudo:ia,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ca,da),a[3]=(a[3]||a[4]||a[5]||"").replace(ca,da),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||ga.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&ga.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return X.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&V.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ca,da).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+L+")"+a+"("+L+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=ga.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(Q," ")+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){k=q[u]||(q[u]={}),j=k[a]||[],n=j[0]===w&&j[1],m=j[0]===w&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[w,n,m];break}}else if(s&&(j=(b[u]||(b[u]={}))[a])&&j[0]===w)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(s&&((l[u]||(l[u]={}))[a]=[w,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||ga.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ia(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=J(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ia(function(a){var b=[],c=[],d=h(a.replace(R,"$1"));return d[u]?ia(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ia(function(a){return function(b){return ga(a,b).length>0}}),contains:ia(function(a){return a=a.replace(ca,da),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ia(function(a){return W.test(a||"")||ga.error("unsupported lang: "+a),a=a.replace(ca,da).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Z.test(a.nodeName)},input:function(a){return Y.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:oa(function(){return[0]}),last:oa(function(a,b){return[b-1]}),eq:oa(function(a,b,c){return[0>c?c+b:c]}),even:oa(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:oa(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:oa(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:oa(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=ma(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=na(b);function qa(){}qa.prototype=d.filters=d.pseudos,d.setFilters=new qa,g=ga.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=S.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=T.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(R," ")}),h=h.slice(c.length));for(g in d.filter)!(e=X[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?ga.error(a):z(a,i).slice(0)};function ra(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function sa(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[u]||(b[u]={}),(h=i[d])&&h[0]===w&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function ta(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function ua(a,b,c){for(var d=0,e=b.length;e>d;d++)ga(a,b[d],c);return c}function va(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function wa(a,b,c,d,e,f){return d&&!d[u]&&(d=wa(d)),e&&!e[u]&&(e=wa(e,f)),ia(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||ua(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:va(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=va(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?J(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=va(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):H.apply(g,r)})}function xa(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=sa(function(a){return a===b},h,!0),l=sa(function(a){return J(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];f>i;i++)if(c=d.relative[a[i].type])m=[sa(ta(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return wa(i>1&&ta(m),i>1&&ra(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(R,"$1"),c,e>i&&xa(a.slice(i,e)),f>e&&xa(a=a.slice(e)),f>e&&ra(a))}m.push(c)}return ta(m)}function ya(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,m,o,p=0,q="0",r=f&&[],s=[],t=j,u=f||e&&d.find.TAG("*",k),v=w+=null==t?1:Math.random()||.1,x=u.length;for(k&&(j=g!==n&&g);q!==x&&null!=(l=u[q]);q++){if(e&&l){m=0;while(o=a[m++])if(o(l,g,h)){i.push(l);break}k&&(w=v)}c&&((l=!o&&l)&&p--,f&&r.push(l))}if(p+=q,c&&q!==p){m=0;while(o=b[m++])o(r,s,g,h);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=F.call(i));s=va(s)}H.apply(i,s),k&&!f&&s.length>0&&p+b.length>1&&ga.uniqueSort(i)}return k&&(w=v,j=t),r};return c?ia(f):f}return h=ga.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=xa(b[c]),f[u]?d.push(f):e.push(f);f=A(a,ya(e,d)),f.selector=a}return f},i=ga.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(ca,da),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=X.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(ca,da),aa.test(j[0].type)&&pa(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&ra(j),!a)return H.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,aa.test(a)&&pa(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ja(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ja(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||ka("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ja(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ka("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ja(function(a){return null==a.getAttribute("disabled")})||ka(K,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),ga}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return g.call(b,a)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,A=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:z.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:l,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}return d=l.getElementById(c[2]),d&&d.parentNode&&(this.length=1,this[0]=d),this.context=l,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};A.prototype=n.fn,y=n(l);var B=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?g.call(n(a),this[0]):g.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function D(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return D(a,"nextSibling")},prev:function(a){return D(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(C[a]||n.unique(e),B.test(a)&&e.reverse()),this.pushStack(e)}});var E=/\S+/g,F={};function G(a){var b=F[a]={};return n.each(a.match(E)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?F[a]||G(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(b=a.memory&&l,c=!0,g=e||0,e=0,f=h.length,d=!0;h&&f>g;g++)if(h[g].apply(l[0],l[1])===!1&&a.stopOnFalse){b=!1;break}d=!1,h&&(i?i.length&&j(i.shift()):b?h=[]:k.disable())},k={add:function(){if(h){var c=h.length;!function g(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&g(c)})}(arguments),d?f=h.length:b&&(e=c,j(b))}return this},remove:function(){return h&&n.each(arguments,function(a,b){var c;while((c=n.inArray(b,h,c))>-1)h.splice(c,1),d&&(f>=c&&f--,g>=c&&g--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],f=0,this},disable:function(){return h=i=b=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,b||k.disable(),this},locked:function(){return!i},fireWith:function(a,b){return!h||c&&!i||(b=b||[],b=[a,b.slice?b.slice():b],d?i.push(b):j(b)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!c}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var H;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(H.resolveWith(l,[n]),n.fn.triggerHandler&&(n(l).triggerHandler("ready"),n(l).off("ready"))))}});function I(){l.removeEventListener("DOMContentLoaded",I,!1),a.removeEventListener("load",I,!1),n.ready()}n.ready.promise=function(b){return H||(H=n.Deferred(),"complete"===l.readyState?setTimeout(n.ready):(l.addEventListener("DOMContentLoaded",I,!1),a.addEventListener("load",I,!1))),H.promise(b)},n.ready.promise();var J=n.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)n.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f};n.acceptData=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function K(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=n.expando+K.uid++}K.uid=1,K.accepts=n.acceptData,K.prototype={key:function(a){if(!K.accepts(a))return 0;var b={},c=a[this.expando];if(!c){c=K.uid++;try{b[this.expando]={value:c},Object.defineProperties(a,b)}catch(d){b[this.expando]=c,n.extend(a,b)}}return this.cache[c]||(this.cache[c]={}),c},set:function(a,b,c){var d,e=this.key(a),f=this.cache[e];if("string"==typeof b)f[b]=c;else if(n.isEmptyObject(f))n.extend(this.cache[e],b);else for(d in b)f[d]=b[d];return f},get:function(a,b){var c=this.cache[this.key(a)];return void 0===b?c:c[b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=this.key(a),g=this.cache[f];if(void 0===b)this.cache[f]={};else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in g?d=[b,e]:(d=e,d=d in g?[d]:d.match(E)||[])),c=d.length;while(c--)delete g[d[c]]}},hasData:function(a){return!n.isEmptyObject(this.cache[a[this.expando]]||{})},discard:function(a){a[this.expando]&&delete this.cache[a[this.expando]]}};var L=new K,M=new K,N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(O,"-$1").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}M.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return M.hasData(a)||L.hasData(a)},data:function(a,b,c){
return M.access(a,b,c)},removeData:function(a,b){M.remove(a,b)},_data:function(a,b,c){return L.access(a,b,c)},_removeData:function(a,b){L.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=M.get(f),1===f.nodeType&&!L.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));L.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){M.set(this,a)}):J(this,function(b){var c,d=n.camelCase(a);if(f&&void 0===b){if(c=M.get(f,a),void 0!==c)return c;if(c=M.get(f,d),void 0!==c)return c;if(c=P(f,d,void 0),void 0!==c)return c}else this.each(function(){var c=M.get(this,d);M.set(this,d,b),-1!==a.indexOf("-")&&void 0!==c&&M.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){M.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=L.get(a,b),c&&(!d||n.isArray(c)?d=L.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return L.get(a,c)||L.access(a,c,{empty:n.Callbacks("once memory").add(function(){L.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=L.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var Q=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,R=["Top","Right","Bottom","Left"],S=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)},T=/^(?:checkbox|radio)$/i;!function(){var a=l.createDocumentFragment(),b=a.appendChild(l.createElement("div")),c=l.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),k.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",k.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var U="undefined";k.focusinBubbles="onfocusin"in a;var V=/^key/,W=/^(?:mouse|pointer|contextmenu)|click/,X=/^(?:focusinfocus|focusoutblur)$/,Y=/^([^.]*)(?:\.(.+)|)$/;function Z(){return!0}function $(){return!1}function _(){try{return l.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return typeof n!==U&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(E)||[""],j=b.length;while(j--)h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g,!1)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.hasData(a)&&L.get(a);if(r&&(i=r.events)){b=(b||"").match(E)||[""],j=b.length;while(j--)if(h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&(delete r.handle,L.remove(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,m,o,p=[d||l],q=j.call(b,"type")?b.type:b,r=j.call(b,"namespace")?b.namespace.split("."):[];if(g=h=d=d||l,3!==d.nodeType&&8!==d.nodeType&&!X.test(q+n.event.triggered)&&(q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),k=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=r.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),o=n.event.special[q]||{},e||!o.trigger||o.trigger.apply(d,c)!==!1)){if(!e&&!o.noBubble&&!n.isWindow(d)){for(i=o.delegateType||q,X.test(i+q)||(g=g.parentNode);g;g=g.parentNode)p.push(g),h=g;h===(d.ownerDocument||l)&&p.push(h.defaultView||h.parentWindow||a)}f=0;while((g=p[f++])&&!b.isPropagationStopped())b.type=f>1?i:o.bindType||q,m=(L.get(g,"events")||{})[b.type]&&L.get(g,"handle"),m&&m.apply(g,c),m=k&&g[k],m&&m.apply&&n.acceptData(g)&&(b.result=m.apply(g,c),b.result===!1&&b.preventDefault());return b.type=q,e||b.isDefaultPrevented()||o._default&&o._default.apply(p.pop(),c)!==!1||!n.acceptData(d)||k&&n.isFunction(d[q])&&!n.isWindow(d)&&(h=d[k],h&&(d[k]=null),n.event.triggered=q,d[q](),n.event.triggered=void 0,h&&(d[k]=h)),b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(L.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(g.namespace))&&(a.handleObj=g,a.data=g.data,e=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(a.result=e)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!==this;i=i.parentNode||this)if(i.disabled!==!0||"click"!==a.type){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>=0:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,d,e,f=b.button;return null==a.pageX&&null!=b.clientX&&(c=a.target.ownerDocument||l,d=c.documentElement,e=c.body,a.pageX=b.clientX+(d&&d.scrollLeft||e&&e.scrollLeft||0)-(d&&d.clientLeft||e&&e.clientLeft||0),a.pageY=b.clientY+(d&&d.scrollTop||e&&e.scrollTop||0)-(d&&d.clientTop||e&&e.clientTop||0)),a.which||void 0===f||(a.which=1&f?1:2&f?3:4&f?2:0),a}},fix:function(a){if(a[n.expando])return a;var b,c,d,e=a.type,f=a,g=this.fixHooks[e];g||(this.fixHooks[e]=g=W.test(e)?this.mouseHooks:V.test(e)?this.keyHooks:{}),d=g.props?this.props.concat(g.props):this.props,a=new n.Event(f),b=d.length;while(b--)c=d[b],a[c]=f[c];return a.target||(a.target=l),3===a.target.nodeType&&(a.target=a.target.parentNode),g.filter?g.filter(a,f):a},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==_()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===_()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&n.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c,d){var e=n.extend(new n.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?n.event.trigger(e,null,b):n.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?Z:$):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={isDefaultPrevented:$,isPropagationStopped:$,isImmediatePropagationStopped:$,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=Z,a&&a.preventDefault&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=Z,a&&a.stopPropagation&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=Z,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!n.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),k.focusinBubbles||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a),!0)};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=L.access(d,b);e||d.addEventListener(a,c,!0),L.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=L.access(d,b)-1;e?L.access(d,b,e):(d.removeEventListener(a,c,!0),L.remove(d,b))}}}),n.fn.extend({on:function(a,b,c,d,e){var f,g;if("object"==typeof a){"string"!=typeof b&&(c=c||b,b=void 0);for(g in a)this.on(g,b,c,a[g],e);return this}if(null==c&&null==d?(d=b,c=b=void 0):null==d&&("string"==typeof b?(d=c,c=void 0):(d=c,c=b,b=void 0)),d===!1)d=$;else if(!d)return this;return 1===e&&(f=d,d=function(a){return n().off(a),f.apply(this,arguments)},d.guid=f.guid||(f.guid=n.guid++)),this.each(function(){n.event.add(this,a,d,c,b)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=$),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});var aa=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,ba=/<([\w:]+)/,ca=/<|&#?\w+;/,da=/<(?:script|style|link)/i,ea=/checked\s*(?:[^=]|=\s*.checked.)/i,fa=/^$|\/(?:java|ecma)script/i,ga=/^true\/(.*)/,ha=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,ia={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ia.optgroup=ia.option,ia.tbody=ia.tfoot=ia.colgroup=ia.caption=ia.thead,ia.th=ia.td;function ja(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function ka(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function la(a){var b=ga.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function ma(a,b){for(var c=0,d=a.length;d>c;c++)L.set(a[c],"globalEval",!b||L.get(b[c],"globalEval"))}function na(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(L.hasData(a)&&(f=L.access(a),g=L.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}M.hasData(a)&&(h=M.access(a),i=n.extend({},h),M.set(b,i))}}function oa(a,b){var c=a.getElementsByTagName?a.getElementsByTagName(b||"*"):a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function pa(a,b){var c=b.nodeName.toLowerCase();"input"===c&&T.test(a.type)?b.checked=a.checked:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}n.extend({clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(k.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=oa(h),f=oa(a),d=0,e=f.length;e>d;d++)pa(f[d],g[d]);if(b)if(c)for(f=f||oa(a),g=g||oa(h),d=0,e=f.length;e>d;d++)na(f[d],g[d]);else na(a,h);return g=oa(h,"script"),g.length>0&&ma(g,!i&&oa(a,"script")),h},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k=b.createDocumentFragment(),l=[],m=0,o=a.length;o>m;m++)if(e=a[m],e||0===e)if("object"===n.type(e))n.merge(l,e.nodeType?[e]:e);else if(ca.test(e)){f=f||k.appendChild(b.createElement("div")),g=(ba.exec(e)||["",""])[1].toLowerCase(),h=ia[g]||ia._default,f.innerHTML=h[1]+e.replace(aa,"<$1></$2>")+h[2],j=h[0];while(j--)f=f.lastChild;n.merge(l,f.childNodes),f=k.firstChild,f.textContent=""}else l.push(b.createTextNode(e));k.textContent="",m=0;while(e=l[m++])if((!d||-1===n.inArray(e,d))&&(i=n.contains(e.ownerDocument,e),f=oa(k.appendChild(e),"script"),i&&ma(f),c)){j=0;while(e=f[j++])fa.test(e.type||"")&&c.push(e)}return k},cleanData:function(a){for(var b,c,d,e,f=n.event.special,g=0;void 0!==(c=a[g]);g++){if(n.acceptData(c)&&(e=c[L.expando],e&&(b=L.cache[e]))){if(b.events)for(d in b.events)f[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);L.cache[e]&&delete L.cache[e]}delete M.cache[c[M.expando]]}}}),n.fn.extend({text:function(a){return J(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&(this.textContent=a)})},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=ja(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=ja(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(oa(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&ma(oa(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(oa(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return J(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!da.test(a)&&!ia[(ba.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(aa,"<$1></$2>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(oa(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(oa(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,l=this.length,m=this,o=l-1,p=a[0],q=n.isFunction(p);if(q||l>1&&"string"==typeof p&&!k.checkClone&&ea.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(l&&(c=n.buildFragment(a,this[0].ownerDocument,!1,this),d=c.firstChild,1===c.childNodes.length&&(c=d),d)){for(f=n.map(oa(c,"script"),ka),g=f.length;l>j;j++)h=c,j!==o&&(h=n.clone(h,!0,!0),g&&n.merge(f,oa(h,"script"))),b.call(this[j],h,j);if(g)for(i=f[f.length-1].ownerDocument,n.map(f,la),j=0;g>j;j++)h=f[j],fa.test(h.type||"")&&!L.access(h,"globalEval")&&n.contains(i,h)&&(h.src?n._evalUrl&&n._evalUrl(h.src):n.globalEval(h.textContent.replace(ha,"")))}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),g=e.length-1,h=0;g>=h;h++)c=h===g?this:this.clone(!0),n(e[h])[b](c),f.apply(d,c.get());return this.pushStack(d)}});var qa,ra={};function sa(b,c){var d,e=n(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:n.css(e[0],"display");return e.detach(),f}function ta(a){var b=l,c=ra[a];return c||(c=sa(a,b),"none"!==c&&c||(qa=(qa||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=qa[0].contentDocument,b.write(),b.close(),c=sa(a,b),qa.detach()),ra[a]=c),c}var ua=/^margin/,va=new RegExp("^("+Q+")(?!px)[a-z%]+$","i"),wa=function(b){return b.ownerDocument.defaultView.opener?b.ownerDocument.defaultView.getComputedStyle(b,null):a.getComputedStyle(b,null)};function xa(a,b,c){var d,e,f,g,h=a.style;return c=c||wa(a),c&&(g=c.getPropertyValue(b)||c[b]),c&&(""!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),va.test(g)&&ua.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0!==g?g+"":g}function ya(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}!function(){var b,c,d=l.documentElement,e=l.createElement("div"),f=l.createElement("div");if(f.style){f.style.backgroundClip="content-box",f.cloneNode(!0).style.backgroundClip="",k.clearCloneStyle="content-box"===f.style.backgroundClip,e.style.cssText="border:0;width:0;height:0;top:0;left:-9999px;margin-top:1px;position:absolute",e.appendChild(f);function g(){f.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",f.innerHTML="",d.appendChild(e);var g=a.getComputedStyle(f,null);b="1%"!==g.top,c="4px"===g.width,d.removeChild(e)}a.getComputedStyle&&n.extend(k,{pixelPosition:function(){return g(),b},boxSizingReliable:function(){return null==c&&g(),c},reliableMarginRight:function(){var b,c=f.appendChild(l.createElement("div"));return c.style.cssText=f.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",f.style.width="1px",d.appendChild(e),b=!parseFloat(a.getComputedStyle(c,null).marginRight),d.removeChild(e),f.removeChild(c),b}})}}(),n.swap=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};var za=/^(none|table(?!-c[ea]).+)/,Aa=new RegExp("^("+Q+")(.*)$","i"),Ba=new RegExp("^([+-])=("+Q+")","i"),Ca={position:"absolute",visibility:"hidden",display:"block"},Da={letterSpacing:"0",fontWeight:"400"},Ea=["Webkit","O","Moz","ms"];function Fa(a,b){if(b in a)return b;var c=b[0].toUpperCase()+b.slice(1),d=b,e=Ea.length;while(e--)if(b=Ea[e]+c,b in a)return b;return d}function Ga(a,b,c){var d=Aa.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function Ha(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+R[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+R[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+R[f]+"Width",!0,e))):(g+=n.css(a,"padding"+R[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+R[f]+"Width",!0,e)));return g}function Ia(a,b,c){var d=!0,e="width"===b?a.offsetWidth:a.offsetHeight,f=wa(a),g="border-box"===n.css(a,"boxSizing",!1,f);if(0>=e||null==e){if(e=xa(a,b,f),(0>e||null==e)&&(e=a.style[b]),va.test(e))return e;d=g&&(k.boxSizingReliable()||e===a.style[b]),e=parseFloat(e)||0}return e+Ha(a,b,c||(g?"border":"content"),d,f)+"px"}function Ja(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=L.get(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&S(d)&&(f[g]=L.access(d,"olddisplay",ta(d.nodeName)))):(e=S(d),"none"===c&&e||L.set(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=xa(a,"opacity");return""===c?"1":c}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;return b=n.cssProps[h]||(n.cssProps[h]=Fa(i,h)),g=n.cssHooks[b]||n.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b]:(f=typeof c,"string"===f&&(e=Ba.exec(c))&&(c=(e[1]+1)*e[2]+parseFloat(n.css(a,b)),f="number"),null!=c&&c===c&&("number"!==f||n.cssNumber[h]||(c+="px"),k.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=Fa(a.style,h)),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=xa(a,b,d)),"normal"===e&&b in Da&&(e=Da[b]),""===c||c?(f=parseFloat(e),c===!0||n.isNumeric(f)?f||0:e):e}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?za.test(n.css(a,"display"))&&0===a.offsetWidth?n.swap(a,Ca,function(){return Ia(a,b,d)}):Ia(a,b,d):void 0},set:function(a,c,d){var e=d&&wa(a);return Ga(a,c,d?Ha(a,b,d,"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),n.cssHooks.marginRight=ya(k.reliableMarginRight,function(a,b){return b?n.swap(a,{display:"inline-block"},xa,[a,"marginRight"]):void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+R[d]+b]=f[d]||f[d-2]||f[0];return e}},ua.test(a)||(n.cssHooks[a+b].set=Ga)}),n.fn.extend({css:function(a,b){return J(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=wa(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return Ja(this,!0)},hide:function(){return Ja(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){S(this)?n(this).show():n(this).hide()})}});function Ka(a,b,c,d,e){return new Ka.prototype.init(a,b,c,d,e)}n.Tween=Ka,Ka.prototype={constructor:Ka,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=Ka.propHooks[this.prop];return a&&a.get?a.get(this):Ka.propHooks._default.get(this)},run:function(a){var b,c=Ka.propHooks[this.prop];return this.options.duration?this.pos=b=n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):Ka.propHooks._default.set(this),this}},Ka.prototype.init.prototype=Ka.prototype,Ka.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[n.cssProps[a.prop]]||n.cssHooks[a.prop])?n.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},Ka.propHooks.scrollTop=Ka.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},n.fx=Ka.prototype.init,n.fx.step={};var La,Ma,Na=/^(?:toggle|show|hide)$/,Oa=new RegExp("^(?:([+-])=|)("+Q+")([a-z%]*)$","i"),Pa=/queueHooks$/,Qa=[Va],Ra={"*":[function(a,b){var c=this.createTween(a,b),d=c.cur(),e=Oa.exec(b),f=e&&e[3]||(n.cssNumber[a]?"":"px"),g=(n.cssNumber[a]||"px"!==f&&+d)&&Oa.exec(n.css(c.elem,a)),h=1,i=20;if(g&&g[3]!==f){f=f||g[3],e=e||[],g=+d||1;do h=h||".5",g/=h,n.style(c.elem,a,g+f);while(h!==(h=c.cur()/d)&&1!==h&&--i)}return e&&(g=c.start=+g||+d||0,c.unit=f,c.end=e[1]?g+(e[1]+1)*e[2]:+e[2]),c}]};function Sa(){return setTimeout(function(){La=void 0}),La=n.now()}function Ta(a,b){var c,d=0,e={height:a};for(b=b?1:0;4>d;d+=2-b)c=R[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function Ua(a,b,c){for(var d,e=(Ra[b]||[]).concat(Ra["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function Va(a,b,c){var d,e,f,g,h,i,j,k,l=this,m={},o=a.style,p=a.nodeType&&S(a),q=L.get(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,l.always(function(){l.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=n.css(a,"display"),k="none"===j?L.get(a,"olddisplay")||ta(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(o.display="inline-block")),c.overflow&&(o.overflow="hidden",l.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],Na.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}m[d]=q&&q[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(m))"inline"===("none"===j?ta(a.nodeName):j)&&(o.display=j);else{q?"hidden"in q&&(p=q.hidden):q=L.access(a,"fxshow",{}),f&&(q.hidden=!p),p?n(a).show():l.done(function(){n(a).hide()}),l.done(function(){var b;L.remove(a,"fxshow");for(b in m)n.style(a,b,m[b])});for(d in m)g=Ua(p?q[d]:0,d,l),d in q||(q[d]=g.start,p&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function Wa(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function Xa(a,b,c){var d,e,f=0,g=Qa.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=La||Sa(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:La||Sa(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(Wa(k,j.opts.specialEasing);g>f;f++)if(d=Qa[f].call(j,a,k,j.opts))return d;return n.map(k,Ua,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(Xa,{tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],Ra[c]=Ra[c]||[],Ra[c].unshift(b)},prefilter:function(a,b){b?Qa.unshift(a):Qa.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(S).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=Xa(this,n.extend({},a),f);(e||L.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=L.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&Pa.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=L.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(Ta(b,!0),a,d,e)}}),n.each({slideDown:Ta("show"),slideUp:Ta("hide"),slideToggle:Ta("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=0,c=n.timers;for(La=n.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||n.fx.stop(),La=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){Ma||(Ma=setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){clearInterval(Ma),Ma=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(a,b){return a=n.fx?n.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},function(){var a=l.createElement("input"),b=l.createElement("select"),c=b.appendChild(l.createElement("option"));a.type="checkbox",k.checkOn=""!==a.value,k.optSelected=c.selected,b.disabled=!0,k.optDisabled=!c.disabled,a=l.createElement("input"),a.value="t",a.type="radio",k.radioValue="t"===a.value}();var Ya,Za,$a=n.expr.attrHandle;n.fn.extend({attr:function(a,b){return J(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(a&&3!==f&&8!==f&&2!==f)return typeof a.getAttribute===U?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),d=n.attrHooks[b]||(n.expr.match.bool.test(b)?Za:Ya)),
void 0===c?d&&"get"in d&&null!==(e=d.get(a,b))?e:(e=n.find.attr(a,b),null==e?void 0:e):null!==c?d&&"set"in d&&void 0!==(e=d.set(a,c,b))?e:(a.setAttribute(b,c+""),c):void n.removeAttr(a,b))},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(E);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)&&(a[d]=!1),a.removeAttribute(c)},attrHooks:{type:{set:function(a,b){if(!k.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}}}),Za={set:function(a,b,c){return b===!1?n.removeAttr(a,c):a.setAttribute(c,c),c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=$a[b]||n.find.attr;$a[b]=function(a,b,d){var e,f;return d||(f=$a[b],$a[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,$a[b]=f),e}});var _a=/^(?:input|select|textarea|button)$/i;n.fn.extend({prop:function(a,b){return J(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[n.propFix[a]||a]})}}),n.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(a,b,c){var d,e,f,g=a.nodeType;if(a&&3!==g&&8!==g&&2!==g)return f=1!==g||!n.isXMLDoc(a),f&&(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){return a.hasAttribute("tabindex")||_a.test(a.nodeName)||a.href?a.tabIndex:-1}}}}),k.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this});var ab=/[\t\r\n\f]/g;n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h="string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ab," "):" ")){f=0;while(e=b[f++])d.indexOf(" "+e+" ")<0&&(d+=e+" ");g=n.trim(d),c.className!==g&&(c.className=g)}return this},removeClass:function(a){var b,c,d,e,f,g,h=0===arguments.length||"string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ab," "):"")){f=0;while(e=b[f++])while(d.indexOf(" "+e+" ")>=0)d=d.replace(" "+e+" "," ");g=a?n.trim(d):"",c.className!==g&&(c.className=g)}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):this.each(n.isFunction(a)?function(c){n(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c){var b,d=0,e=n(this),f=a.match(E)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(c===U||"boolean"===c)&&(this.className&&L.set(this,"__className__",this.className),this.className=this.className||a===!1?"":L.get(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(ab," ").indexOf(b)>=0)return!0;return!1}});var bb=/\r/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(bb,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a))}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||(k.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=n.inArray(d.value,f)>=0)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>=0:void 0}},k.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}});var cb=n.now(),db=/\?/;n.parseJSON=function(a){return JSON.parse(a+"")},n.parseXML=function(a){var b,c;if(!a||"string"!=typeof a)return null;try{c=new DOMParser,b=c.parseFromString(a,"text/xml")}catch(d){b=void 0}return(!b||b.getElementsByTagName("parsererror").length)&&n.error("Invalid XML: "+a),b};var eb=/#.*$/,fb=/([?&])_=[^&]*/,gb=/^(.*?):[ \t]*([^\r\n]*)$/gm,hb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,ib=/^(?:GET|HEAD)$/,jb=/^\/\//,kb=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,lb={},mb={},nb="*/".concat("*"),ob=a.location.href,pb=kb.exec(ob.toLowerCase())||[];function qb(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(E)||[];if(n.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function rb(a,b,c,d){var e={},f=a===mb;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function sb(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&n.extend(!0,a,d),a}function tb(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function ub(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:ob,type:"GET",isLocal:hb.test(pb[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":nb,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?sb(sb(a,n.ajaxSettings),b):sb(n.ajaxSettings,a)},ajaxPrefilter:qb(lb),ajaxTransport:qb(mb),ajax:function(a,b){"object"==typeof a&&(b=a,a=void 0),b=b||{};var c,d,e,f,g,h,i,j,k=n.ajaxSetup({},b),l=k.context||k,m=k.context&&(l.nodeType||l.jquery)?n(l):n.event,o=n.Deferred(),p=n.Callbacks("once memory"),q=k.statusCode||{},r={},s={},t=0,u="canceled",v={readyState:0,getResponseHeader:function(a){var b;if(2===t){if(!f){f={};while(b=gb.exec(e))f[b[1].toLowerCase()]=b[2]}b=f[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===t?e:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return t||(a=s[c]=s[c]||a,r[a]=b),this},overrideMimeType:function(a){return t||(k.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>t)for(b in a)q[b]=[q[b],a[b]];else v.always(a[v.status]);return this},abort:function(a){var b=a||u;return c&&c.abort(b),x(0,b),this}};if(o.promise(v).complete=p.add,v.success=v.done,v.error=v.fail,k.url=((a||k.url||ob)+"").replace(eb,"").replace(jb,pb[1]+"//"),k.type=b.method||b.type||k.method||k.type,k.dataTypes=n.trim(k.dataType||"*").toLowerCase().match(E)||[""],null==k.crossDomain&&(h=kb.exec(k.url.toLowerCase()),k.crossDomain=!(!h||h[1]===pb[1]&&h[2]===pb[2]&&(h[3]||("http:"===h[1]?"80":"443"))===(pb[3]||("http:"===pb[1]?"80":"443")))),k.data&&k.processData&&"string"!=typeof k.data&&(k.data=n.param(k.data,k.traditional)),rb(lb,k,b,v),2===t)return v;i=n.event&&k.global,i&&0===n.active++&&n.event.trigger("ajaxStart"),k.type=k.type.toUpperCase(),k.hasContent=!ib.test(k.type),d=k.url,k.hasContent||(k.data&&(d=k.url+=(db.test(d)?"&":"?")+k.data,delete k.data),k.cache===!1&&(k.url=fb.test(d)?d.replace(fb,"$1_="+cb++):d+(db.test(d)?"&":"?")+"_="+cb++)),k.ifModified&&(n.lastModified[d]&&v.setRequestHeader("If-Modified-Since",n.lastModified[d]),n.etag[d]&&v.setRequestHeader("If-None-Match",n.etag[d])),(k.data&&k.hasContent&&k.contentType!==!1||b.contentType)&&v.setRequestHeader("Content-Type",k.contentType),v.setRequestHeader("Accept",k.dataTypes[0]&&k.accepts[k.dataTypes[0]]?k.accepts[k.dataTypes[0]]+("*"!==k.dataTypes[0]?", "+nb+"; q=0.01":""):k.accepts["*"]);for(j in k.headers)v.setRequestHeader(j,k.headers[j]);if(k.beforeSend&&(k.beforeSend.call(l,v,k)===!1||2===t))return v.abort();u="abort";for(j in{success:1,error:1,complete:1})v[j](k[j]);if(c=rb(mb,k,b,v)){v.readyState=1,i&&m.trigger("ajaxSend",[v,k]),k.async&&k.timeout>0&&(g=setTimeout(function(){v.abort("timeout")},k.timeout));try{t=1,c.send(r,x)}catch(w){if(!(2>t))throw w;x(-1,w)}}else x(-1,"No Transport");function x(a,b,f,h){var j,r,s,u,w,x=b;2!==t&&(t=2,g&&clearTimeout(g),c=void 0,e=h||"",v.readyState=a>0?4:0,j=a>=200&&300>a||304===a,f&&(u=tb(k,v,f)),u=ub(k,u,v,j),j?(k.ifModified&&(w=v.getResponseHeader("Last-Modified"),w&&(n.lastModified[d]=w),w=v.getResponseHeader("etag"),w&&(n.etag[d]=w)),204===a||"HEAD"===k.type?x="nocontent":304===a?x="notmodified":(x=u.state,r=u.data,s=u.error,j=!s)):(s=x,(a||!x)&&(x="error",0>a&&(a=0))),v.status=a,v.statusText=(b||x)+"",j?o.resolveWith(l,[r,x,v]):o.rejectWith(l,[v,x,s]),v.statusCode(q),q=void 0,i&&m.trigger(j?"ajaxSuccess":"ajaxError",[v,k,j?r:s]),p.fireWith(l,[v,x]),i&&(m.trigger("ajaxComplete",[v,k]),--n.active||n.event.trigger("ajaxStop")))}return v},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax({url:a,type:b,dataType:e,data:c,success:d})}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){var b;return n.isFunction(a)?this.each(function(b){n(this).wrapAll(a.call(this,b))}):(this[0]&&(b=n(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this)},wrapInner:function(a){return this.each(n.isFunction(a)?function(b){n(this).wrapInner(a.call(this,b))}:function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}}),n.expr.filters.hidden=function(a){return a.offsetWidth<=0&&a.offsetHeight<=0},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var vb=/%20/g,wb=/\[\]$/,xb=/\r?\n/g,yb=/^(?:submit|button|image|reset|file)$/i,zb=/^(?:input|select|textarea|keygen)/i;function Ab(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||wb.test(a)?d(a,e):Ab(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)Ab(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)Ab(c,a[c],b,e);return d.join("&").replace(vb,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&zb.test(this.nodeName)&&!yb.test(a)&&(this.checked||!T.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(xb,"\r\n")}}):{name:b.name,value:c.replace(xb,"\r\n")}}).get()}}),n.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(a){}};var Bb=0,Cb={},Db={0:200,1223:204},Eb=n.ajaxSettings.xhr();a.attachEvent&&a.attachEvent("onunload",function(){for(var a in Cb)Cb[a]()}),k.cors=!!Eb&&"withCredentials"in Eb,k.ajax=Eb=!!Eb,n.ajaxTransport(function(a){var b;return k.cors||Eb&&!a.crossDomain?{send:function(c,d){var e,f=a.xhr(),g=++Bb;if(f.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(e in a.xhrFields)f[e]=a.xhrFields[e];a.mimeType&&f.overrideMimeType&&f.overrideMimeType(a.mimeType),a.crossDomain||c["X-Requested-With"]||(c["X-Requested-With"]="XMLHttpRequest");for(e in c)f.setRequestHeader(e,c[e]);b=function(a){return function(){b&&(delete Cb[g],b=f.onload=f.onerror=null,"abort"===a?f.abort():"error"===a?d(f.status,f.statusText):d(Db[f.status]||f.status,f.statusText,"string"==typeof f.responseText?{text:f.responseText}:void 0,f.getAllResponseHeaders()))}},f.onload=b(),f.onerror=b("error"),b=Cb[g]=b("abort");try{f.send(a.hasContent&&a.data||null)}catch(h){if(b)throw h}},abort:function(){b&&b()}}:void 0}),n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(d,e){b=n("<script>").prop({async:!0,charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&e("error"===a.type?404:200,a.type)}),l.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Fb=[],Gb=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Fb.pop()||n.expando+"_"+cb++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Gb.test(b.url)?"url":"string"==typeof b.data&&!(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Gb.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Gb,"$1"+e):b.jsonp!==!1&&(b.url+=(db.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Fb.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||l;var d=v.exec(a),e=!c&&[];return d?[b.createElement(d[1])]:(d=n.buildFragment([a],b,e),e&&e.length&&n(e).remove(),n.merge([],d.childNodes))};var Hb=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&Hb)return Hb.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>=0&&(d=n.trim(a.slice(h)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e,dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).complete(c&&function(a,b){g.each(c,f||[a.responseText,b,a])}),this},n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};var Ib=a.document.documentElement;function Jb(a){return n.isWindow(a)?a:9===a.nodeType&&a.defaultView}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d=this[0],e={top:0,left:0},f=d&&d.ownerDocument;if(f)return b=f.documentElement,n.contains(b,d)?(typeof d.getBoundingClientRect!==U&&(e=d.getBoundingClientRect()),c=Jb(f),{top:e.top+c.pageYOffset-b.clientTop,left:e.left+c.pageXOffset-b.clientLeft}):e},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===n.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(d=a.offset()),d.top+=n.css(a[0],"borderTopWidth",!0),d.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-d.top-n.css(c,"marginTop",!0),left:b.left-d.left-n.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||Ib;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Ib})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(b,c){var d="pageYOffset"===c;n.fn[b]=function(e){return J(this,function(b,e,f){var g=Jb(b);return void 0===f?g?g[c]:b[e]:void(g?g.scrollTo(d?a.pageXOffset:f,d?f:a.pageYOffset):b[e]=f)},b,e,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=ya(k.pixelPosition,function(a,c){return c?(c=xa(a,b),va.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return J(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var Kb=a.jQuery,Lb=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=Lb),b&&a.jQuery===n&&(a.jQuery=Kb),n},typeof b===U&&(a.jQuery=a.$=n),n});
$.extend({
include: function(context,file) {
var files = typeof file == "string" ? [file]:file;
for (var i = 0; i < files.length; i++) {
var name = files[i].replace(/^\s|\s$/g, "");
var att = name.split('.');
var ext = att[att.length - 1].toLowerCase();
var isCSS = ext == "css";
var tag = isCSS ? "link" : "script";
var attr = isCSS ? " type='text/css' rel='stylesheet' " : " language='javascript' type='text/javascript' ";
var link = (isCSS ? "href" : "src") + "='" + context + name + "'";
if ($(tag + "[" + link + "]").length == 0) document.write("<" + tag + attr + link + "></" + tag + ">");
}
}
});
\ No newline at end of file
;(function($) {
$.extend({
table: {// 表格封装处理
id: 'list-table',
_option: {},
_params: {},
bindevent: function(opts) {
$('.btn-more').click(function() {$("i", this).toggleClass("fa-angle-down fa-angle-up");$('#list-form-more').slideToggle('fast');});
$('#search-form').find(".btn-close").click(function() {$('.btn-more').click();});
$('#search-form').find(".btn-search").click(function() {$.table.search();});
$('#search-form').find(".btn-reset").click(function() {$.form.reset();});
$(document).click(function(event) {
if ($(event.target).closest(".btn-more").length == 0 && $(event.target).closest("#list-form-more").length==0) {
if ($('#list-form-more').is(":visible")) {
$(".btn-more i", this).toggleClass("fa-angle-down fa-angle-up");
$('#list-form-more').hide('fast');
}
}
});
$(".list-bar").find("button[data-method],input[data-method]").each(function() {
var u = ctx + $(this).attr("data-url");
switch ($(this).attr("data-method")) {
case 'add':
opts.createUrl = u;
break;
case 'edit':
opts.updateUrl = u;
break;
case 'removeAll':
opts.removeUrl = u;
break;
case 'exportExcel':
opts.exportUrl = u;
break;
}
$(this).click(function() {eval("$.operate." + $(this).attr("data-method") + "()");});
});
},
setTabelid:function(tableid){//重新设置tableid,一个表单多个表格的时候需要
$.table.id = tableid;
},
parse: function(tableid, opts) {
$.table.id = tableid;
var $table = $("#" + tableid);
if (undefined == opts) {opts = {};}
$.table.bindevent(opts);
var cols = [],config;
$($table.find("thead th")).each(function() {
try {
config = eval("(" + $(this).attr("config") + ")");
} catch (err) {
alert("数据表格解析错误,请检查表格 " + $(this).text() + " 列属性是否正确.");
return false;
}
if (undefined == config.field) {} else if ("_NUMBER" == config.field) { //序号列
config.align = "center";
config.width = "50";
config.formatter = function(v, r, i) {
return $.table.serialNumber(i);
}
}
cols.push(config);
});
var _ish = (eval("(" + $table.attr("data-config") + ")").height == undefined);
if (_ish) {opts.height = ($(window).height() - 30);}
$.extend(true, opts, eval("(" + $table.attr("data-config") + ")"));
opts.columns = cols;
$.table.init(opts);
$(".bs-bars").css("width", "100%");
if (_ish) {$(window).resize(function() {$("#" + tableid).bootstrapTable('resetView', {height: $(window).height() - 30});});}
},
// 初始化表格参数
init: function(options) {
$.table._option = options;
$.table._params = $.util.isEmpty(options.queryParams) ? $.table.queryParams : options.queryParams;
_sortOrder = $.util.isEmpty(options.sortOrder) ? "asc" : options.sortOrder;
_sortName = $.util.isEmpty(options.sortName) ? "" : options.sortName;
_uniqueId = $.util.isEmpty(options.uniqueId) ? "" : options.uniqueId;
_striped = $.util.isEmpty(options.striped) ? false : options.striped;
_escape = $.util.isEmpty(options.escape) ? false : options.escape;
_height = $.util.isEmpty(options.height) ? "" : options.height;
_initPageSize = $.util.isEmpty(options.pageSize) ? 15 : options.pageSize;
if (options.url != null) {
options.url = (options.url.indexOf(ctx) != 0) ? ctx + options.url : options.url;
}
$("#" + $.table.id).bootstrapTable({
search: false, //$.util.visible(options.search), // 是否显示搜索框功能
showSearch: false, //$.util.visible(options.showSearch), // 是否显示检索信息
showRefresh: false, //$.util.visible(options.showRefresh), // 是否显示刷新按钮
showColumns: false, //$.util.visible(options.showColumns), // 是否显示隐藏某列下拉框
showToggle: false, //$.util.visible(options.showToggle), // 是否显示详细视图和列表视图的切换按钮
showExport: false, //$.util.visible(options.showExport), // 是否支持导出文件
height: _height,
url: options.url, // 请求后台的URL(*)
contentType: "application/x-www-form-urlencoded", // 编码类型
method: 'post', // 请求方式(*)
cache: false, // 是否使用缓存
striped: _striped, // 是否显示行间隔色
sortable: true, // 是否启用排序
sortStable: true, // 设置为 true 将获得稳定的排序
sortName: _sortName, // 排序列名称
sortOrder: _sortOrder, // 排序方式 asc 或者 desc
pagination: $.util.visible(options.pagination), // 是否显示分页(*)
pageNumber: 1, // 初始化加载第一页,默认第一页
pageSize: _initPageSize, // 每页的记录行数(*)
pageList: [15, 25, 50], // 可供选择的每页的行数(*)
escape: _escape, // 转义HTML字符串
iconSize: 'outline', // 图标大小:undefined默认的按钮尺寸 xs超小按钮sm小按钮lg大按钮
toolbar: '#toolbar', // 指定工作栏
sidePagination: "server", // 启用服务端分页
queryParams: $.table._params, // 传递参数(*)
columns: options.columns, // 显示列信息(*)
responseHandler: $.table.responseHandler, // 回调函数
uniqueId: _uniqueId,
useRowAttrFunc: true,
//当选中行,拖拽时的哪行数据,并且可以获取这行数据的上一行数据和下一行数据
onReorderRowsDrag: function(table, row) {onReorderRowsDrag(table, row);},
//拖拽完成后的这条数据,并且可以获取这行数据的上一行数据和下一行数据
onReorderRowsDrop: function(table, row) {onReorderRowsDrop(table, row);},
//当拖拽结束后,整个表格的数据
onReorderRow: function(newData) {onReorderRow(newData);},
onClickRow: options.onClickRow
});
},
// 查询条件
queryParams: function(params) {
$.each($("#search-form").serializeArray(), function(i, field) {params[field.name] = field.value;});
params.pageSize = params.limit;
params.pageNum = params.offset / params.limit + 1;
params.searchValue = params.search;
params.orderByColumn = params.sort;
params.isAsc = params.order;
return params;
},
// 请求获取数据后处理回调函数
responseHandler: function(res) {
if (res.code == 0) {
return {rows: res.rows,total: res.total};
} else {
$.win.alertWarning(res.msg);
return {rows: [],total: 0};
}
},
// 序列号生成
serialNumber: function(index) {
var table = $("#" + $.table.id).bootstrapTable('getOptions');
var pageSize = table.pageSize;
var pageNumber = table.pageNumber;
return pageSize * (pageNumber - 1) + index + 1;
},
// 搜索-默认第一个form
search: function(formId) {
var currentId = $.util.isEmpty(formId) ? $('form').attr('id') : formId;
var params = $("#" + $.table.id).bootstrapTable('getOptions');
params.queryParams = function(params) {
var search = {};
$.each($("#" + currentId).serializeArray(), function(i, field) {
search[field.name] = field.value;
});
search.pageSize = params.limit;
search.pageNum = params.offset / params.limit + 1;
search.searchValue = params.search;
search.orderByColumn = params.sort;
search.isAsc = params.order;
return search;
}
$("#" + $.table.id).bootstrapTable('refresh', params);
},
// 刷新表格
refresh: function() {
try {
$("#" + $.table.id).bootstrapTable('refresh', {silent: true});
} catch (e) {
console.log(e);
//关闭当前窗口
//window.opener.location.href = window.opener.location.href;
//window.close();
}
},
// 查询表格指定列值
selectColumns: function(column) {return $.map($("#" + $.table.id).bootstrapTable('getSelections'), function(row) {return row[column];});},
// 查询表格首列值
selectFirstColumns: function() {return $.map($("#" + $.table.id).bootstrapTable('getSelections'), function(row) {return row[$.table._option.columns[1].field];});},
// 回显数据字典
dict: function(datas, value) {
var actions = [];
$.each(datas, function(index, dict) {
if (dict.dictValue == value) {
actions.push(($.util.isEmpty(dict.listClass) ? "<span>" : "<span class='badge badge-" + dict.listClass +
"'>") + dict.dictLabel + "</span>");
return false;
}
});
return actions.join('');
},
// 显示表格指定列
showColumn: function(column) {$("#" + $.table.id).bootstrapTable('showColumn', column);},
// 隐藏表格指定列
hideColumn: function(column) {$("#" + $.table.id).bootstrapTable('hideColumn', column);}
},
form: {// 表单封装处理
init: function(formid, saveBtn) {
if (undefined == formid || "" == formid) {
alert("表单form ID值不能为空,请给表单的form添加ID,默认为 form1");
return false;
}
var $form = $('#' + formid);
$(".collapse-link").click(function() {
var fbody = $(this).parents("fieldset").find(".form-fieldset-body");
$("i", this).toggleClass("fa-chevron-down fa-chevron-up");
fbody.slideToggle(function() {
if (fbody.is(":hidden")) {
fbody.after(
"<div class='text-center'><a class='btna btna-default' href='javascript:;' onclick='$(this).parents(\"fieldset\").find(\".collapse-link\").click();'>点击查看隐藏信息</a></div>"
);
} else {
fbody.next().remove();
}
});
});
var _rules = {},
_messages = {};
var isTableForm = $(".form-table").size() > 0;
$form.find("input[data-rule],select[data-rule],textarea[data-rule]").each(function() {
var s = isTableForm ? $(this).parents("td.tr").prev() : $(this).parents("div.control-content").prev();
s.html("<span>*</span>" + s.text());
var msgs = eval("(" + $(this).attr("data-messages") + ")");
_rules[$(this).attr("name")] = eval("(" + $(this).attr("data-rule") + ")");
if (undefined != msgs) {
_messages[$(this).attr("name")] = msgs;
}
});
//console.log(isTableForm+"-----------------------"+JSON.stringify(_rules));
$("#" + formid).validate({
rules: _rules,
messages: _messages
});
if ($.fn.select2 !== undefined) {
$("select.form-control:not(.noselect2)").each(function() {
$(this).select2().on("change", function() {
//$(this).valid();
});
});
}
$.form.readbox();
if (saveBtn) {
$("#" + saveBtn).click(function() {
var url = $form.attr("data-action");
if (url == undefined || "" == url) {
alert("提交地址错误 ,请检查form表单的data-action.");
} else {
if ($("#" + formid).validate().form()) {
$.win.loading("正在处理中,请稍后...");
var config = {
url: ctx + url,
type: "post",
dataType: "json",
data: $form.serialize(),
success: function(result) {
$.win.opener().$.win.msg('保存成功');
$.win.close("table");
}
};
$.ajax(config)
}
}
});
}
},
save: function(url, data, handler) {
$.win.loading("数据保存中,请稍后...");
var config = {
type: "post",
dataType: "json",
url: url,
data: data,
success: function(result) {
if ($.isFunction(handler)) {
$.win.closeLoading();
handler(result);
} else {
if (result.code == web_status.SUCCESS) {
try {
$.win.opener().$.win.msg('保存成功');
$.win.close("table");
} catch (e) {}
} else {
$.win.alertError(result.msg);
}
$.win.closeLoading();
}
}
};
$.ajax(config)
},
reset: function(formId) {
var currentId = $.util.isEmpty(formId) ? $('form').attr('id') : formId;
$("#" + currentId)[0].reset();
},
selectCheckeds: function(name) { // 获取选中复选框项
var checkeds = "";
$('input:checkbox[name="' + name + '"]:checked').each(function(i) {
if (0 == i) {
checkeds = $(this).val();
} else {
checkeds += ("," + $(this).val());
}
});
return checkeds;
},
readbox: function() {
if ($(".check-box").length > 0) {
$(".check-box").iCheck({
checkboxClass: 'icheckbox-blue',
radioClass: 'iradio-blue'
})
}
if ($(".radio-box").length > 0) {
$(".radio-box").iCheck({
checkboxClass: 'icheckbox-blue',
radioClass: 'iradio-blue'
})
}
},
selectSelects: function(name) { // 获取选中下拉框项
var selects = "";
$('#' + name + ' option:selected').each(function(i) {
if (0 == i) {
selects = $(this).val();
} else {
selects += ("," + $(this).val());
}
});
return selects;
}
},
win: { // 弹出层封装处理
icon: function(type) { // 显示图标
var icon = "";
if (type == modal_status.WARNING) {
icon = 0;
} else if (type == modal_status.SUCCESS) {
icon = 1;
} else if (type == modal_status.FAIL) {
icon = 2;
} else {
icon = 3;
}
return icon;
},
msg: function(content) {
layer.msg(content, {
time: 2000,
offset: '50px'
});
},
// 消息提示并刷新父窗体
msgReload: function(msg, type) {
layer.msg(msg, {
icon: $.win.icon(type),
time: 500,
shade: [0.1, '#8F8F8F']
},
function() {
$.win.reload();
});
},
toast: function(content, type) {
toastr.option = {
closeButton: true,
debug: false,
progressBar: true,
showEasing: "swing",
hideEasing: "linear",
showMethod: "fadeIn",
hideMethod: "fadeOut",
onclick: null,
positionClass: "toast-bottom-center",
showDuration: "300",
hideDuration: "100",
timeOut: "200",
extendedTimeOut: "100"
}
//toastr["info"]("你有新消息了!","消息提示");
if (type == 1) {
toastr.error(content, '系统错误');
} else if (type == 2) {
toastr.warning(content, '系统警告');
} else if (type == 3) {
toastr.info(content, '系统系统信');
} else {
toastr.success(content, '操作成功');
}
},
toastRefresh: function(content) {
$.win.toast(content);
$.win.opener().$.table.refresh();
},
// 弹出提示
alert: function(content, type) {
top.layer.alert(content + "", {
icon: $.win.icon(type),
title: "系统提示",
btn: ['确认'],
btnclass: ['btn btn-primary']
});
},
alertCallBack: function(content, type, callBack) {
return top.layer.alert(content + "", {
icon: $.win.icon(type),
title: "系统提示",
btn: ['确认'],
btnclass: ['btn btn-primary']
}, callBack);
},
// 错误提示
alertError: function(content) {
$.win.alert(content, modal_status.FAIL);
},
// 成功提示
alertSuccess: function(content) {
$.win.alert(content, modal_status.SUCCESS);
},
// 警告提示
alertWarning: function(content) {
$.win.alert(content, modal_status.WARNING);
},
alertCollBackWarning: function(content, callBack) {
return $.win.alertCallBack(content, modal_status.WARNING, callBack);
},
confirm: function(content, callBack, cancelBack) {
top.layer.confirm(content, {
icon: 3,
title: "系统提示",
btn: ['确认', '取消'],
btnclass: ['btn btn-primary', 'btn btn-danger']
}, function(index) {
top.layer.close(index);
callBack(true);
}, function(index) {
top.layer.close(index);
if ($.isFunction(cancelBack)) {
cancelBack(true);
}
});
},
/**
* refresh:是否刷新父母页面
* - 空或不填写为不刷新
* - parent:父页面刷新
* - table:父母页面列表刷新
*/
close: function(refresh, msg) { // 关闭窗体
var index = parent.layer.getFrameIndex(window.name);
if (undefined == index) {
window.close();
}
try {
if ("table" == refresh) {
if ($.util.isNotEmpty(msg)) {
$.win.opener().$.win.msg(msg);
}
$.win.opener().$.table.refresh();
} else if ("parent" == refresh) {
$.win.opener().location.reload();
}
parent.layer.close(index);
} catch (e) {}
},
opener: function() { //如果是layer弹出窗口,弹出窗口获取父页面
//再此临时解决首页待办提交流程 js 报错的问题
try {
if(frameElement != null){
var api = frameElement.api || {};
var config = api.config;
return config.opener;
}else{
return window.opener;
}
} catch (e) {
window.opener.location.reload();
//window.opener.location.href = window.opener.location.href;
//window.close();
}
},
/**
* 打开开一个窗口
* @url 窗口地址
* @title 标题
* @size 窗口大小(格式1:数组宽、高['200px','100%'],格式2:如果为true,为最大弹出层,如宽或高任意有个100%,或者true,都为弹出个新页面)
* @noBtn 是否有窗口自带按钮
* @clsHandler 窗口关闭事件回调事件
*/
open: function(url, title, size, btn,clsHandler) {
size = $.win._size(size);
if ($.util.isEmpty(title)) {title = false};
if ($.util.isEmpty(url)) {url = ctx + "404.html"};
var opts = {
area:size,title:title,content:url,
type:2,resize:true,maxmin:false,shadeClose: false,opener: window,scrollbar: true,
end: function() {
if ($.isFunction(clsHandler)) {
clsHandler();//location.reload();
}
}
};
if (btn) {
opts.btn = ['确定', '关闭'],
opts.yes = function(index, layero) {
var iframeWin = layero.find('iframe')[0];
iframeWin.contentWindow.submitHandler();
}
opts.cancel = function(index) {
return true;
}
}
var index = top.layer.open(opts);
if (size == true) {
top.layer.full(index);
}
},
openForm:function(url,winName){
/*var a = $("<a href='"+url+"' target='_blank'>555</a>").get(0);
var e = document.createEvent('MouseEvents');
e.initEvent( 'click', true, true );
a.dispatchEvent(e);*/
if(!winName){winName='newWindow';}
var param = 'width='+(window.screen.availWidth-20)+',height='+(window.screen.availHeight-60)+ ',top=5,left=5,resizable=yes,status=yes,menubar=no,scrollbars=yes';
// window.open(url,'_blank',param);
window.open(url);
},
openContent: function(content, size, title, btns, handler) {
if (undefined == title) {
title = false;
}
var opts = {
type: 1,
area: size,
maxmin: false,
title: title,
shadeClose: false,
closeBtn: 0,
scrollbar: false,
content: content
};
if ($.isFunction(handler)) {
opts.yes = handler;
if (btns != undefined && "" != btns) {
opts.btn = btns;
} else {
opts.btn = ['确定', '取消'];
}
}
layer.open(opts);
},
openHTML: function(content, size, title) {
if (undefined == title) {
title = false;
}
var opts = {
type: 1,maxmin: false,
area: size,title: title,
shadeClose: true,closeBtn: 0,scrollbar: false,
content: content
};
return layer.open(opts);
},
// 打开遮罩层
loading: function(message) {
$.blockUI({
message: '<div class="loaderbox"><div class="loading-activity"></div> ' + message + '</div>'
});
},
// 关闭遮罩层
closeLoading: function() {
setTimeout(function() {
$.unblockUI()
}, 50);
},
// 重新加载
reload: function() {
parent.location.reload();
},
_size: function(size) {
if (size == undefined || ''==size) {
size = ['85%', '85%'];
}else{
if(size==true){
size = ['100%', '100%'];
}else{
if ($.util.isEmpty(size[0])) {size[0] = "85%"};
if ($.util.isEmpty(size[1])) {size[1] = "85%"}
}
}
if (navigator.userAgent.match(/(iPhone|iPod|Android|ios )/i)) {size = ['auto', 'auto']}; //如果是移动端,就使用自适应大小弹窗
return size;
}
},
operate: {// 操作封装处理
exportExcel: function(formId) { // 下载-默认第一个form
var currentId = $.util.isEmpty(formId) ? $('form').attr('id') : formId;
$.win.loading("正在导出数据,请稍后...");
$.post($.table._option.exportUrl, $("#" + currentId).serializeArray(), function(result) {
if (result.code == web_status.SUCCESS) {
window.location.href = "/util/download?fileName=" + result.msg + "&delete=" + true;
} else {
$.win.alertError(result.msg);
}
$.win.closeLoading();
});
},
submit: function(url, type, dataType, data) { // 提交数据
$.win.loading("正在处理中,请稍后...");
url = (url.indexOf(ctx) < 0) ? ctx + url : url;
var config = {
url: url,
type: type,
dataType: dataType,
data: data,
success: function(result) {
$.operate.ajaxSuccess(result);
}
};
$.ajax(config);
},
post: function(url, data) { // post请求传输
$.operate.submit(url, "post", "json", data);
},
get: function(url, handler) { // get请求传输
if ($.isFunction(handler)) {
$.get(url, handler);
} else {
$.operate.submit(url, "get", "json", "");
}
},
// 删除信息
remove: function(id) {
$.win.confirm("确定删除该条" + $.table._option.modalName + "信息吗?", function() {
var url = $.util.isEmpty(id) ? $.table._option.removeUrl : $.table._option.removeUrl.replace("{id}", id);
$.operate.submit(url, "post", "json", {
"id": id
});
});
},
// 批量删除信息
removeAll: function() {
var rows = $.util.isEmpty($.table._option.uniqueId) ? $.table.selectFirstColumns() : $.table.selectColumns($.table
._option.uniqueId);
if (rows.length == 0) {
$.win.alertWarning("请至少选择一条记录");
return;
}
$.win.confirm("确认要删除选中的" + rows.length + "条数据吗?", function() {
var url = ($.table._option.removeUrl.indexOf(ctx) < 0) ? ctx += $.table._option.removeUrl : $.table._option.removeUrl;
var data = {
"ids": rows.join()
};
$.operate.submit(url, "post", "json", data);
});
},
// 清空信息
clean: function() {
$.win.confirm("确定清空所有" + $.table._option.modalName + "吗?", function() {
var url = $.table._option.cleanUrl;
$.operate.submit(url, "post", "json", "");
});
},
// 添加信息
add: function(id) {
var url = $.util.isEmpty(id) ? $.table._option.createUrl : $.table._option.createUrl.replace("{id}", id);
$.win.open(url, "添加" + $.table._option.modalName, $.table._option.modalSize);
},
// 编辑信息
edit: function(id) {
var url = "/404.html";
if ($.table._option.updateUrl == undefined || "" == $.table._option.updateUrl) {
alert("信息编辑服务地址错误:" + $.table._option.updateUrl + ",请配置信息编辑服务地址.");
return false;
}
if ($.util.isNotEmpty(id)) {
url = $.table._option.updateUrl.replace("{id}", id);
} else {
var id = $.util.isEmpty($.table._option.uniqueId) ? $.table.selectFirstColumns() : $.table.selectColumns($.table
._option.uniqueId);
if (id.length == 0) {
$.win.alertWarning("请至少选择一条记录");
return;
} else if (id.length > 1) {
$.win.alertWarning("请选择一条记录,进行编辑.");
return;
}
url = $.table._option.updateUrl.replace("{id}", id);
}
$.win.open(url, "编辑" + $.table._option.modalName, $.table._option.modalSize);
},
// 工具栏表格树编辑
editTree: function() {
var row = $('#bootstrap-tree-table').bootstrapTreeTable('getSelections')[0];
if ($.util.isEmpty(row)) {
$.win.alertWarning("请至少选择一条记录");
return;
}
var url = $.table._option.updateUrl.replace("{id}", row[$.table._option.uniqueId]);
$.win.open("编辑" + $.table._option.modalName, url);
},
// 保存信息
save: function(url, data, handler) {
$.win.loading("正在处理中,请稍后...");
var config = {
url: url,
type: "post",
dataType: "json",
data: data,
success: function(result) {
if ($.isFunction(handler)) {
$.win.closeLoading();
handler(result);
} else {
if (result.code == web_status.SUCCESS) {
$.win.opener().$.win.msg('保存成功');
$.win.close("table");
} else {
$.win.alertError(result.msg);
}
$.win.closeLoading();
}
}
};
$.ajax(config)
},
// 保存结果弹出msg刷新table表格
ajaxSuccess: function(result) {
if (result.code == web_status.SUCCESS) {
$.win.msg(result.msg);
$.table.refresh();
} else {
$.win.alertError(result.msg);
}
$.win.closeLoading();
},
// 成功结果提示msg(父窗体全局更新)
saveSuccess: function(result) {
if (result.code == web_status.SUCCESS) {
$.win.msgReload("保存成功,正在刷新数据请稍后……", modal_status.SUCCESS);
} else {
$.win.alertError(result.msg);
}
$.win.closeLoading();
},
// 成功回调执行事件(父窗体静默更新)
successCallback: function(result) {
if (result.code == web_status.SUCCESS) {
if (window.parent.$("#bootstrap-table").length > 0) {
$.win.close();
window.parent.$.win.msg(result.msg);
window.parent.$.table.refresh();
} else if (window.parent.$("#bootstrap-tree-table").length > 0) {
$.win.close();
window.parent.$.win.msg(result.msg);
window.parent.$.treeTable.refresh();
} else {
$.win.msgReload("保存成功,正在刷新数据请稍后……", modal_status.SUCCESS);
}
} else {
$.win.alertError(result.msg);
}
$.win.closeLoading();
}
},
validate: {// 校验封装处理
// 判断返回标识是否唯一 false 不存在 true 存在
unique: function(value) {if (value == "0") {return true;}return false;},
// 表单验证
form: function(formId) {
var currentId = $.util.isEmpty(formId) ? $('form').attr('id') : formId;
return $("#" + currentId).validate().form();
}
},
tree: {// 树插件封装处理
_option: {},
_lastValue: {},
// 初始化树结构
init: function(options) {
$.tree._option = options;
// 属性ID
var _id = $.util.isEmpty(options.id) ? "tree" : options.id;
// 展开等级节点
var _expandLevel = $.util.isEmpty(options.expandLevel) ? 0 : options.expandLevel;
// 树结构初始化加载
var setting = {
check: options.check,
view: {
selectedMulti: false,
nameIsHTML: true
},
data: {
key: {
title: "title"
},
simpleData: {
enable: true
}
},
callback: {
onClick: options.onClick
}
};
$.get(options.url, function(data) {
var treeName = $("#treeName").val();
var treeId = $("#treeId").val();
tree = $.fn.zTree.init($("#" + _id), setting, data);
$._tree = tree;
// 展开第一级节点
var nodes = tree.getNodesByParam("level", 0);
for (var i = 0; i < nodes.length; i++) {
if (_expandLevel > 0) {
tree.expandNode(nodes[i], true, false, false);
}
$.tree.selectByIdName(treeId, treeName, nodes[i]);
}
// 展开第二级节点
nodes = tree.getNodesByParam("level", 1);
for (var i = 0; i < nodes.length; i++) {
if (_expandLevel > 1) {
tree.expandNode(nodes[i], true, false, false);
}
$.tree.selectByIdName(treeId, treeName, nodes[i]);
}
// 展开第三级节点
nodes = tree.getNodesByParam("level", 2);
for (var i = 0; i < nodes.length; i++) {
if (_expandLevel > 2) {
tree.expandNode(nodes[i], true, false, false);
}
$.tree.selectByIdName(treeId, treeName, nodes[i]);
}
}, null, null, "正在加载,请稍后...");
},
// 搜索节点
searchNode: function() {
// 取得输入的关键字的值
var value = $.util.trim($("#keyword").val());
if ($.tree._lastValue === value) {
return;
}
// 保存最后一次搜索名称
$.tree._lastValue = value;
var nodes = $._tree.getNodes();
// 如果要查空字串,就退出不查了。
if (value == "") {
$.tree.showAllNode(nodes);
return;
}
$.tree.hideAllNode(nodes);
// 根据搜索值模糊匹配
$.tree.updateNodes($._tree.getNodesByParamFuzzy("name", value));
},
// 根据Id和Name选中指定节点
selectByIdName: function(treeId, treeName, node) {
if ($.util.isNotEmpty(treeName) && $.util.isNotEmpty(treeId)) {
if (treeId == node.id && treeName == node.name) {
$._tree.selectNode(node, true);
}
}
},
// 显示所有节点
showAllNode: function(nodes) {
nodes = $._tree.transformToArray(nodes);
for (var i = nodes.length - 1; i >= 0; i--) {
if (nodes[i].getParentNode() != null) {
$._tree.expandNode(nodes[i], true, false, false, false);
} else {
$._tree.expandNode(nodes[i], true, true, false, false);
}
$._tree.showNode(nodes[i]);
$.tree.showAllNode(nodes[i].children);
}
},
// 隐藏所有节点
hideAllNode: function(nodes) {
var tree = $.fn.zTree.getZTreeObj("tree");
var nodes = $._tree.transformToArray(nodes);
for (var i = nodes.length - 1; i >= 0; i--) {
$._tree.hideNode(nodes[i]);
}
},
// 显示所有父节点
showParent: function(treeNode) {
var parentNode;
while ((parentNode = treeNode.getParentNode()) != null) {
$._tree.showNode(parentNode);
$._tree.expandNode(parentNode, true, false, false);
treeNode = parentNode;
}
},
// 显示所有孩子节点
showChildren: function(treeNode) {
if (treeNode.isParent) {
for (var idx in treeNode.children) {
var node = treeNode.children[idx];
$._tree.showNode(node);
$.tree.showChildren(node);
}
}
},
// 更新节点状态
updateNodes: function(nodeList) {
$._tree.showNodes(nodeList);
for (var i = 0, l = nodeList.length; i < l; i++) {
var treeNode = nodeList[i];
$.tree.showChildren(treeNode);
$.tree.showParent(treeNode)
}
},
// 获取当前被勾选集合
getCheckedNodes: function(column) {
var _column = $.util.isEmpty(column) ? "id" : column;
var nodes = $._tree.getCheckedNodes(true);
return $.map(nodes, function(row) {
return row[_column];
}).join();
},
// 不允许根父节点选择
notAllowParents: function(_tree) {
var nodes = _tree.getSelectedNodes();
for (var i = 0; i < nodes.length; i++) {
if (nodes[i].level == 0) {
$.win.alertError("不能选择根节点(" + nodes[i].name + ")");
return false;
}
if (nodes[i].isParent) {
$.win.alertError("不能选择父节点(" + nodes[i].name + ")");
return false;
}
}
return true;
},
// 不允许最后层级节点选择
notAllowLastLevel: function(_tree) {
var nodes = _tree.getSelectedNodes();
for (var i = 0; i < nodes.length; i++) {
if (nodes[i].level == nodes.length + 1) {
$.win.alertError("不能选择最后层级节点(" + nodes[i].name + ")");
return false;
}
}
return true;
},
// 隐藏/显示搜索栏
toggleSearch: function() {
$('#search').slideToggle(200);
$('#btnShow').toggle();
$('#btnHide').toggle();
$('#keyword').focus();
},
// 折叠zTreeVue
collapse: function() {
$._tree.expandAll(false);
},
// 展开
expand: function() {
$._tree.expandAll(true);
},
dept: function(id, name, rootId, max, callback) {
if ($.util.isEmpty(rootId)) rootId = '';
if ($.util.isEmpty(max)) max = 0;
if ($.util.isEmpty(callback)) callback = '';
zTreeVue.init([], {
type: 'dept',
rootId: rootId,
max: max
}, callback, {
id: id,
name: name
}, true);
},
user: function(id, name, rootId, max, callback) {
if ($.util.isEmpty(rootId)) rootId = '';
if ($.util.isEmpty(max)) max = 0;
if ($.util.isEmpty(callback)) callback = '';
zTreeVue.init([], {
type: 'user',
rootId: rootId,
max: max
}, callback, {
id: id,
name: name
}, true);
}
},
file: {
get: function(id) {
$.get(_FILE_SERVICE + "/file/get/" + id);
},
getPath: function(id) {
return _FILE_SERVICE + "/file/get/" + id;
},
del: function(id, handler) {
if ($.util.isEmpty(id)) {
alert('id不能为空');
} else {
$.get(ctx + "/file/delete/" + id, function() {
handler();
});
}
},
/**
* 文件操作后回调函数,外层有<div class="file-container"></div>
* @param res 上传成功后回传的file对象
* @param type 回写的类型,image:图片,list:列表
*/
handler: function(type, res) {
if (type == "image") {
var div = $("<div class='thumbnail'></div>");
$("<button type='button' class='images-remove' title='删除文件' data-id='" + res.fileId +
"'><i class='glyphicon glyphicon-trash'></i></button>").bind('click', function() {
var that = $(this);
$.win.confirm("您确认删除吗?", function() {
$.file.del(that.attr("data-id"), function() {
that.parent().remove();
});
});
}).appendTo(div);
div.append("<img class='preview-image' src='" + _FILE_SERVICE + "/file/get/" + res.fileId + "'>");
$(".file-container").append(div);
} else if (type == "list") {
} else {
}
},
//图片列表
retPic: function(res) {
$.file.handler("image", res);
},
//列表回显
rList: function(res) {
$.file.handler("list", res);
}
},
util: {
//返回文件类型的fa 图标 名称
fileTypeIco: function(x) {
if ("doc,docx".indexOf(x) > -1) {
return "fa-file-word-o";
} else if ("jpg,JPG,bmp,png".indexOf(x) > -1) {
return "fa-file-image-o";
} else if ("xls,xlsx".indexOf(x) > -1) {
return "fa-file-excel-o";
} else if ("ppt,pptx".indexOf(x) > -1) {
return "fa-file-powerpoint-o";
} else if ("pdf".indexOf(x) > -1) {
return "fa-file-pdf-o";
} else {
return "fa-file-text-o";
}
},
/**
* 文件上传函数(默认handler可以不传入,调用页面要有附件回显容器id:file_contain)
* @param module 所属业务模块
* @param moduleId 所属业务模块表的id
* @param moduleType 上传文件标识
* @param handler 上传成功后的回调函数
*/
upload: function(module, moduleId, moduleType, handler) {
$.win.open(ctx + "common/file?module=" + module + "&moduleId=" + moduleId + "&returnHandler=" + handler + "&moduleType=" + moduleType, "附件上传", ['800px', '80%']);
},
/**
* 单个文件上传函数(默认handler可以不传入,调用页面要有附件回显容器 样式 .fileupload_btn)
* @param obj file 控件对象(必填)
* @param module 所属业务模块(必填)
* @param moduleId 所属业务模块表的id(必填)
* @param moduleType 所属业务模块表的标识
* @param companyId 所属业务模块表的id(必填)
* @param handler 上传成功后的回调函数(可选)
*/
uploadSign: function(obj, module, moduleId, moduleType, companyId, userId, handler) {
if ($.util.isEmpty(module)) {
alert("单个文件上传函数参数错误:module 必填");
return;
}
if ($.util.isEmpty(moduleId)) {
alert("请先保存或业务参数id输入错误.");
return;
}
if ($.util.isEmpty(companyId)) {
alert("单个文件上传函数参数错误:companyId 必填");
return;
}
var reader = new FileReader();
reader.onloadstart = function(e) {
console.log("开始读取....");
}
reader.onprogress = function(e) {
console.log("正在读取中....");
}
reader.onabort = function(e) {
console.log("中断读取....");
}
reader.onerror = function(e) {
console.log("读取异常....");
}
reader.onload = function(e) {
console.log("成功读取....");
$(".fileupload_btn").html("").append("<img src='" + this.result + "' >");
}
reader.readAsDataURL(obj.files[0]);
jQuery.ajaxFileUpload({
url: _FILE_SERVICE + "/file/upload", //用于文件上传的服务器端请求地址
secureuri: false, //是否需要安全协议,一般设置为false
fileElementId: ['fileupload'], //文件上传域的ID 在这里设置要上传的多个input的ID
data: {
'module': module,
'moduleId': moduleId,
'companyId': companyId,
'moduleType': moduleType,
'uploadType': 'single'
},
dataType: 'json', //返回值类型 一般设置为json
success: function(data, status) { //服务器成功响应处理函数
console.log(data);
if ($.isFunction(handler)) {
handler(data);
}
},
error: function(data, status, e) { //服务器响应失败处理函数
alert(e);
}
});
},
/**
* 单附件上传(跨域)
* @param obj 初始化操作对象 默认为:this 即可
* @param module 所属模块名称
* @param moduleId 所属模块数据ID
* @param moduleType 所属模块类型
* @param companyId 上传人所在公司ID
* @param userId 上传人用户ID
* @param handler 回调方法
* @param fileuploadId file控件ID
*/
uploadSignCross: function(obj, module, moduleId, moduleType, companyId, userId, handler) {
var explorer = $.util.getBrowser();
var browserType = explorer.browser + " " + explorer.version;
var token = $.md5('SinoSoft' + $.util.getNowFormatDate());
if ($.util.isEmpty(module)) {
alert("单个文件上传函数参数错误:module 必填");
return;
}
if ($.util.isEmpty(moduleId)) {
alert("请先保存或业务参数id输入错误.");
return;
}
if ($.util.isEmpty(companyId)) {
alert("单个文件上传函数参数错误:companyId 必填");
return;
}
var reader = new FileReader();
reader.onloadstart = function(e) {
console.log("开始读取....");
}
reader.onprogress = function(e) {
console.log("正在读取中....");
}
reader.onabort = function(e) {
console.log("中断读取....");
}
reader.onerror = function(e) {
console.log("读取异常....");
}
reader.onload = function(e) {
console.log("成功读取....");
$(".fileupload_btn").html("").append("<img src='" + this.result + "' >");
}
reader.readAsDataURL(obj.files[0]);
console.info('--------------------------------------');
jQuery.ajaxFileUpload({
url: ctx + "common/upload", //用于文件上传的服务器端请求地址
secureuri: false, //是否需要安全协议,一般设置为false
fileElementId: [obj.id], //文件上传域的ID 在这里设置要上传的多个input的ID
data: {
'module': module,
'moduleId': moduleId,
'companyId': companyId,
'moduleType': moduleType,
'uploadType': 'single',
'token': token,
'url': "/file/upload",
'browserType': browserType
},
dataType: 'json', //返回值类型 一般设置为json
success: function(data, status) { //服务器成功响应处理函数
console.log(data);
if ($.isFunction(handler)) {
handler(data);
}
},
error: function(data, status, e) { //服务器响应失败处理函数
alert(e);
}
});
},
/**
* 单附件上传(跨域)文件替换(标记原文件为历史版本并上传新文件)
* @param obj 初始化操作对象 默认为:this 即可
* @param fileId 文件Id
* @param module 所属模块名称
* @param moduleId 所属模块数据ID
* @param moduleType 所属模块类型
* @param companyId 上传人所在公司ID
* @param userId 上传人用户ID
* @param handler 回调方法
* @param fileuploadId file控件ID
*/
uploadSignReplaceHV: function(obj, fileId, module, moduleId, moduleType, companyId, userId, handler) {
var explorer = $.util.getBrowser();
var browserType = explorer.browser + " " + explorer.version;
var token = $.md5('SinoSoft' + $.util.getNowFormatDate());
if ($.util.isEmpty(fileId)) {
alert("单个文件上传函数参数错误:fileId 必填");
return;
}
if ($.util.isEmpty(module)) {
alert("单个文件上传函数参数错误:module 必填");
return;
}
if ($.util.isEmpty(moduleId)) {
alert("请先保存或业务参数id输入错误.");
return;
}
if ($.util.isEmpty(companyId)) {
alert("单个文件上传函数参数错误:companyId 必填");
return;
}
var reader = new FileReader();
reader.onloadstart = function(e) {
console.log("开始读取....");
}
reader.onprogress = function(e) {
console.log("正在读取中....");
}
reader.onabort = function(e) {
console.log("中断读取....");
}
reader.onerror = function(e) {
console.log("读取异常....");
}
reader.onload = function(e) {
console.log("成功读取....");
$(".fileupload_btn").html("").append("<img src='" + this.result + "' >");
}
reader.readAsDataURL(obj.files[0]);
console.info('--------------------------------------');
jQuery.ajaxFileUpload({
url: ctx + "file/upload/replace/"+fileId, //用于文件上传的服务器端请求地址
secureuri: false, //是否需要安全协议,一般设置为false
fileElementId: [obj.id], //文件上传域的ID 在这里设置要上传的多个input的ID
data: {
'module': module,
'moduleId': moduleId,
'companyId': companyId,
'moduleType': moduleType,
'uploadType': 'single',
'token': token,
'url': "/file/upload",
'browserType': browserType
},
dataType: 'json', //返回值类型 一般设置为json
success: function(data, status) { //服务器成功响应处理函数
console.log(data);
if ($.isFunction(handler)) {
handler(data);
}
},
error: function(data, status, e) { //服务器响应失败处理函数
alert(e);
}
});
},
/**
* 单个文件上传不覆盖函数(默认handler可以不传入,调用页面要有附件回显容器 样式 .fileupload_btn)
* @param obj file 控件对象(必填)
* @param module 所属业务模块(必填)
* @param moduleId 所属业务模块表的id(必填)
* @param moduleType 所属业务模块表的标识
* @param companyId 所属业务模块表的id(必填)
* @param handler 上传成功后的回调函数(可选)
*/
uploadMult: function(obj, module, moduleId, moduleType, companyId, userId, handler) {
if ($.util.isEmpty(module)) {
alert("单个文件上传函数参数错误:module 必填");
return;
}
if ($.util.isEmpty(moduleId)) {
alert("请先保存或业务参数id输入错误.");
return;
}
if ($.util.isEmpty(companyId)) {
alert("单个文件上传函数参数错误:companyId 必填");
return;
}
var reader = new FileReader();
reader.onloadstart = function(e) {
console.log("开始读取....");
}
reader.onprogress = function(e) {
console.log("正在读取中....");
}
reader.onabort = function(e) {
console.log("中断读取....");
}
reader.onerror = function(e) {
console.log("读取异常....");
}
reader.onload = function(e) {
console.log("成功读取....");
$(".fileupload_btn").html("").append("<img src='" + this.result + "' >");
}
reader.readAsDataURL(obj.files[0]);
jQuery.ajaxFileUpload({
url: ctx + "file/upload", //用于文件上传的服务器端请求地址
secureuri: false, //是否需要安全协议,一般设置为false
fileElementId: ['fileupload'], //文件上传域的ID 在这里设置要上传的多个input的ID
data: {
'module': module,
'moduleId': moduleId,
'companyId': companyId,
'moduleType': moduleType,
'uploadType': 'multiple'
},
dataType: 'json', //返回值类型 一般设置为json
success: function(data, status) { //服务器成功响应处理函数
if ($.isFunction(handler)) {
handler(data);
}
},
error: function(data, status, e) { //服务器响应失败处理函数
alert(e);
}
});
},
//多附件上传(跨域)
uploadMultCross: function(obj, module, moduleId, moduleType, companyId, userId, handler) {
var explorer = $.util.getBrowser();
var browserType = explorer.browser + " " + explorer.version;
var token = $.md5('SinoSoft' + $.util.getNowFormatDate());
if ($.util.isEmpty(module)) {
alert("单个文件上传函数参数错误:module 必填");
return;
}
if ($.util.isEmpty(moduleId)) {
alert("请先保存或业务参数id输入错误.");
return;
}
if ($.util.isEmpty(companyId)) {
alert("单个文件上传函数参数错误:companyId 必填");
return;
}
var reader = new FileReader();
reader.onloadstart = function(e) {
console.log("开始读取....");
}
reader.onprogress = function(e) {
console.log("正在读取中....");
}
reader.onabort = function(e) {
console.log("中断读取....");
}
reader.onerror = function(e) {
console.log("读取异常....");
}
reader.onload = function(e) {
console.log("成功读取....");
$(".fileupload_btn").html("").append("<img src='" + this.result + "' >");
}
reader.readAsDataURL(obj.files[0]);
jQuery.ajaxFileUpload({
url: ctx + "common/upload", //用于文件上传的服务器端请求地址
secureuri: false, //是否需要安全协议,一般设置为false
fileElementId: ['fileupload'], //文件上传域的ID 在这里设置要上传的多个input的ID
data: {
'module': module,
'moduleId': moduleId,
'companyId': companyId,
'moduleType': moduleType,
'uploadType': 'multiple',
'token': token,
'url': "/file/upload",
'browserType': browserType
},
dataType: 'json', //返回值类型 一般设置为json
success: function(data, status) { //服务器成功响应处理函数
if ($.isFunction(handler)) {
handler(data);
}
},
error: function(data, status, e) { //服务器响应失败处理函数
alert(e);
}
});
},
/**
* 公文关联
* @param id 业务ID
* @param type 查询的公文类型(多类型用||分隔) SW 收文 FW 发文 QB 签报 HYJY 会议纪要 YZSP 用章审批
* @param relationType 关联类型
* @param isMulti 单选多选类型:1单选 0多选
* @param callback 回调函数名称
*/
fileRelation: function(id, type, relationType, isMulti, callback) {
var opts = {
title: '公文关联',
btn: ['选 择', '取 消'],
area: ["70%", "85%"],
scrollbar: true,
opener: window,
type: 2,
content: ctx + "mvRelation/" + type + "?id=" + id + "&relationType=" + relationType + "&isMulti=" + isMulti,
yes: function(index, layero) {
var iw = layero.find('iframe')[0];
iw.contentWindow.saveRelation(callback);
}
};
console.log(top)
var index = top.layer.open(opts);
},
// 判断字符串是否为空
isEmpty: function(value) {if (value == undefined || value == null || this.trim(value) == "") {return true;}return false;},
// 判断一个字符串是否为非空串
isNotEmpty: function(value) {return !$.util.isEmpty(value);},
// 是否显示数据 为空默认为显示
visible: function(value) {if ($.util.isEmpty(value) || value == true) {return true;}return false;},
// 空格截取
trim: function(value) {if (value == null) {return "";}return value.toString().replace(/(^\s*)|(\s*$)|\r|\n/g, "");},
// 指定随机数返回
random: function(min, max) {return Math.floor((Math.random() * max) + min);},
startWith: function(value, start) {var reg = new RegExp("^" + start);return reg.test(value)},
endWith: function(value, end) {var reg = new RegExp(end + "$");return reg.test(value)},
nowDate: function(formatte) {
var date = new Date();
var seperator = "-";
var year = date.getFullYear();
var month = date.getMonth() + 1;
var strDate = date.getDate();
if (month >= 1 && month <= 9) {month = "0" + month;}
if (strDate >= 0 && strDate <= 9) {strDate = "0" + strDate;}
var currentdate = year + seperator + month + seperator + strDate + " " + date.getHours() + ":" + date.getMinutes();
if (formatte == undefined || "" == formatte) {formatte = "yyyy-MM-dd";}
return $.util.dateFtt(currentdate, formatte);
},
/**
* 对Date的扩展,将 Date 转化为指定格式的String
* 月(M)、日(d)、12小时(h)、24小时(H)、分(m)、秒(s)、周(E)、季度(q) 可以用 1-2 个占位符
* 年(y)可以用 1-4 个占位符,毫秒(S)只能用 1 个占位符(是 1-3 位的数字)
* eg:
* (new Date()).pattern("yyyy-MM-dd hh:mm:ss.S") ==> 2006-07-02 08:09:04.423
* (new Date()).pattern("yyyy-MM-dd E HH:mm:ss") ==> 2009-03-10 二 20:09:04
* (new Date()).pattern("yyyy-MM-dd EE hh:mm:ss") ==> 2009-03-10 周二 08:09:04
* (new Date()).pattern("yyyy-MM-dd EEE hh:mm:ss") ==> 2009-03-10 星期二 08:09:04
* (new Date()).pattern("yyyy-M-d h:m:s.S") ==> 2006-7-2 8:9:4.18
*/
dateFtt: function(date, fmt) {
if (date == null || date == "" || date == "null") {
return "-";
}
if(date!=undefined && date!=null && date.length >19){
date = date.substring(0,19);
}
date = date.replace(/-/g, "/");
var _d = new Date(date);
var o = {
"M+": _d.getMonth() + 1, //月份
"d+": _d.getDate(), //日
"h+": _d.getHours() % 12 == 0 ? 12 : _d.getHours() % 12, //小时
"H+": _d.getHours(), //小时
"m+": _d.getMinutes(), //分
"s+": _d.getSeconds(), //秒
"q+": Math.floor((_d.getMonth() + 3) / 3), //季度
"S": _d.getMilliseconds() //毫秒
};
var week = {"0": "日","1": "一","2": "二","3": "三","4": "四","5": "五","6": "六"};
if (/(y+)/.test(fmt)) {
fmt = fmt.replace(RegExp.$1, (_d.getFullYear() + "").substr(4 - RegExp.$1.length));
};
if (/(E+)/.test(fmt)) {
fmt = fmt.replace(RegExp.$1, ((RegExp.$1.length > 1) ? (RegExp.$1.length > 2 ? "星期" : "周") : "") + week[_d.getDay() +
""]);
}
for (var k in o) {
if (new RegExp("(" + k + ")").test(fmt)) {
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
}
}
return fmt;
},
uuid: function() {
return 'xxxFxxxaxAxxxxxyxx'.replace(/[xy]/g, function(c) {
var r = Math.random() * 16 | 0,v = c == 'x' ? r : (r & 0x3 | 0x8);
return v.toString(16)
});
},
getNowFormatDate: function() {
var date = new Date();
var seperator1 = "-";
var year = date.getFullYear();
var month = date.getMonth() + 1;
var strDate = date.getDate();
if (month >= 1 && month <= 9) {
month = "0" + month;
}
if (strDate >= 0 && strDate <= 9) {
strDate = "0" + strDate;
}
var currentdate = year + seperator1 + month + seperator1 + strDate;
return currentdate;
},
userInfo: function(userId, handler) {
$.win.loading("加载数据中,请稍后...");
var config = {
type: "post",
dataType: "json",
url: ctx + "system/user/profile/user/info",
data: {
id: userId
},
success: function(result) {
if ($.isFunction(handler)) {
$.win.closeLoading();
handler(result);
} else {
$.win.closeLoading();
}
}
};
$.ajax(config);
},
// 将表单序列化后转换为{"name1":"value1","name2":"value2"}
getFormObj: function(formId) {
var serializeArr = $("#" + formId).serializeArray();
if (serializeArr && serializeArr.length != 0) {
var obj = {};
for (i in serializeArr) {
var key, value;
var serializeObj = serializeArr[i];
key = serializeObj["name"];
value = serializeObj["value"];
if (!obj[key]) { //如果这个属性没有赋过值,就直接赋值
obj[key] = value;
} else {
obj[key] += "," + value
}
}
return obj;
} else {
return {};
}
},
getBrowser: function() { // 获取浏览器名
var rMsie = /(msie\s|trident\/7)([\w\.]+)/;
var rTrident = /(trident)\/([\w.]+)/;
var rEdge = /(chrome)\/([\w.]+)/; //IE
var rFirefox = /(firefox)\/([\w.]+)/; //火狐
var rOpera = /(opera).+version\/([\w.]+)/; //旧Opera
var rNewOpera = /(opr)\/(.+)/; //新Opera 基于谷歌
var rChrome = /(chrome)\/([\w.]+)/; //谷歌
var rUC = /(chrome)\/([\w.]+)/; //UC
var rMaxthon = /(chrome)\/([\w.]+)/; //遨游
var r2345 = /(chrome)\/([\w.]+)/; //2345
var rQQ = /(chrome)\/([\w.]+)/; //QQ
//var rMetasr = /(metasr)\/([\w.]+)/;//搜狗
var rSafari = /version\/([\w.]+).*(safari)/;
var ua = navigator.userAgent.toLowerCase();
var matchBS, matchBS2;
//IE 低版
matchBS = rMsie.exec(ua);
if (matchBS != null) {
matchBS2 = rTrident.exec(ua);
if (matchBS2 != null) {
switch (matchBS2[2]) {
case "4.0":
return {browser: "Microsoft IE",version: "8"};
break;
case "5.0":
return {browser: "Microsoft IE",version: "9"};
break;
case "6.0":
return {browser: "Microsoft IE",version: "10"};
break;
case "7.0":
return {browser: "Microsoft IE",version: "11"};
break;
default:
return {browser: "Microsoft IE",version: "Undefined"};
}
} else {
return {browser: "Microsoft IE",version: matchBS[2] || "0"};
}
}
//IE最新版
matchBS = rEdge.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {return {browser: "Microsoft Edge",version: "Chrome/" + matchBS[2] || "0"};}
//UC浏览器
matchBS = rUC.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {return {browser: "UC",version: "Chrome/" + matchBS[2] || "0"};}
//火狐浏览器
matchBS = rFirefox.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {return {browser: "火狐",version: "Firefox/" + matchBS[2] || "0"};}
//Oper浏览器
matchBS = rOpera.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {return {browser: "Opera",version: "Chrome/" + matchBS[2] || "0"};}
//遨游
matchBS = rMaxthon.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {return {browser: "遨游",version: "Chrome/" + matchBS[2] || "0"};}
//2345浏览器
matchBS = r2345.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {return {browser: "2345",version: "Chrome/ " + matchBS[2] || "0"};}
//QQ浏览器
matchBS = rQQ.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {return {browser: "QQ",version: "Chrome/" + matchBS[2] || "0"};}
//Safari(苹果)浏览器
matchBS = rSafari.exec(ua);
if ((matchBS != null) && (!(window.attachEvent)) && (!(window.chrome)) && (!(window.opera))) {return {browser: "Safari",version: "Safari/" + matchBS[1] || "0"};}
//谷歌浏览器
matchBS = rChrome.exec(ua);
if ((matchBS != null) && (!(window.attachEvent))) {
matchBS2 = rNewOpera.exec(ua);
if (matchBS2 == null) {
return {browser: "谷歌",version: "Chrome/" + matchBS[2] || "0"};
} else {
return {browser: "Opera",version: "opr/" + matchBS2[2] || "0"};
}
}
},
/**
* 切割长度
*/
splitStr: function (content, length) {
if($.util.isEmpty(content)){
return content;
}
if ($.util.isEmpty(length)) {
length = 30;
}
return (content.length > length ? content.substring(0, length) : content);
},
/**
* 隐藏部分页面内容
*/
hidePartHtml: function (content, width) {
if($.util.isEmpty(content)){
return content;
}
content = "<div style='overflow:hidden;width:"+width+"'>"+content+"</div>...";
return content;
}
}
});
})(jQuery);
/** 消息状态码 */
web_status = {SUCCESS: 0,FAIL: 500};
/** 弹窗状态码 */
modal_status = {SUCCESS: "success",FAIL: "error",WARNING: "warning"};
/*! layer弹层组件拓展类 */
;!function(){layer.use("skin/layer.ext.css",function(){layer.layui_layer_extendlayerextjs=!0});var a=layer.cache||{},b=function(b){return a.skin?" "+a.skin+" "+a.skin+"-"+b:""};layer.prompt=function(a,c){a=a||{},"function"==typeof a&&(c=a);var d,e=2==a.formType?'<textarea class="layui-layer-input">'+(a.value||"")+"</textarea>":function(){return'<input type="'+(1==a.formType?"password":"text")+'" class="layui-layer-input" value="'+(a.value||"")+'">'}();return layer.open($.extend({btn:["&#x786E;&#x5B9A;","&#x53D6;&#x6D88;"],content:e,skin:"layui-layer-prompt"+b("prompt"),success:function(a){d=a.find(".layui-layer-input"),d.focus()},yes:function(b){var e=d.val();""===e?d.focus():e.length>(a.maxlength||500)?layer.tips("&#x6700;&#x591A;&#x8F93;&#x5165;"+(a.maxlength||500)+"&#x4E2A;&#x5B57;&#x6570;",d,{tips:1}):c&&c(e,b,d)}},a))},layer.tab=function(a){a=a||{};var c=a.tab||{};return layer.open($.extend({type:1,skin:"layui-layer-tab"+b("tab"),title:function(){var a=c.length,b=1,d="";if(a>0)for(d='<span class="layui-layer-tabnow">'+c[0].title+"</span>";a>b;b++)d+="<span>"+c[b].title+"</span>";return d}(),content:'<ul class="layui-layer-tabmain">'+function(){var a=c.length,b=1,d="";if(a>0)for(d='<li class="layui-layer-tabli xubox_tab_layer">'+(c[0].content||"no content")+"</li>";a>b;b++)d+='<li class="layui-layer-tabli">'+(c[b].content||"no content")+"</li>";return d}()+"</ul>",success:function(a){var b=a.find(".layui-layer-title").children(),c=a.find(".layui-layer-tabmain").children();b.on("mousedown",function(a){a.stopPropagation?a.stopPropagation():a.cancelBubble=!0;var b=$(this),d=b.index();b.addClass("layui-layer-tabnow").siblings().removeClass("layui-layer-tabnow"),c.eq(d).show().siblings().hide()})}},a))},layer.photos=function(a,c,d){function e(a,b,c){var d=new Image;d.onload=function(){d.onload=null,b(d)},d.onerror=function(a){d.onerror=null,c(a)},d.src=a}var f={};if(a=a||{},a.photos){var g=a.photos.constructor===Object,h=g?a.photos:{},i=h.data||[],j=h.start||0;if(f.imgIndex=j+1,g){if(0===i.length)return void layer.msg("&#x6CA1;&#x6709;&#x56FE;&#x7247;")}else{var k=$(a.photos),l=k.find(a.img||"img");if(0===l.length)return;if(c||k.find(h.img||"img").each(function(b){var c=$(this);i.push({alt:c.attr("alt"),pid:c.attr("layer-pid"),src:c.attr("layer-src")||c.attr("src"),thumb:c.attr("src")}),c.on("click",function(){layer.photos($.extend(a,{photos:{start:b,data:i,tab:a.tab},full:a.full}),!0)})}),!c)return}f.imgprev=function(a){f.imgIndex--,f.imgIndex<1&&(f.imgIndex=i.length),f.tabimg(a)},f.imgnext=function(a,b){f.imgIndex++,f.imgIndex>i.length&&(f.imgIndex=1,b)||f.tabimg(a)},f.keyup=function(a){if(!f.end){var b=a.keyCode;a.preventDefault(),37===b?f.imgprev(!0):39===b?f.imgnext(!0):27===b&&layer.close(f.index)}},f.tabimg=function(b){i.length<=1||(h.start=f.imgIndex-1,layer.close(f.index),layer.photos(a,!0,b))},f.event=function(){f.bigimg.hover(function(){f.imgsee.show()},function(){f.imgsee.hide()}),f.bigimg.find(".layui-layer-imgprev").on("click",function(a){a.preventDefault(),f.imgprev()}),f.bigimg.find(".layui-layer-imgnext").on("click",function(a){a.preventDefault(),f.imgnext()}),$(document).on("keyup",f.keyup)},f.loadi=layer.load(1,{shade:"shade"in a?!1:.9,scrollbar:!1}),e(i[j].src,function(c){layer.close(f.loadi),f.index=layer.open($.extend({type:1,area:function(){var b=[c.width,c.height],d=[$(window).width()-100,$(window).height()-100];return!a.full&&b[0]>d[0]&&(b[0]=d[0],b[1]=b[0]*d[1]/b[0]),[b[0]+"px",b[1]+"px"]}(),title:!1,shade:.9,shadeClose:!0,closeBtn:!1,move:".layui-layer-phimg img",moveType:1,scrollbar:!1,moveOut:!0,shift:5*Math.random()|0,skin:"layui-layer-photos"+b("photos"),content:'<div class="layui-layer-phimg"><img src="'+i[j].src+'" alt="'+(i[j].alt||"")+'" layer-pid="'+i[j].pid+'"><div class="layui-layer-imgsee">'+(i.length>1?'<span class="layui-layer-imguide"><a href="javascript:;" class="layui-layer-iconext layui-layer-imgprev"></a><a href="javascript:;" class="layui-layer-iconext layui-layer-imgnext"></a></span>':"")+'<div class="layui-layer-imgbar" style="display:'+(d?"block":"")+'"><span class="layui-layer-imgtit"><a href="javascript:;">'+(i[j].alt||"")+"</a><em>"+f.imgIndex+"/"+i.length+"</em></span></div></div></div>",success:function(b,c){f.bigimg=b.find(".layui-layer-phimg"),f.imgsee=b.find(".layui-layer-imguide,.layui-layer-imgbar"),f.event(b),a.tab&&a.tab(i[j],b)},end:function(){f.end=!0,$(document).off("keyup",f.keyup)}},a))},function(){layer.close(f.loadi),layer.msg("&#x5F53;&#x524D;&#x56FE;&#x7247;&#x5730;&#x5740;&#x5F02;&#x5E38;<br>&#x662F;&#x5426;&#x7EE7;&#x7EED;&#x67E5;&#x770B;&#x4E0B;&#x4E00;&#x5F20;&#xFF1F;",{time:3e4,btn:["下一张","不看了"],yes:function(){i.length>1&&f.imgnext(!0,!0)}})})}}}();
/*! laydate-v5.0.9 日期与时间组件 MIT License http://www.layui.com/laydate/ By 贤心 */
;!function(){"use strict";var e=window.layui&&layui.define,t={getPath:function(){var e=document.currentScript?document.currentScript.src:function(){for(var e,t=document.scripts,n=t.length-1,a=n;a>0;a--)if("interactive"===t[a].readyState){e=t[a].src;break}return e||t[n].src}();return e.substring(0,e.lastIndexOf("/")+1)}(),getStyle:function(e,t){var n=e.currentStyle?e.currentStyle:window.getComputedStyle(e,null);return n[n.getPropertyValue?"getPropertyValue":"getAttribute"](t)},link:function(e,a,i){if(n.path){var r=document.getElementsByTagName("head")[0],o=document.createElement("link");"string"==typeof a&&(i=a);var s=(i||e).replace(/\.|\//g,""),l="layuicss-"+s,d=0;o.rel="stylesheet",o.href=n.path+e,o.id=l,document.getElementById(l)||r.appendChild(o),"function"==typeof a&&!function c(){return++d>80?window.console&&console.error("laydate.css: Invalid"):void(1989===parseInt(t.getStyle(document.getElementById(l),"width"))?a():setTimeout(c,100))}()}}},n={v:"5.0.9",config:{},index:window.laydate&&window.laydate.v?1e5:0,path:t.getPath,set:function(e){var t=this;return t.config=w.extend({},t.config,e),t},ready:function(a){var i="laydate",r="",o=(e?"modules/laydate/":"theme/")+"default/laydate.css?v="+n.v+r;return e?layui.addcss(o,a,i):t.link(o,a,i),this}},a=function(){var e=this;return{hint:function(t){e.hint.call(e,t)},config:e.config}},i="laydate",r=".layui-laydate",o="layui-this",s="laydate-disabled",l="开始日期超出了结束日期<br>建议重新选择",d=[100,2e5],c="layui-laydate-static",m="layui-laydate-list",u="laydate-selected",h="layui-laydate-hint",y="laydate-day-prev",f="laydate-day-next",p="layui-laydate-footer",g=".laydate-btns-confirm",v="laydate-time-text",D=".laydate-btns-time",T=function(e){var t=this;t.index=++n.index,t.config=w.extend({},t.config,n.config,e),n.ready(function(){t.init()})},w=function(e){return new C(e)},C=function(e){for(var t=0,n="object"==typeof e?[e]:(this.selector=e,document.querySelectorAll(e||null));t<n.length;t++)this.push(n[t])};C.prototype=[],C.prototype.constructor=C,w.extend=function(){var e=1,t=arguments,n=function(e,t){e=e||(t.constructor===Array?[]:{});for(var a in t)e[a]=t[a]&&t[a].constructor===Object?n(e[a],t[a]):t[a];return e};for(t[0]="object"==typeof t[0]?t[0]:{};e<t.length;e++)"object"==typeof t[e]&&n(t[0],t[e]);return t[0]},w.ie=function(){var e=navigator.userAgent.toLowerCase();return!!(window.ActiveXObject||"ActiveXObject"in window)&&((e.match(/msie\s(\d+)/)||[])[1]||"11")}(),w.stope=function(e){e=e||window.event,e.stopPropagation?e.stopPropagation():e.cancelBubble=!0},w.each=function(e,t){var n,a=this;if("function"!=typeof t)return a;if(e=e||[],e.constructor===Object){for(n in e)if(t.call(e[n],n,e[n]))break}else for(n=0;n<e.length&&!t.call(e[n],n,e[n]);n++);return a},w.digit=function(e,t,n){var a="";e=String(e),t=t||2;for(var i=e.length;i<t;i++)a+="0";return e<Math.pow(10,t)?a+(0|e):e},w.elem=function(e,t){var n=document.createElement(e);return w.each(t||{},function(e,t){n.setAttribute(e,t)}),n},C.addStr=function(e,t){return e=e.replace(/\s+/," "),t=t.replace(/\s+/," ").split(" "),w.each(t,function(t,n){new RegExp("\\b"+n+"\\b").test(e)||(e=e+" "+n)}),e.replace(/^\s|\s$/,"")},C.removeStr=function(e,t){return e=e.replace(/\s+/," "),t=t.replace(/\s+/," ").split(" "),w.each(t,function(t,n){var a=new RegExp("\\b"+n+"\\b");a.test(e)&&(e=e.replace(a,""))}),e.replace(/\s+/," ").replace(/^\s|\s$/,"")},C.prototype.find=function(e){var t=this,n=0,a=[],i="object"==typeof e;return this.each(function(r,o){for(var s=i?[e]:o.querySelectorAll(e||null);n<s.length;n++)a.push(s[n]);t.shift()}),i||(t.selector=(t.selector?t.selector+" ":"")+e),w.each(a,function(e,n){t.push(n)}),t},C.prototype.each=function(e){return w.each.call(this,this,e)},C.prototype.addClass=function(e,t){return this.each(function(n,a){a.className=C[t?"removeStr":"addStr"](a.className,e)})},C.prototype.removeClass=function(e){return this.addClass(e,!0)},C.prototype.hasClass=function(e){var t=!1;return this.each(function(n,a){new RegExp("\\b"+e+"\\b").test(a.className)&&(t=!0)}),t},C.prototype.attr=function(e,t){var n=this;return void 0===t?function(){if(n.length>0)return n[0].getAttribute(e)}():n.each(function(n,a){a.setAttribute(e,t)})},C.prototype.removeAttr=function(e){return this.each(function(t,n){n.removeAttribute(e)})},C.prototype.html=function(e){return this.each(function(t,n){n.innerHTML=e})},C.prototype.val=function(e){return this.each(function(t,n){n.value=e})},C.prototype.append=function(e){return this.each(function(t,n){"object"==typeof e?n.appendChild(e):n.innerHTML=n.innerHTML+e})},C.prototype.remove=function(e){return this.each(function(t,n){e?n.removeChild(e):n.parentNode.removeChild(n)})},C.prototype.on=function(e,t){return this.each(function(n,a){a.attachEvent?a.attachEvent("on"+e,function(e){e.target=e.srcElement,t.call(a,e)}):a.addEventListener(e,t,!1)})},C.prototype.off=function(e,t){return this.each(function(n,a){a.detachEvent?a.detachEvent("on"+e,t):a.removeEventListener(e,t,!1)})},T.isLeapYear=function(e){return e%4===0&&e%100!==0||e%400===0},T.prototype.config={type:"date",range:!1,format:"yyyy-MM-dd",value:null,min:"1900-1-1",max:"2099-12-31",trigger:"focus",show:!1,showBottom:!0,btns:["clear","now","confirm"],lang:"cn",theme:"default",position:null,calendar:!1,mark:{},zIndex:null,done:null,change:null},T.prototype.lang=function(){var e=this,t=e.config,n={cn:{weeks:["日","一","二","三","四","五","六"],time:["时","分","秒"],timeTips:"选择时间",startTime:"开始时间",endTime:"结束时间",dateTips:"返回日期",month:["一","二","三","四","五","六","七","八","九","十","十一","十二"],tools:{confirm:"确定",clear:"清空",now:"现在"}},en:{weeks:["Su","Mo","Tu","We","Th","Fr","Sa"],time:["Hours","Minutes","Seconds"],timeTips:"Select Time",startTime:"Start Time",endTime:"End Time",dateTips:"Select Date",month:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],tools:{confirm:"Confirm",clear:"Clear",now:"Now"}}};return n[t.lang]||n.cn},T.prototype.init=function(){var e=this,t=e.config,n="yyyy|y|MM|M|dd|d|HH|H|mm|m|ss|s",a="static"===t.position,i={year:"yyyy",month:"yyyy-MM",date:"yyyy-MM-dd",time:"HH:mm:ss",datetime:"yyyy-MM-dd HH:mm:ss"};t.elem=w(t.elem),t.eventElem=w(t.eventElem),t.elem[0]&&(t.range===!0&&(t.range="-"),t.format===i.date&&(t.format=i[t.type]),e.format=t.format.match(new RegExp(n+"|.","g"))||[],e.EXP_IF="",e.EXP_SPLIT="",w.each(e.format,function(t,a){var i=new RegExp(n).test(a)?"\\d{"+function(){return new RegExp(n).test(e.format[0===t?t+1:t-1]||"")?/^yyyy|y$/.test(a)?4:a.length:/^yyyy$/.test(a)?"1,4":/^y$/.test(a)?"1,308":"1,2"}()+"}":"\\"+a;e.EXP_IF=e.EXP_IF+i,e.EXP_SPLIT=e.EXP_SPLIT+"("+i+")"}),e.EXP_IF=new RegExp("^"+(t.range?e.EXP_IF+"\\s\\"+t.range+"\\s"+e.EXP_IF:e.EXP_IF)+"$"),e.EXP_SPLIT=new RegExp("^"+e.EXP_SPLIT+"$",""),e.isInput(t.elem[0])||"focus"===t.trigger&&(t.trigger="click"),t.elem.attr("lay-key")||(t.elem.attr("lay-key",e.index),t.eventElem.attr("lay-key",e.index)),t.mark=w.extend({},t.calendar&&"cn"===t.lang?{"0-1-1":"元旦","0-2-14":"情人","0-3-8":"妇女","0-3-12":"植树","0-4-1":"愚人","0-5-1":"劳动","0-5-4":"青年","0-6-1":"儿童","0-9-10":"教师","0-9-18":"国耻","0-10-1":"国庆","0-12-25":"圣诞"}:{},t.mark),w.each(["min","max"],function(e,n){var a=[],i=[];if("number"==typeof t[n]){var r=t[n],o=(new Date).getTime(),s=864e5,l=new Date(r?r<s?o+r*s:r:o);a=[l.getFullYear(),l.getMonth()+1,l.getDate()],r<s||(i=[l.getHours(),l.getMinutes(),l.getSeconds()])}else a=(t[n].match(/\d+-\d+-\d+/)||[""])[0].split("-"),i=(t[n].match(/\d+:\d+:\d+/)||[""])[0].split(":");t[n]={year:0|a[0]||(new Date).getFullYear(),month:a[1]?(0|a[1])-1:(new Date).getMonth(),date:0|a[2]||(new Date).getDate(),hours:0|i[0],minutes:0|i[1],seconds:0|i[2]}}),e.elemID="layui-laydate"+t.elem.attr("lay-key"),(t.show||a)&&e.render(),a||e.events(),t.value&&(t.value.constructor===Date?e.setValue(e.parse(0,e.systemDate(t.value))):e.setValue(t.value)))},T.prototype.render=function(){var e=this,t=e.config,n=e.lang(),a="static"===t.position,i=e.elem=w.elem("div",{id:e.elemID,"class":["layui-laydate",t.range?" layui-laydate-range":"",a?" "+c:"",t.theme&&"default"!==t.theme&&!/^#/.test(t.theme)?" laydate-theme-"+t.theme:""].join("")}),r=e.elemMain=[],o=e.elemHeader=[],s=e.elemCont=[],l=e.table=[],d=e.footer=w.elem("div",{"class":p});if(t.zIndex&&(i.style.zIndex=t.zIndex),w.each(new Array(2),function(e){if(!t.range&&e>0)return!0;var a=w.elem("div",{"class":"layui-laydate-header"}),i=[function(){var e=w.elem("i",{"class":"layui-icon laydate-icon laydate-prev-y"});return e.innerHTML="&#xe65a;",e}(),function(){var e=w.elem("i",{"class":"layui-icon laydate-icon laydate-prev-m"});return e.innerHTML="&#xe603;",e}(),function(){var e=w.elem("div",{"class":"laydate-set-ym"}),t=w.elem("span"),n=w.elem("span");return e.appendChild(t),e.appendChild(n),e}(),function(){var e=w.elem("i",{"class":"layui-icon laydate-icon laydate-next-m"});return e.innerHTML="&#xe602;",e}(),function(){var e=w.elem("i",{"class":"layui-icon laydate-icon laydate-next-y"});return e.innerHTML="&#xe65b;",e}()],d=w.elem("div",{"class":"layui-laydate-content"}),c=w.elem("table"),m=w.elem("thead"),u=w.elem("tr");w.each(i,function(e,t){a.appendChild(t)}),m.appendChild(u),w.each(new Array(6),function(e){var t=c.insertRow(0);w.each(new Array(7),function(a){if(0===e){var i=w.elem("th");i.innerHTML=n.weeks[a],u.appendChild(i)}t.insertCell(a)})}),c.insertBefore(m,c.children[0]),d.appendChild(c),r[e]=w.elem("div",{"class":"layui-laydate-main laydate-main-list-"+e}),r[e].appendChild(a),r[e].appendChild(d),o.push(i),s.push(d),l.push(c)}),w(d).html(function(){var e=[],i=[];return"datetime"===t.type&&e.push('<span lay-type="datetime" class="laydate-btns-time">'+n.timeTips+"</span>"),w.each(t.btns,function(e,r){var o=n.tools[r]||"btn";t.range&&"now"===r||(a&&"clear"===r&&(o="cn"===t.lang?"重置":"Reset"),i.push('<span lay-type="'+r+'" class="laydate-btns-'+r+'">'+o+"</span>"))}),e.push('<div class="laydate-footer-btns">'+i.join("")+"</div>"),e.join("")}()),w.each(r,function(e,t){i.appendChild(t)}),t.showBottom&&i.appendChild(d),/^#/.test(t.theme)){var m=w.elem("style"),u=["#{{id}} .layui-laydate-header{background-color:{{theme}};}","#{{id}} .layui-this{background-color:{{theme}} !important;}"].join("").replace(/{{id}}/g,e.elemID).replace(/{{theme}}/g,t.theme);"styleSheet"in m?(m.setAttribute("type","text/css"),m.styleSheet.cssText=u):m.innerHTML=u,w(i).addClass("laydate-theme-molv"),i.appendChild(m)}e.remove(T.thisElemDate),a?t.elem.append(i):(document.body.appendChild(i),e.position()),e.checkDate().calendar(),e.changeEvent(),T.thisElemDate=e.elemID,"function"==typeof t.ready&&t.ready(w.extend({},t.dateTime,{month:t.dateTime.month+1}))},T.prototype.remove=function(e){var t=this,n=(t.config,w("#"+(e||t.elemID)));return n.hasClass(c)||t.checkDate(function(){n.remove()}),t},T.prototype.position=function(){var e=this,t=e.config,n=e.bindElem||t.elem[0],a=n.getBoundingClientRect(),i=e.elem.offsetWidth,r=e.elem.offsetHeight,o=function(e){return e=e?"scrollLeft":"scrollTop",document.body[e]|document.documentElement[e]},s=function(e){return document.documentElement[e?"clientWidth":"clientHeight"]},l=5,d=a.left,c=a.bottom;d+i+l>s("width")&&(d=s("width")-i-l),c+r+l>s()&&(c=a.top>r?a.top-r:s()-r,c-=2*l),t.position&&(e.elem.style.position=t.position),e.elem.style.left=d+("fixed"===t.position?0:o(1))+"px",e.elem.style.top=c+("fixed"===t.position?0:o())+"px"},T.prototype.hint=function(e){var t=this,n=(t.config,w.elem("div",{"class":h}));n.innerHTML=e||"",w(t.elem).find("."+h).remove(),t.elem.appendChild(n),clearTimeout(t.hinTimer),t.hinTimer=setTimeout(function(){w(t.elem).find("."+h).remove()},3e3)},T.prototype.getAsYM=function(e,t,n){return n?t--:t++,t<0&&(t=11,e--),t>11&&(t=0,e++),[e,t]},T.prototype.systemDate=function(e){var t=e||new Date;return{year:t.getFullYear(),month:t.getMonth(),date:t.getDate(),hours:e?e.getHours():0,minutes:e?e.getMinutes():0,seconds:e?e.getSeconds():0}},T.prototype.checkDate=function(e){var t,a,i=this,r=(new Date,i.config),o=r.dateTime=r.dateTime||i.systemDate(),s=i.bindElem||r.elem[0],l=(i.isInput(s)?"val":"html",i.isInput(s)?s.value:"static"===r.position?"":s.innerHTML),c=function(e){e.year>d[1]&&(e.year=d[1],a=!0),e.month>11&&(e.month=11,a=!0),e.hours>23&&(e.hours=0,a=!0),e.minutes>59&&(e.minutes=0,e.hours++,a=!0),e.seconds>59&&(e.seconds=0,e.minutes++,a=!0),t=n.getEndDate(e.month+1,e.year),e.date>t&&(e.date=t,a=!0)},m=function(e,t,n){var o=["startTime","endTime"];t=(t.match(i.EXP_SPLIT)||[]).slice(1),n=n||0,r.range&&(i[o[n]]=i[o[n]]||{}),w.each(i.format,function(s,l){var c=parseFloat(t[s]);t[s].length<l.length&&(a=!0),/yyyy|y/.test(l)?(c<d[0]&&(c=d[0],a=!0),e.year=c):/MM|M/.test(l)?(c<1&&(c=1,a=!0),e.month=c-1):/dd|d/.test(l)?(c<1&&(c=1,a=!0),e.date=c):/HH|H/.test(l)?(c<1&&(c=0,a=!0),e.hours=c,r.range&&(i[o[n]].hours=c)):/mm|m/.test(l)?(c<1&&(c=0,a=!0),e.minutes=c,r.range&&(i[o[n]].minutes=c)):/ss|s/.test(l)&&(c<1&&(c=0,a=!0),e.seconds=c,r.range&&(i[o[n]].seconds=c))}),c(e)};return"limit"===e?(c(o),i):(l=l||r.value,"string"==typeof l&&(l=l.replace(/\s+/g," ").replace(/^\s|\s$/g,"")),i.startState&&!i.endState&&(delete i.startState,i.endState=!0),"string"==typeof l&&l?i.EXP_IF.test(l)?r.range?(l=l.split(" "+r.range+" "),i.startDate=i.startDate||i.systemDate(),i.endDate=i.endDate||i.systemDate(),r.dateTime=w.extend({},i.startDate),w.each([i.startDate,i.endDate],function(e,t){m(t,l[e],e)})):m(o,l):(i.hint("日期格式不合法<br>必须遵循下述格式:<br>"+(r.range?r.format+" "+r.range+" "+r.format:r.format)+"<br>已为你重置"),a=!0):l&&l.constructor===Date?r.dateTime=i.systemDate(l):(r.dateTime=i.systemDate(),delete i.startState,delete i.endState,delete i.startDate,delete i.endDate,delete i.startTime,delete i.endTime),c(o),a&&l&&i.setValue(r.range?i.endDate?i.parse():"":i.parse()),e&&e(),i)},T.prototype.mark=function(e,t){var n,a=this,i=a.config;return w.each(i.mark,function(e,a){var i=e.split("-");i[0]!=t[0]&&0!=i[0]||i[1]!=t[1]&&0!=i[1]||i[2]!=t[2]||(n=a||t[2])}),n&&e.html('<span class="laydate-day-mark">'+n+"</span>"),a},T.prototype.limit=function(e,t,n,a){var i,r=this,o=r.config,l={},d=o[n>41?"endDate":"dateTime"],c=w.extend({},d,t||{});return w.each({now:c,min:o.min,max:o.max},function(e,t){l[e]=r.newDate(w.extend({year:t.year,month:t.month,date:t.date},function(){var e={};return w.each(a,function(n,a){e[a]=t[a]}),e}())).getTime()}),i=l.now<l.min||l.now>l.max,e&&e[i?"addClass":"removeClass"](s),i},T.prototype.calendar=function(e){var t,a,i,r=this,s=r.config,l=e||s.dateTime,c=new Date,m=r.lang(),u="date"!==s.type&&"datetime"!==s.type,h=e?1:0,y=w(r.table[h]).find("td"),f=w(r.elemHeader[h][2]).find("span");if(l.year<d[0]&&(l.year=d[0],r.hint("最低只能支持到公元"+d[0]+"年")),l.year>d[1]&&(l.year=d[1],r.hint("最高只能支持到公元"+d[1]+"年")),r.firstDate||(r.firstDate=w.extend({},l)),c.setFullYear(l.year,l.month,1),t=c.getDay(),a=n.getEndDate(l.month||12,l.year),i=n.getEndDate(l.month+1,l.year),w.each(y,function(e,n){var d=[l.year,l.month],c=0;n=w(n),n.removeAttr("class"),e<t?(c=a-t+e,n.addClass("laydate-day-prev"),d=r.getAsYM(l.year,l.month,"sub")):e>=t&&e<i+t?(c=e-t,s.range||c+1===l.date&&n.addClass(o)):(c=e-i-t,n.addClass("laydate-day-next"),d=r.getAsYM(l.year,l.month)),d[1]++,d[2]=c+1,n.attr("lay-ymd",d.join("-")).html(d[2]),r.mark(n,d).limit(n,{year:d[0],month:d[1]-1,date:d[2]},e)}),w(f[0]).attr("lay-ym",l.year+"-"+(l.month+1)),w(f[1]).attr("lay-ym",l.year+"-"+(l.month+1)),"cn"===s.lang?(w(f[0]).attr("lay-type","year").html(l.year+"年"),w(f[1]).attr("lay-type","month").html(l.month+1+"月")):(w(f[0]).attr("lay-type","month").html(m.month[l.month]),w(f[1]).attr("lay-type","year").html(l.year)),u&&(s.range&&(e?r.endDate=r.endDate||{year:l.year+("year"===s.type?1:0),month:l.month+("month"===s.type?0:-1)}:r.startDate=r.startDate||{year:l.year,month:l.month},e&&(r.listYM=[[r.startDate.year,r.startDate.month+1],[r.endDate.year,r.endDate.month+1]],r.list(s.type,0).list(s.type,1),"time"===s.type?r.setBtnStatus("时间",w.extend({},r.systemDate(),r.startTime),w.extend({},r.systemDate(),r.endTime)):r.setBtnStatus(!0))),s.range||(r.listYM=[[l.year,l.month+1]],r.list(s.type,0))),s.range&&!e){var p=r.getAsYM(l.year,l.month);r.calendar(w.extend({},l,{year:p[0],month:p[1]}))}return s.range||r.limit(w(r.footer).find(g),null,0,["hours","minutes","seconds"]),s.range&&e&&!u&&r.stampRange(),r},T.prototype.list=function(e,t){var n=this,a=n.config,i=a.dateTime,r=n.lang(),l=a.range&&"date"!==a.type&&"datetime"!==a.type,d=w.elem("ul",{"class":m+" "+{year:"laydate-year-list",month:"laydate-month-list",time:"laydate-time-list"}[e]}),c=n.elemHeader[t],u=w(c[2]).find("span"),h=n.elemCont[t||0],y=w(h).find("."+m)[0],f="cn"===a.lang,p=f?"年":"",T=n.listYM[t]||{},C=["hours","minutes","seconds"],x=["startTime","endTime"][t];if(T[0]<1&&(T[0]=1),"year"===e){var M,b=M=T[0]-7;b<1&&(b=M=1),w.each(new Array(15),function(e){var i=w.elem("li",{"lay-ym":M}),r={year:M};M==T[0]&&w(i).addClass(o),i.innerHTML=M+p,d.appendChild(i),M<n.firstDate.year?(r.month=a.min.month,r.date=a.min.date):M>=n.firstDate.year&&(r.month=a.max.month,r.date=a.max.date),n.limit(w(i),r,t),M++}),w(u[f?0:1]).attr("lay-ym",M-8+"-"+T[1]).html(b+p+" - "+(M-1+p))}else if("month"===e)w.each(new Array(12),function(e){var i=w.elem("li",{"lay-ym":e}),s={year:T[0],month:e};e+1==T[1]&&w(i).addClass(o),i.innerHTML=r.month[e]+(f?"月":""),d.appendChild(i),T[0]<n.firstDate.year?s.date=a.min.date:T[0]>=n.firstDate.year&&(s.date=a.max.date),n.limit(w(i),s,t)}),w(u[f?0:1]).attr("lay-ym",T[0]+"-"+T[1]).html(T[0]+p);else if("time"===e){var E=function(){w(d).find("ol").each(function(e,a){w(a).find("li").each(function(a,i){n.limit(w(i),[{hours:a},{hours:n[x].hours,minutes:a},{hours:n[x].hours,minutes:n[x].minutes,seconds:a}][e],t,[["hours"],["hours","minutes"],["hours","minutes","seconds"]][e])})}),a.range||n.limit(w(n.footer).find(g),n[x],0,["hours","minutes","seconds"])};a.range?n[x]||(n[x]={hours:0,minutes:0,seconds:0}):n[x]=i,w.each([24,60,60],function(e,t){var a=w.elem("li"),i=["<p>"+r.time[e]+"</p><ol>"];w.each(new Array(t),function(t){i.push("<li"+(n[x][C[e]]===t?' class="'+o+'"':"")+">"+w.digit(t,2)+"</li>")}),a.innerHTML=i.join("")+"</ol>",d.appendChild(a)}),E()}if(y&&h.removeChild(y),h.appendChild(d),"year"===e||"month"===e)w(n.elemMain[t]).addClass("laydate-ym-show"),w(d).find("li").on("click",function(){var r=0|w(this).attr("lay-ym");if(!w(this).hasClass(s)){if(0===t)i[e]=r,l&&(n.startDate[e]=r),n.limit(w(n.footer).find(g),null,0);else if(l)n.endDate[e]=r;else{var c="year"===e?n.getAsYM(r,T[1]-1,"sub"):n.getAsYM(T[0],r,"sub");w.extend(i,{year:c[0],month:c[1]})}"year"===a.type||"month"===a.type?(w(d).find("."+o).removeClass(o),w(this).addClass(o),"month"===a.type&&"year"===e&&(n.listYM[t][0]=r,l&&(n[["startDate","endDate"][t]].year=r),n.list("month",t))):(n.checkDate("limit").calendar(),n.closeList()),n.setBtnStatus(),a.range||n.done(null,"change"),w(n.footer).find(D).removeClass(s)}});else{var S=w.elem("span",{"class":v}),k=function(){w(d).find("ol").each(function(e){var t=this,a=w(t).find("li");t.scrollTop=30*(n[x][C[e]]-2),t.scrollTop<=0&&a.each(function(e,n){if(!w(this).hasClass(s))return t.scrollTop=30*(e-2),!0})})},H=w(c[2]).find("."+v);k(),S.innerHTML=a.range?[r.startTime,r.endTime][t]:r.timeTips,w(n.elemMain[t]).addClass("laydate-time-show"),H[0]&&H.remove(),c[2].appendChild(S),w(d).find("ol").each(function(e){var t=this;w(t).find("li").on("click",function(){var r=0|this.innerHTML;w(this).hasClass(s)||(a.range?n[x][C[e]]=r:i[C[e]]=r,w(t).find("."+o).removeClass(o),w(this).addClass(o),E(),k(),(n.endDate||"time"===a.type)&&n.done(null,"change"),n.setBtnStatus())})})}return n},T.prototype.listYM=[],T.prototype.closeList=function(){var e=this;e.config;w.each(e.elemCont,function(t,n){w(this).find("."+m).remove(),w(e.elemMain[t]).removeClass("laydate-ym-show laydate-time-show")}),w(e.elem).find("."+v).remove()},T.prototype.setBtnStatus=function(e,t,n){var a,i=this,r=i.config,o=w(i.footer).find(g),d=r.range&&"date"!==r.type&&"time"!==r.type;d&&(t=t||i.startDate,n=n||i.endDate,a=i.newDate(t).getTime()>i.newDate(n).getTime(),i.limit(null,t)||i.limit(null,n)?o.addClass(s):o[a?"addClass":"removeClass"](s),e&&a&&i.hint("string"==typeof e?l.replace(/日期/g,e):l))},T.prototype.parse=function(e,t){var n=this,a=n.config,i=t||(e?w.extend({},n.endDate,n.endTime):a.range?w.extend({},n.startDate,n.startTime):a.dateTime),r=n.format.concat();return w.each(r,function(e,t){/yyyy|y/.test(t)?r[e]=w.digit(i.year,t.length):/MM|M/.test(t)?r[e]=w.digit(i.month+1,t.length):/dd|d/.test(t)?r[e]=w.digit(i.date,t.length):/HH|H/.test(t)?r[e]=w.digit(i.hours,t.length):/mm|m/.test(t)?r[e]=w.digit(i.minutes,t.length):/ss|s/.test(t)&&(r[e]=w.digit(i.seconds,t.length))}),a.range&&!e?r.join("")+" "+a.range+" "+n.parse(1):r.join("")},T.prototype.newDate=function(e){return e=e||{},new Date(e.year||1,e.month||0,e.date||1,e.hours||0,e.minutes||0,e.seconds||0)},T.prototype.setValue=function(e){var t=this,n=t.config,a=t.bindElem||n.elem[0],i=t.isInput(a)?"val":"html";return"static"===n.position||w(a)[i](e||""),this},T.prototype.stampRange=function(){var e,t,n=this,a=n.config,i=w(n.elem).find("td");if(a.range&&!n.endDate&&w(n.footer).find(g).addClass(s),n.endDate)return e=n.newDate({year:n.startDate.year,month:n.startDate.month,date:n.startDate.date}).getTime(),t=n.newDate({year:n.endDate.year,month:n.endDate.month,date:n.endDate.date}).getTime(),e>t?n.hint(l):void w.each(i,function(a,i){var r=w(i).attr("lay-ymd").split("-"),s=n.newDate({year:r[0],month:r[1]-1,date:r[2]}).getTime();w(i).removeClass(u+" "+o),s!==e&&s!==t||w(i).addClass(w(i).hasClass(y)||w(i).hasClass(f)?u:o),s>e&&s<t&&w(i).addClass(u)})},T.prototype.done=function(e,t){var n=this,a=n.config,i=w.extend({},n.startDate?w.extend(n.startDate,n.startTime):a.dateTime),r=w.extend({},w.extend(n.endDate,n.endTime));return w.each([i,r],function(e,t){"month"in t&&w.extend(t,{month:t.month+1})}),e=e||[n.parse(),i,r],"function"==typeof a[t||"done"]&&a[t||"done"].apply(a,e),n},T.prototype.choose=function(e){var t=this,n=t.config,a=n.dateTime,i=w(t.elem).find("td"),r=e.attr("lay-ymd").split("-"),l=function(e){new Date;e&&w.extend(a,r),n.range&&(t.startDate?w.extend(t.startDate,r):t.startDate=w.extend({},r,t.startTime),t.startYMD=r)};if(r={year:0|r[0],month:(0|r[1])-1,date:0|r[2]},!e.hasClass(s))if(n.range){if(w.each(["startTime","endTime"],function(e,n){t[n]=t[n]||{hours:0,minutes:0,seconds:0}}),t.endState)l(),delete t.endState,delete t.endDate,t.startState=!0,i.removeClass(o+" "+u),e.addClass(o);else if(t.startState){if(e.addClass(o),t.endDate?w.extend(t.endDate,r):t.endDate=w.extend({},r,t.endTime),t.newDate(r).getTime()<t.newDate(t.startYMD).getTime()){var d=w.extend({},t.endDate,{hours:t.startDate.hours,minutes:t.startDate.minutes,seconds:t.startDate.seconds});w.extend(t.endDate,t.startDate,{hours:t.endDate.hours,minutes:t.endDate.minutes,seconds:t.endDate.seconds}),t.startDate=d}n.showBottom||t.done(),t.stampRange(),t.endState=!0,t.done(null,"change")}else e.addClass(o),l(),t.startState=!0;w(t.footer).find(g)[t.endDate?"removeClass":"addClass"](s)}else"static"===n.position?(l(!0),t.calendar().done().done(null,"change")):"date"===n.type?(l(!0),t.setValue(t.parse()).remove().done()):"datetime"===n.type&&(l(!0),t.calendar().done(null,"change"))},T.prototype.tool=function(e,t){var n=this,a=n.config,i=a.dateTime,r="static"===a.position,o={datetime:function(){w(e).hasClass(s)||(n.list("time",0),a.range&&n.list("time",1),w(e).attr("lay-type","date").html(n.lang().dateTips))},date:function(){n.closeList(),w(e).attr("lay-type","datetime").html(n.lang().timeTips)},clear:function(){n.setValue("").remove(),r&&(w.extend(i,n.firstDate),n.calendar()),a.range&&(delete n.startState,delete n.endState,delete n.endDate,delete n.startTime,delete n.endTime),n.done(["",{},{}])},now:function(){var e=new Date;w.extend(i,n.systemDate(),{hours:e.getHours(),minutes:e.getMinutes(),seconds:e.getSeconds()}),n.setValue(n.parse()).remove(),r&&n.calendar(),n.done()},confirm:function(){if(a.range){if(!n.endDate)return n.hint("请先选择日期范围");if(w(e).hasClass(s))return n.hint("time"===a.type?l.replace(/日期/g,"时间"):l)}else if(w(e).hasClass(s))return n.hint("不在有效日期或时间范围内");n.done(),n.setValue(n.parse()).remove()}};o[t]&&o[t]()},T.prototype.change=function(e){var t=this,n=t.config,a=n.dateTime,i=n.range&&("year"===n.type||"month"===n.type),r=t.elemCont[e||0],o=t.listYM[e],s=function(s){var l=["startDate","endDate"][e],d=w(r).find(".laydate-year-list")[0],c=w(r).find(".laydate-month-list")[0];return d&&(o[0]=s?o[0]-15:o[0]+15,t.list("year",e)),c&&(s?o[0]--:o[0]++,t.list("month",e)),(d||c)&&(w.extend(a,{year:o[0]}),i&&(t[l].year=o[0]),n.range||t.done(null,"change"),t.setBtnStatus(),n.range||t.limit(w(t.footer).find(g),{year:o[0]})),d||c};return{prevYear:function(){s("sub")||(a.year--,t.checkDate("limit").calendar(),n.range||t.done(null,"change"))},prevMonth:function(){var e=t.getAsYM(a.year,a.month,"sub");w.extend(a,{year:e[0],month:e[1]}),t.checkDate("limit").calendar(),n.range||t.done(null,"change")},nextMonth:function(){var e=t.getAsYM(a.year,a.month);w.extend(a,{year:e[0],month:e[1]}),t.checkDate("limit").calendar(),n.range||t.done(null,"change")},nextYear:function(){s()||(a.year++,t.checkDate("limit").calendar(),n.range||t.done(null,"change"))}}},T.prototype.changeEvent=function(){var e=this;e.config;w(e.elem).on("click",function(e){w.stope(e)}),w.each(e.elemHeader,function(t,n){w(n[0]).on("click",function(n){e.change(t).prevYear()}),w(n[1]).on("click",function(n){e.change(t).prevMonth()}),w(n[2]).find("span").on("click",function(n){var a=w(this),i=a.attr("lay-ym"),r=a.attr("lay-type");i&&(i=i.split("-"),e.listYM[t]=[0|i[0],0|i[1]],e.list(r,t),w(e.footer).find(D).addClass(s))}),w(n[3]).on("click",function(n){e.change(t).nextMonth()}),w(n[4]).on("click",function(n){e.change(t).nextYear()})}),w.each(e.table,function(t,n){var a=w(n).find("td");a.on("click",function(){e.choose(w(this))})}),w(e.footer).find("span").on("click",function(){var t=w(this).attr("lay-type");e.tool(this,t)})},T.prototype.isInput=function(e){return/input|textarea/.test(e.tagName.toLocaleLowerCase())},T.prototype.events=function(){var e=this,t=e.config,n=function(n,a){n.on(t.trigger,function(){a&&(e.bindElem=this),e.render()})};t.elem[0]&&!t.elem[0].eventHandler&&(n(t.elem,"bind"),n(t.eventElem),w(document).on("click",function(n){n.target!==t.elem[0]&&n.target!==t.eventElem[0]&&n.target!==w(t.closeStop)[0]&&e.remove()}).on("keydown",function(t){13===t.keyCode&&w("#"+e.elemID)[0]&&e.elemID===T.thisElem&&(t.preventDefault(),w(e.footer).find(g)[0].click())}),w(window).on("resize",function(){return!(!e.elem||!w(r)[0])&&void e.position()}),t.elem[0].eventHandler=!0)},n.render=function(e){var t=new T(e);return a.call(t)},n.getEndDate=function(e,t){var n=new Date;return n.setFullYear(t||n.getFullYear(),e||n.getMonth()+1,1),new Date(n.getTime()-864e5).getDate()},window.lay=window.lay||w,e?(n.ready(),layui.define(function(e){n.path=layui.cache.dir,e(i,n)})):"function"==typeof define&&define.amd?define(function(){return n}):function(){n.ready(),window.laydate=n}()}();
\ No newline at end of file
/**
@Name: laydate 核心样式
@Author:贤心
@Site:http://sentsin.com/layui/laydate
**/
html{_background-image:url(about:blank); _background-attachment:fixed;}
.layer-date{display: inline-block!important;vertical-align:text-top;max-width:240px;}
.laydate_body .laydate_box, .laydate_body .laydate_box *{margin:0; padding:0;}
.laydate-icon,
.laydate-icon-default,
.laydate-icon-danlan,
.laydate-icon-dahong,
.laydate-icon-molv{height:34px; padding-right:20px;min-width:34px;vertical-align: text-top;border:1px solid #C6C6C6; background-repeat:no-repeat; background-position:right center; background-color:#fff; outline:0;}
.laydate-icon-default{ background-image:url(../skins/default/icon.png)}
.laydate-icon-danlan{border:1px solid #B1D2EC; background-image:url(../skins/danlan/icon.png)}
.laydate-icon-dahong{background-image:url(../skins/dahong/icon.png)}
.laydate-icon-molv{background-image:url(../skins/molv/icon.png)}
.laydate_body .laydate_box{width:240px; font:12px '\5B8B\4F53'; z-index:99999999; *margin:-2px 0 0 -2px; *overflow:hidden; _margin:0; _position:absolute!important; background-color:#fff;}
.laydate_body .laydate_box li{list-style:none;}
.laydate_body .laydate_box .laydate_void{cursor:text!important;}
.laydate_body .laydate_box a, .laydate_body .laydate_box a:hover{text-decoration:none; blr:expression(this.onFocus=this.blur()); cursor:pointer;}
.laydate_body .laydate_box a:hover{text-decoration:none;}
.laydate_body .laydate_box cite, .laydate_body .laydate_box label{position:absolute; width:0; height:0; border-width:5px; border-style:dashed; border-color:transparent; overflow:hidden; cursor:pointer;}
.laydate_body .laydate_box .laydate_yms, .laydate_body .laydate_box .laydate_time{display:none;}
.laydate_body .laydate_box .laydate_show{display:block;}
.laydate_body .laydate_box input{outline:0; font-size:14px; background-color:#fff;}
.laydate_body .laydate_top{position:relative; height:26px; padding:5px; *width:100%; z-index:99;}
.laydate_body .laydate_ym{position:relative; float:left; height:24px; cursor:pointer;}
.laydate_body .laydate_ym input{float:left; height:24px; line-height:24px; text-align:center; border:none; cursor:pointer;}
.laydate_body .laydate_ym .laydate_yms{position:absolute; left: -1px; top: 24px; height:181px;}
.laydate_body .laydate_y{width:121px;}
.laydate_body .laydate_y input{width:64px; margin-right:15px;}
.laydate_body .laydate_y .laydate_yms{width:121px; text-align:center;}
.laydate_body .laydate_y .laydate_yms a{position:relative; display:block; height:20px;}
.laydate_body .laydate_y .laydate_yms ul{height:139px; padding:0; *overflow:hidden;}
.laydate_body .laydate_y .laydate_yms ul li{float:left; width:60px; height:20px; line-height: 20px; text-overflow: ellipsis; overflow: hidden; white-space: nowrap;}
.laydate_box *{box-sizing:content-box!important;}
.laydate_body .laydate_m{width:99px;float: right;margin-right:-2px;}
.laydate_body .laydate_m .laydate_yms{width:99px; padding:0;}
.laydate_body .laydate_m input{width:42px; margin-right:15px;}
.laydate_body .laydate_m .laydate_yms span{display:block; float:left; width:42px; margin: 5px 0 0 5px; line-height:24px; text-align:center; _display:inline;}
.laydate_body .laydate_choose{display:block; float:left; position:relative; width:20px; height:24px;}
.laydate_body .laydate_choose cite, .laydate_body .laydate_tab cite{left:50%; top:50%;}
.laydate_body .laydate_chtop cite{margin:-7px 0 0 -5px; border-bottom-style:solid;}
.laydate_body .laydate_chdown cite, .laydate_body .laydate_ym label{top:50%; margin:-2px 0 0 -5px; border-top-style:solid;}
.laydate_body .laydate_chprev cite{margin:-5px 0 0 -7px;}
.laydate_body .laydate_chnext cite{margin:-5px 0 0 -2px;}
.laydate_body .laydate_ym label{right:28px;}
.laydate_body .laydate_table{ width:230px; margin:0 5px; border-collapse:collapse; border-spacing:0px; }
.laydate_body .laydate_table td{width:31px; height:19px; line-height:19px; text-align: center; cursor:pointer; font-size: 12px;}
.laydate_body .laydate_table thead{height:22px; line-height:22px;}
.laydate_body .laydate_table thead th{font-weight:400; font-size:12px; text-align:center;}
.laydate_body .laydate_bottom{position:relative; height:22px; line-height:20px; padding:5px; font-size:12px;}
.laydate_body .laydate_bottom #laydate_hms{position: relative; z-index: 1; float:left; }
.laydate_body .laydate_time{ position:absolute; left:5px; bottom: 26px; width:129px; height:125px; *overflow:hidden;}
.laydate_body .laydate_time .laydate_hmsno{ padding:5px 0 0 5px;}
.laydate_body .laydate_time .laydate_hmsno span{display:block; float:left; width:24px; height:19px; line-height:19px; text-align:center; cursor:pointer; *margin-bottom:-5px;}
.laydate_body .laydate_time1{width:228px; height:154px;}
.laydate_body .laydate_time1 .laydate_hmsno{padding: 6px 0 0 8px;}
.laydate_body .laydate_time1 .laydate_hmsno span{width:21px; height:20px; line-height:20px;}
.laydate_body .laydate_msg{left:49px; bottom:67px; width:141px; height:auto; overflow: hidden;}
.laydate_body .laydate_msg p{padding:5px 10px;}
.laydate_body .laydate_bottom li{float:left; height:20px; line-height:20px; border-right:none; font-weight:900;}
.laydate_body .laydate_bottom .laydate_sj{width:33px; text-align:center; font-weight:400;}
.laydate_body .laydate_bottom input{float:left; width:21px; height:20px; line-height:20px; border:none; text-align:center; cursor:pointer; font-size:12px; font-weight:400;}
.laydate_body .laydate_bottom .laydte_hsmtex{height:20px; line-height:20px; text-align:center;}
.laydate_body .laydate_bottom .laydte_hsmtex span{position:absolute; width:20px; top:0; right:0px; cursor:pointer;}
.laydate_body .laydate_bottom .laydte_hsmtex span:hover{font-size:14px;}
.laydate_body .laydate_bottom .laydate_btn{position:absolute; right:5px; top:5px;}
.laydate_body .laydate_bottom .laydate_btn a{float:left; height:20px; padding:0 6px; _padding:0 5px;}
.laydate_body .laydate_bottom .laydate_v{position:absolute; left:10px; top:6px; font-family:Courier; z-index:0;}
/**
@Name: laydate皮肤:墨绿
@Author:贤心
@Site:http://sentsin.com/layui/laydate
**/
.laydate-icon{border:1px solid #ccc; background-image:url(icon.png)}
.laydate_body .laydate_bottom #laydate_hms,
.laydate_body .laydate_time{border:1px solid #ccc;}
.laydate_body .laydate_box,
.laydate_body .laydate_ym .laydate_yms,
.laydate_body .laydate_time{box-shadow: 2px 2px 5px rgba(0,0,0,.1);}
.laydate_body .laydate_box{border-top:none; border-bottom:none; background-color:#fff; color:#00625A;}
.laydate_body .laydate_box input{background:none!important; color:#fff;}
.laydate_body .laydate_box .laydate_void{color:#00E8D7!important;}
.laydate_body .laydate_box a, .laydate_body .laydate_box a:hover{color:#00625A;}
.laydate_body .laydate_box a:hover{color:#666;}
.laydate_body .laydate_click{background-color:#009F95!important; color:#fff!important;}
.laydate_body .laydate_top{border-top:1px solid #009F95; background-color:#009F95}
.laydate_body .laydate_ym{border:1px solid #009F95; background-color:#009F95;}
.laydate_body .laydate_ym .laydate_yms{border:1px solid #009F95; background-color:#009F95; color:#fff;}
.laydate_body .laydate_y .laydate_yms a{border-bottom:1px solid #009F95;}
.laydate_body .laydate_y .laydate_yms .laydate_chdown{border-top:1px solid #009F95; border-bottom:none;}
.laydate_body .laydate_choose{border-left:1px solid #009F95;}
.laydate_body .laydate_chprev{border-left:none; border-right:1px solid #009F95;}
.laydate_body .laydate_choose:hover,
.laydate_body .laydate_y .laydate_yms a:hover{background-color:#00C1B3;}
.laydate_body .laydate_chtop cite{border-bottom-color:#fff;}
.laydate_body .laydate_chdown cite, .laydate_body .laydate_ym label{border-top-color:#fff;}
.laydate_body .laydate_chprev cite{border-right-style:solid; border-right-color:#fff;}
.laydate_body .laydate_chnext cite{border-left-style:solid; border-left-color:#fff;}
.laydate_body .laydate_table{width: 240px!important; margin: 0!important; border:1px solid #ccc; border-top:none; border-bottom:none;}
.laydate_body .laydate_table td{border:none; height:21px!important; line-height:21px!important; background-color:#fff; color:#00625A;}
.laydate_body .laydate_table .laydate_nothis{color:#999;}
.laydate_body .laydate_table thead{border-bottom:1px solid #ccc; height:21px!important; line-height:21px!important;}
.laydate_body .laydate_table thead th{}
.laydate_body .laydate_bottom{border:1px solid #ccc; border-top:none;}
.laydate_body .laydate_bottom #laydate_hms{background-color:#fff;}
.laydate_body .laydate_time{background-color:#fff;}
.laydate_body .laydate_time1{width: 226px!important; height: 152px!important;}
.laydate_body .laydate_bottom .laydate_sj{width:31px!important; border-right:1px solid #ccc; background-color:#fff;}
.laydate_body .laydate_bottom input{background-color:#fff; color:#00625A;}
.laydate_body .laydate_bottom .laydte_hsmtex{border-bottom:1px solid #ccc;}
.laydate_body .laydate_bottom .laydate_btn{border-right:1px solid #ccc;}
.laydate_body .laydate_bottom .laydate_v{color:#999}
.laydate_body .laydate_bottom .laydate_btn a{border: 1px solid #ccc; border-right:none; background-color:#fff;}
.laydate_body .laydate_bottom .laydate_btn a:hover{background-color:#F6F6F6; color:#00625A;}
.laydate_body .laydate_m .laydate_yms span:hover,
.laydate_body .laydate_time .laydate_hmsno span:hover,
.laydate_body .laydate_y .laydate_yms ul li:hover,
.laydate_body .laydate_table td:hover{background-color:#00C1B3; color:#fff;}
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
<!--
2013-9-30: Created.
-->
<svg>
<metadata>
Created by iconfont
</metadata>
<defs>
<font id="laydate-icon" horiz-adv-x="1024" >
<font-face
font-family="laydate-icon"
font-weight="500"
font-stretch="normal"
units-per-em="1024"
ascent="896"
descent="-128"
/>
<missing-glyph />
<glyph glyph-name="x" unicode="x" horiz-adv-x="1001"
d="M281 543q-27 -1 -53 -1h-83q-18 0 -36.5 -6t-32.5 -18.5t-23 -32t-9 -45.5v-76h912v41q0 16 -0.5 30t-0.5 18q0 13 -5 29t-17 29.5t-31.5 22.5t-49.5 9h-133v-97h-438v97zM955 310v-52q0 -23 0.5 -52t0.5 -58t-10.5 -47.5t-26 -30t-33 -16t-31.5 -4.5q-14 -1 -29.5 -0.5
t-29.5 0.5h-32l-45 128h-439l-44 -128h-29h-34q-20 0 -45 1q-25 0 -41 9.5t-25.5 23t-13.5 29.5t-4 30v167h911zM163 247q-12 0 -21 -8.5t-9 -21.5t9 -21.5t21 -8.5q13 0 22 8.5t9 21.5t-9 21.5t-22 8.5zM316 123q-8 -26 -14 -48q-5 -19 -10.5 -37t-7.5 -25t-3 -15t1 -14.5
t9.5 -10.5t21.5 -4h37h67h81h80h64h36q23 0 34 12t2 38q-5 13 -9.5 30.5t-9.5 34.5q-5 19 -11 39h-368zM336 498v228q0 11 2.5 23t10 21.5t20.5 15.5t34 6h188q31 0 51.5 -14.5t20.5 -52.5v-227h-327z" />
<glyph glyph-name="youyou" unicode="&#58882;" d="M283.648 721.918976 340.873216 780.926976 740.352 383.997952 340.876288-12.925952 283.648 46.077952 619.52 383.997952Z" horiz-adv-x="1024" />
<glyph glyph-name="zuozuo" unicode="&#58883;" d="M740.352 721.918976 683.126784 780.926976 283.648 383.997952 683.123712-12.925952 740.352 46.077952 404.48 383.997952Z" horiz-adv-x="1024" />
<glyph glyph-name="xiayiye" unicode="&#58970;" d="M62.573 384.103l423.401 423.662c18.985 18.985 49.757 18.985 68.727 0 18.982-18.972 18.985-49.746 0-68.729l-355.058-355.067 356.796-356.796c18.977-18.971 18.976-49.746 0-68.727-18.982-18.976-49.751-18.976-68.727 0l-39.753 39.753 0.269 0.246-385.655 385.661zM451.365 384.103l423.407 423.662c18.985 18.985 49.757 18.985 68.727 0 18.982-18.972 18.985-49.746 0-68.729l-355.058-355.067 356.796-356.796c18.977-18.971 18.976-49.746 0-68.727-18.982-18.976-49.757-18.977-68.727 0l-39.762 39.754 0.273 0.249-385.662 385.661zM451.365 384.103z" horiz-adv-x="1024" />
<glyph glyph-name="xiayiye1" unicode="&#58971;" d="M948.066926 382.958838l-411.990051-412.24426c-18.47333-18.47333-48.417689-18.47333-66.875207 0-18.47333 18.461167-18.47333 48.405526 0 66.875207L814.691135 383.088983 467.512212 730.269123c-18.466032 18.458735-18.466032 48.405526 0 66.873991 18.468465 18.464816 48.410391 18.464816 66.872774 0l38.682336-38.682336-0.261507-0.239614 375.259894-375.265975v0.003649m-378.312834 0L157.756743-29.285422c-18.47333-18.47333-48.415256-18.47333-66.872775 0-18.47333 18.461167-18.47333 48.405526 0 66.875207L436.369787 383.088983 89.19208 730.269123c-18.4636 18.458735-18.4636 48.405526 0 66.873991 18.470898 18.464816 48.415256 18.464816 66.872774 0l38.692067-38.682336-0.266372-0.239614 375.267191-375.265975-0.004865 0.003649m0 0z" horiz-adv-x="1024" />
</font>
</defs></svg>
/*! laydate-v5.0.9 日期与时间组件 MIT License http://www.layui.com/laydate/ By 贤心 */
.laydate-set-ym,.layui-laydate,.layui-laydate *,.layui-laydate-list{box-sizing:border-box}html #layuicss-laydate{display:none;position:absolute;width:1989px}.layui-laydate *{margin:0;padding:0}.layui-laydate{position:absolute;z-index:66666666;margin:5px 0;border-radius:2px;font-size:14px;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-name:laydate-upbit;animation-name:laydate-upbit}.layui-laydate-main{width:272px}.layui-laydate-content td,.layui-laydate-header *,.layui-laydate-list li{transition-duration:.3s;-webkit-transition-duration:.3s}@-webkit-keyframes laydate-upbit{from{-webkit-transform:translate3d(0,20px,0);opacity:.3}to{-webkit-transform:translate3d(0,0,0);opacity:1}}@keyframes laydate-upbit{from{transform:translate3d(0,20px,0);opacity:.3}to{transform:translate3d(0,0,0);opacity:1}}.layui-laydate-static{position:relative;z-index:0;display:inline-block;margin:0;-webkit-animation:none;animation:none}.laydate-ym-show .laydate-next-m,.laydate-ym-show .laydate-prev-m{display:none!important}.laydate-ym-show .laydate-next-y,.laydate-ym-show .laydate-prev-y{display:inline-block!important}.laydate-time-show .laydate-set-ym span[lay-type=month],.laydate-time-show .laydate-set-ym span[lay-type=year],.laydate-time-show .layui-laydate-header .layui-icon,.laydate-ym-show .laydate-set-ym span[lay-type=month]{display:none!important}.layui-laydate-header{position:relative;line-height:30px;padding:10px 70px 5px}.laydate-set-ym span,.layui-laydate-header i{padding:0 5px;cursor:pointer}.layui-laydate-header *{display:inline-block;vertical-align:bottom}.layui-laydate-header i{position:absolute;top:10px;color:#999;font-size:18px}.layui-laydate-header i.laydate-prev-y{left:15px}.layui-laydate-header i.laydate-prev-m{left:45px}.layui-laydate-header i.laydate-next-y{right:15px}.layui-laydate-header i.laydate-next-m{right:45px}.laydate-set-ym{width:100%;text-align:center;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.laydate-time-text{cursor:default!important}.layui-laydate-content{position:relative;padding:10px;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none}.layui-laydate-content table{border-collapse:collapse;border-spacing:0}.layui-laydate-content td,.layui-laydate-content th{width:36px;height:30px;padding:5px;text-align:center}.layui-laydate-content td{position:relative;cursor:pointer}.laydate-day-mark{position:absolute;left:0;top:0;width:100%;height:100%;line-height:30px;font-size:12px;overflow:hidden}.laydate-day-mark::after{position:absolute;content:'';right:2px;top:2px;width:5px;height:5px;border-radius:50%}.layui-laydate-footer{position:relative;height:46px;line-height:26px;padding:10px 20px}.layui-laydate-footer span{margin-right:15px;display:inline-block;cursor:pointer;font-size:12px}.layui-laydate-footer span:hover{color:#5FB878}.laydate-footer-btns{position:absolute;right:10px;top:10px}.laydate-footer-btns span{height:26px;line-height:26px;margin:0 0 0 -1px;padding:0 10px;border:1px solid #C9C9C9;background-color:#fff;white-space:nowrap;vertical-align:top;border-radius:2px}.layui-laydate-list>li,.layui-laydate-range .layui-laydate-main{display:inline-block;vertical-align:middle}.layui-laydate-list{position:absolute;left:0;top:0;width:100%;height:100%;padding:10px;background-color:#fff}.layui-laydate-list>li{position:relative;width:33.3%;height:36px;line-height:36px;margin:3px 0;text-align:center;cursor:pointer}.laydate-month-list>li{width:25%;margin:17px 0}.laydate-time-list>li{height:100%;margin:0;line-height:normal;cursor:default}.laydate-time-list p{position:relative;top:-4px;line-height:29px}.laydate-time-list ol{height:181px;overflow:hidden}.laydate-time-list>li:hover ol{overflow-y:auto}.laydate-time-list ol li{width:130%;padding-left:33px;line-height:30px;text-align:left;cursor:pointer}.layui-laydate-hint{position:absolute;top:115px;left:50%;width:250px;margin-left:-125px;line-height:20px;padding:15px;text-align:center;font-size:12px}.layui-laydate-range{width:546px}.layui-laydate-range .laydate-main-list-0 .laydate-next-m,.layui-laydate-range .laydate-main-list-0 .laydate-next-y,.layui-laydate-range .laydate-main-list-1 .laydate-prev-m,.layui-laydate-range .laydate-main-list-1 .laydate-prev-y{display:none}.layui-laydate-range .laydate-main-list-1 .layui-laydate-content{border-left:1px solid #e2e2e2}.layui-laydate,.layui-laydate-hint{border:1px solid #d2d2d2;box-shadow:0 2px 4px rgba(0,0,0,.12);background-color:#fff;color:#666}.layui-laydate-header{border-bottom:1px solid #e2e2e2}.layui-laydate-header i:hover,.layui-laydate-header span:hover{color:#5FB878}.layui-laydate-content{border-top:none 0;border-bottom:none 0}.layui-laydate-content th{font-weight:400;color:#333}.layui-laydate-content td{color:#666}.layui-laydate-content td.laydate-selected{background-color:#00F7DE}.laydate-selected:hover{background-color:#00F7DE!important}.layui-laydate-content td:hover,.layui-laydate-list li:hover{background-color:#eaeaea;color:#333}.laydate-time-list li ol{margin:0;padding:0;border:1px solid #e2e2e2;border-left-width:0}.laydate-time-list li:first-child ol{border-left-width:1px}.laydate-time-list>li:hover{background:0 0}.layui-laydate-content .laydate-day-next,.layui-laydate-content .laydate-day-prev{color:#d2d2d2}.laydate-selected.laydate-day-next,.laydate-selected.laydate-day-prev{background-color:#f8f8f8!important}.layui-laydate-footer{border-top:1px solid #e2e2e2}.layui-laydate-hint{color:#FF5722}.laydate-day-mark::after{background-color:#5FB878}.layui-laydate-content td.layui-this .laydate-day-mark::after{display:none}.layui-laydate-footer span[lay-type=date]{color:#5FB878}.layui-laydate .layui-this{background-color:#009688!important;color:#fff!important}.layui-laydate .laydate-disabled,.layui-laydate .laydate-disabled:hover{background:0 0!important;color:#d2d2d2!important;cursor:not-allowed!important;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none}.laydate-theme-molv{border:none}.laydate-theme-molv.layui-laydate-range{width:548px}.laydate-theme-molv .layui-laydate-main{width:274px}.laydate-theme-molv .layui-laydate-header{border:none;background-color:#009688}.laydate-theme-molv .layui-laydate-header i,.laydate-theme-molv .layui-laydate-header span{color:#f6f6f6}.laydate-theme-molv .layui-laydate-header i:hover,.laydate-theme-molv .layui-laydate-header span:hover{color:#fff}.laydate-theme-molv .layui-laydate-content{border:1px solid #e2e2e2;border-top:none;border-bottom:none}.laydate-theme-molv .laydate-main-list-1 .layui-laydate-content{border-left:none}.laydate-theme-grid .laydate-month-list>li,.laydate-theme-grid .laydate-year-list>li,.laydate-theme-grid .layui-laydate-content td,.laydate-theme-grid .layui-laydate-content thead,.laydate-theme-molv .layui-laydate-footer{border:1px solid #e2e2e2}.laydate-theme-grid .laydate-selected,.laydate-theme-grid .laydate-selected:hover{background-color:#f2f2f2!important;color:#009688!important}.laydate-theme-grid .laydate-selected.laydate-day-next,.laydate-theme-grid .laydate-selected.laydate-day-prev{color:#d2d2d2!important}.laydate-theme-grid .laydate-month-list,.laydate-theme-grid .laydate-year-list{margin:1px 0 0 1px}.laydate-theme-grid .laydate-month-list>li,.laydate-theme-grid .laydate-year-list>li{margin:0 -1px -1px 0}.laydate-theme-grid .laydate-year-list>li{height:43px;line-height:43px}.laydate-theme-grid .laydate-month-list>li{height:71px;line-height:71px}@font-face{font-family:laydate-icon;src:url(font/iconfont.eot);src:url(font/iconfont.eot#iefix) format('embedded-opentype'),url(font/iconfont.svg#iconfont) format('svg'),url(font/iconfont.woff) format('woff'),url(font/iconfont.ttf) format('truetype')}.laydate-icon{font-family:laydate-icon!important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}
\ No newline at end of file
/*!
@Name:layer v2.4 弹层组件
@Author:贤心
@Site:http://layer.layui.com
@License:LGPL
*/
;!function(window, undefined){
"use strict";
var $, win, ready = {
getPath: function(){
var js = document.scripts, script = js[js.length - 1], jsPath = script.src;
if(script.getAttribute('merge')) return;
return jsPath.substring(0, jsPath.lastIndexOf("/") + 1);
}(),
//屏蔽Enter触发弹层
enter: function(e){
if(e.keyCode === 13) e.preventDefault();
},
config: {}, end: {},
btn: ['&#x786E;&#x5B9A;','&#x53D6;&#x6D88;'],
//五种原始层模式
type: ['dialog', 'page', 'iframe', 'loading', 'tips']
};
//默认内置方法。
var layer = {
v: '2.4',
ie6: !!window.ActiveXObject&&!window.XMLHttpRequest,
index: (window.layer && window.layer.v) ? 100000 : 0,
path: ready.getPath,
config: function(options, fn){
var item = 0;
options = options || {};
layer.cache = ready.config = $.extend(ready.config, options);
layer.path = ready.config.path || layer.path;
typeof options.extend === 'string' && (options.extend = [options.extend]);
layer.use('skin/layer.css', (options.extend && options.extend.length > 0) ? (function loop(){
var ext = options.extend;
layer.use(ext[ext[item] ? item : item-1], item < ext.length ? function(){
++item;
return loop;
}() : fn);
}()) : fn);
return this;
},
//载入配件
use: function(module, fn, readyMethod){
var i = 0, head = $('head')[0];
var module = module.replace(/\s/g, '');
var iscss = /\.css$/.test(module);
var node = document.createElement(iscss ? 'link' : 'script');
var id = 'layui_layer_' + module.replace(/\.|\//g, '');
if(!layer.path) return;
if(iscss){
node.rel = 'stylesheet';
}
node[iscss ? 'href' : 'src'] = /^http:\/\//.test(module) ? module : layer.path + module;
node.id = id;
if(!$('#'+ id)[0]){
head.appendChild(node);
}
//轮询加载就绪
;(function poll() {
;(iscss ? parseInt($('#'+id).css('width')) === 1989 : layer[readyMethod||id]) ? function(){
fn && fn();
try { iscss || head.removeChild(node); } catch(e){};
}() : setTimeout(poll, 100);
}());
return this;
},
ready: function(path, fn){
var type = typeof path === 'function';
if(type) fn = path;
layer.config($.extend(ready.config, function(){
return type ? {} : {path: path};
}()), fn);
return this;
},
//各种快捷引用
alert: function(content, options, yes){
var type = typeof options === 'function';
if(type) yes = options;
return layer.open($.extend({
content: content,
yes: yes
}, type ? {} : options));
},
confirm: function(content, options, yes, cancel){
var type = typeof options === 'function';
if(type){
cancel = yes;
yes = options;
}
return layer.open($.extend({
content: content,
btn: ready.btn,
yes: yes,
btn2: cancel
}, type ? {} : options));
},
msg: function(content, options, end){ //最常用提示层
var type = typeof options === 'function', rskin = ready.config.skin;
var skin = (rskin ? rskin + ' ' + rskin + '-msg' : '')||'layui-layer-msg';
var shift = doms.anim.length - 1;
if(type) end = options;
return layer.open($.extend({
content: content,
time: 3000,
shade: false,
skin: skin,
title: false,
closeBtn: false,
btn: false,
end: end
}, (type && !ready.config.skin) ? {
skin: skin + ' layui-layer-hui',
shift: shift
} : function(){
options = options || {};
if(options.icon === -1 || options.icon === undefined && !ready.config.skin){
options.skin = skin + ' ' + (options.skin||'layui-layer-hui');
}
return options;
}()));
},
load: function(icon, options){
return layer.open($.extend({
type: 3,
icon: icon || 0,
shade: 0.01
}, options));
},
tips: function(content, follow, options){
return layer.open($.extend({
type: 4,
content: [content, follow],
closeBtn: false,
time: 3000,
shade: false,
fix: false,
maxWidth: 210
}, options));
}
};
var Class = function(setings){
var that = this;
that.index = ++layer.index;
that.config = $.extend({}, that.config, ready.config, setings);
that.creat();
};
Class.pt = Class.prototype;
//缓存常用字符
var doms = ['layui-layer', '.layui-layer-title', '.layui-layer-main', '.layui-layer-dialog', 'layui-layer-iframe', 'layui-layer-content', 'layui-layer-btn', 'layui-layer-close'];
doms.anim = ['layer-anim', 'layer-anim-01', 'layer-anim-02', 'layer-anim-03', 'layer-anim-04', 'layer-anim-05', 'layer-anim-06'];
//默认配置
Class.pt.config = {
type: 0,
shade: 0.3,
fix: true,
move: doms[1],
title: '&#x4FE1;&#x606F;',
offset: 'auto',
area: 'auto',
closeBtn: 1,
time: 0, //0表示不自动关闭
zIndex: 19891014,
maxWidth: 360,
shift: 0,
icon: -1,
scrollbar: true, //是否允许浏览器滚动条
tips: 2
};
//容器
Class.pt.vessel = function(conType, callback){
var that = this, times = that.index, config = that.config;
var zIndex = config.zIndex + times, titype = typeof config.title === 'object';
var ismax = config.maxmin && (config.type === 1 || config.type === 2);
var titleHTML = (config.title ? '<div class="layui-layer-title" style="'+ (titype ? config.title[1] : '') +'">'
+ (titype ? config.title[0] : config.title)
+ '</div>' : '');
config.zIndex = zIndex;
callback([
//遮罩
config.shade ? ('<div class="layui-layer-shade" id="layui-layer-shade'+ times +'" times="'+ times +'" style="'+ ('z-index:'+ (zIndex-1) +'; background-color:'+ (config.shade[1]||'#000') +'; opacity:'+ (config.shade[0]||config.shade) +'; filter:alpha(opacity='+ (config.shade[0]*100||config.shade*100) +');') +'"></div>') : '',
//主体
'<div class="'+ doms[0] + (' layui-layer-'+ready.type[config.type]) + (((config.type == 0 || config.type == 2) && !config.shade) ? ' layui-layer-border' : '') + ' ' + (config.skin||'') +'" id="'+ doms[0] + times +'" type="'+ ready.type[config.type] +'" times="'+ times +'" showtime="'+ config.time +'" conType="'+ (conType ? 'object' : 'string') +'" style="z-index: '+ zIndex +'; width:'+ config.area[0] + ';height:' + config.area[1] + (config.fix ? '' : ';position:absolute;') +'">'
+ (conType && config.type != 2 ? '' : titleHTML)
+'<div id="'+ (config.id||'') +'" class="layui-layer-content'+ ((config.type == 0 && config.icon !== -1) ? ' layui-layer-padding' :'') + (config.type == 3 ? ' layui-layer-loading'+config.icon : '') +'">'
+ (config.type == 0 && config.icon !== -1 ? '<i class="layui-layer-ico layui-layer-ico'+ config.icon +'"></i>' : '')
+ (config.type == 1 && conType ? '' : (config.content||''))
+'</div>'
+ '<span class="layui-layer-setwin">'+ function(){
var closebtn = ismax ? '<a class="layui-layer-min" href="javascript:;"><cite></cite></a><a class="layui-layer-ico layui-layer-max" href="javascript:;"></a>' : '';
config.closeBtn && (closebtn += '<a class="layui-layer-ico '+ doms[7] +' '+ doms[7] + (config.title ? config.closeBtn : (config.type == 4 ? '1' : '2')) +'" href="javascript:;"></a>');
return closebtn;
}() + '</span>'
+ (config.btn ? function(){
var button = '';
typeof config.btn === 'string' && (config.btn = [config.btn]);
for(var i = 0, len = config.btn.length; i < len; i++){
button += '<a class="'+ doms[6] +''+ i +'">'+ config.btn[i] +'</a>'
}
return '<div class="'+ doms[6] +'">'+ button +'</div>'
}() : '')
+'</div>'
], titleHTML);
return that;
};
//创建骨架
Class.pt.creat = function(){
var that = this, config = that.config, times = that.index, nodeIndex;
var content = config.content, conType = typeof content === 'object';
if($('#'+config.id)[0]) return;
if(typeof config.area === 'string'){
config.area = config.area === 'auto' ? ['', ''] : [config.area, ''];
}
switch(config.type){
case 0:
config.btn = ('btn' in config) ? config.btn : ready.btn[0];
layer.closeAll('dialog');
break;
case 2:
var content = config.content = conType ? config.content : [config.content||'http://layer.layui.com', 'auto'];
config.content = '<iframe scrolling="'+ (config.content[1]||'auto') +'" allowtransparency="true" id="'+ doms[4] +''+ times +'" name="'+ doms[4] +''+ times +'" onload="this.className=\'\';" class="layui-layer-load" frameborder="0" src="' + config.content[0] + '"></iframe>';
break;
case 3:
config.title = false;
config.closeBtn = false;
config.icon === -1 && (config.icon === 0);
layer.closeAll('loading');
break;
case 4:
conType || (config.content = [config.content, 'body']);
config.follow = config.content[1];
config.content = config.content[0] + '<i class="layui-layer-TipsG"></i>';
config.title = false;
config.tips = typeof config.tips === 'object' ? config.tips : [config.tips, true];
config.tipsMore || layer.closeAll('tips');
break;
}
//建立容器
that.vessel(conType, function(html, titleHTML){
$('body').append(html[0]);
conType ? function(){
(config.type == 2 || config.type == 4) ? function(){
$('body').append(html[1]);
}() : function(){
if(!content.parents('.'+doms[0])[0]){
content.show().addClass('layui-layer-wrap').wrap(html[1]);
$('#'+ doms[0] + times).find('.'+doms[5]).before(titleHTML);
}
}();
}() : $('body').append(html[1]);
that.layero = $('#'+ doms[0] + times);
config.scrollbar || doms.html.css('overflow', 'hidden').attr('layer-full', times);
}).auto(times);
config.type == 2 && layer.ie6 && that.layero.find('iframe').attr('src', content[0]);
$(document).off('keydown', ready.enter).on('keydown', ready.enter);
that.layero.on('keydown', function(e){
$(document).off('keydown', ready.enter);
});
if (config.type == 2) {
that.layero.find("iframe")[0].api = that;
}
//坐标自适应浏览器窗口尺寸
config.type == 4 ? that.tips() : that.offset();
if(config.fix){
win.on('resize', function(){
that.offset();
(/^\d+%$/.test(config.area[0]) || /^\d+%$/.test(config.area[1])) && that.auto(times);
config.type == 4 && that.tips();
});
}
config.time <= 0 || setTimeout(function(){
layer.close(that.index)
}, config.time);
that.move().callback();
//为兼容jQuery3.0的css动画影响元素尺寸计算
if(doms.anim[config.shift]){
that.layero.addClass(doms.anim[config.shift]);
};
};
//自适应
Class.pt.auto = function(index){
var that = this, config = that.config, layero = $('#'+ doms[0] + index);
if(config.area[0] === '' && config.maxWidth > 0){
//为了修复IE7下一个让人难以理解的bug
if(/MSIE 7/.test(navigator.userAgent) && config.btn){
layero.width(layero.innerWidth());
}
layero.outerWidth() > config.maxWidth && layero.width(config.maxWidth);
}
var area = [layero.innerWidth(), layero.innerHeight()];
var titHeight = layero.find(doms[1]).outerHeight() || 0;
var btnHeight = layero.find('.'+doms[6]).outerHeight() || 0;
function setHeight(elem){
elem = layero.find(elem);
elem.height(area[1] - titHeight - btnHeight - 2*(parseFloat(elem.css('padding'))|0));
}
switch(config.type){
case 2:
setHeight('iframe');
break;
default:
if(config.area[1] === ''){
if(config.fix && area[1] >= win.height()){
area[1] = win.height();
setHeight('.'+doms[5]);
}
} else {
setHeight('.'+doms[5]);
}
break;
}
return that;
};
//计算坐标
Class.pt.offset = function(){
var that = this, config = that.config, layero = that.layero;
var area = [layero.outerWidth(), layero.outerHeight()];
var type = typeof config.offset === 'object';
that.offsetTop = (win.height() - area[1])/2;
that.offsetLeft = (win.width() - area[0])/2;
if(type){
that.offsetTop = config.offset[0];
that.offsetLeft = config.offset[1]||that.offsetLeft;
} else if(config.offset !== 'auto'){
that.offsetTop = config.offset;
if(config.offset === 'rb'){ //右下角
that.offsetTop = win.height() - area[1];
that.offsetLeft = win.width() - area[0];
}
}
if(!config.fix){
that.offsetTop = /%$/.test(that.offsetTop) ?
win.height()*parseFloat(that.offsetTop)/100
: parseFloat(that.offsetTop);
that.offsetLeft = /%$/.test(that.offsetLeft) ?
win.width()*parseFloat(that.offsetLeft)/100
: parseFloat(that.offsetLeft);
that.offsetTop += win.scrollTop();
that.offsetLeft += win.scrollLeft();
}
layero.css({top: that.offsetTop, left: that.offsetLeft});
};
//Tips
Class.pt.tips = function(){
var that = this, config = that.config, layero = that.layero;
var layArea = [layero.outerWidth(), layero.outerHeight()], follow = $(config.follow);
if(!follow[0]) follow = $('body');
var goal = {
width: follow.outerWidth(),
height: follow.outerHeight(),
top: follow.offset().top,
left: follow.offset().left
}, tipsG = layero.find('.layui-layer-TipsG');
var guide = config.tips[0];
config.tips[1] || tipsG.remove();
goal.autoLeft = function(){
if(goal.left + layArea[0] - win.width() > 0){
goal.tipLeft = goal.left + goal.width - layArea[0];
tipsG.css({right: 12, left: 'auto'});
} else {
goal.tipLeft = goal.left;
};
};
//辨别tips的方位
goal.where = [function(){ //上
goal.autoLeft();
goal.tipTop = goal.top - layArea[1] - 10;
tipsG.removeClass('layui-layer-TipsB').addClass('layui-layer-TipsT').css('border-right-color', config.tips[1]);
}, function(){ //右
goal.tipLeft = goal.left + goal.width + 10;
goal.tipTop = goal.top;
tipsG.removeClass('layui-layer-TipsL').addClass('layui-layer-TipsR').css('border-bottom-color', config.tips[1]);
}, function(){ //下
goal.autoLeft();
goal.tipTop = goal.top + goal.height + 10;
tipsG.removeClass('layui-layer-TipsT').addClass('layui-layer-TipsB').css('border-right-color', config.tips[1]);
}, function(){ //左
goal.tipLeft = goal.left - layArea[0] - 10;
goal.tipTop = goal.top;
tipsG.removeClass('layui-layer-TipsR').addClass('layui-layer-TipsL').css('border-bottom-color', config.tips[1]);
}];
goal.where[guide-1]();
/* 8*2为小三角形占据的空间 */
if(guide === 1){
goal.top - (win.scrollTop() + layArea[1] + 8*2) < 0 && goal.where[2]();
} else if(guide === 2){
win.width() - (goal.left + goal.width + layArea[0] + 8*2) > 0 || goal.where[3]()
} else if(guide === 3){
(goal.top - win.scrollTop() + goal.height + layArea[1] + 8*2) - win.height() > 0 && goal.where[0]();
} else if(guide === 4){
layArea[0] + 8*2 - goal.left > 0 && goal.where[1]()
}
layero.find('.'+doms[5]).css({
'background-color': config.tips[1],
'padding-right': (config.closeBtn ? '30px' : '')
});
layero.css({
left: goal.tipLeft - (config.fix ? win.scrollLeft() : 0),
top: goal.tipTop - (config.fix ? win.scrollTop() : 0)
});
}
//拖拽层
Class.pt.move = function(){
var that = this, config = that.config, conf = {
setY: 0,
moveLayer: function(){
var layero = conf.layero, mgleft = parseInt(layero.css('margin-left'));
var lefts = parseInt(conf.move.css('left'));
mgleft === 0 || (lefts = lefts - mgleft);
if(layero.css('position') !== 'fixed'){
lefts = lefts - layero.parent().offset().left;
conf.setY = 0;
}
layero.css({left: lefts, top: parseInt(conf.move.css('top')) - conf.setY});
}
};
var movedom = that.layero.find(config.move);
config.move && movedom.attr('move', 'ok');
movedom.css({cursor: config.move ? 'move' : 'auto'});
$(config.move).on('mousedown', function(M){
M.preventDefault();
if($(this).attr('move') === 'ok'){
conf.ismove = true;
conf.layero = $(this).parents('.'+ doms[0]);
var xx = conf.layero.offset().left, yy = conf.layero.offset().top, ww = conf.layero.outerWidth() - 6, hh = conf.layero.outerHeight() - 6;
if(!$('#layui-layer-moves')[0]){
$('body').append('<div id="layui-layer-moves" class="layui-layer-moves" style="left:'+ xx +'px; top:'+ yy +'px; width:'+ ww +'px; height:'+ hh +'px; z-index:2147483584"></div>');
}
conf.move = $('#layui-layer-moves');
config.moveType && conf.move.css({visibility: 'hidden'});
conf.moveX = M.pageX - conf.move.position().left;
conf.moveY = M.pageY - conf.move.position().top;
conf.layero.css('position') !== 'fixed' || (conf.setY = win.scrollTop());
}
});
$(document).mousemove(function(M){
if(conf.ismove){
var offsetX = M.pageX - conf.moveX, offsetY = M.pageY - conf.moveY;
M.preventDefault();
//控制元素不被拖出窗口外
if(!config.moveOut){
conf.setY = win.scrollTop();
var setRig = win.width() - conf.move.outerWidth(), setTop = conf.setY;
offsetX < 0 && (offsetX = 0);
offsetX > setRig && (offsetX = setRig);
offsetY < setTop && (offsetY = setTop);
offsetY > win.height() - conf.move.outerHeight() + conf.setY && (offsetY = win.height() - conf.move.outerHeight() + conf.setY);
}
conf.move.css({left: offsetX, top: offsetY});
config.moveType && conf.moveLayer();
offsetX = offsetY = setRig = setTop = null;
}
}).mouseup(function(){
try{
if(conf.ismove){
conf.moveLayer();
conf.move.remove();
config.moveEnd && config.moveEnd();
}
conf.ismove = false;
}catch(e){
conf.ismove = false;
}
});
return that;
};
Class.pt.callback = function(){
var that = this, layero = that.layero, config = that.config;
that.openLayer();
if(config.success){
if(config.type == 2){
layero.find('iframe').on('load', function(){
config.success(layero, that.index);
});
} else {
config.success(layero, that.index);
}
}
layer.ie6 && that.IE6(layero);
//按钮
layero.find('.'+ doms[6]).children('a').on('click', function(){
var index = $(this).index();
if(index === 0){
if(config.yes){
config.yes(that.index, layero)
} else if(config['btn1']){
config['btn1'](that.index, layero)
} else {
layer.close(that.index);
}
} else {
var close = config['btn'+(index+1)] && config['btn'+(index+1)](that.index, layero);
close === false || layer.close(that.index);
}
});
//取消
function cancel(){
var close = config.cancel && config.cancel(that.index, layero);
close === false || layer.close(that.index);
}
//右上角关闭回调
layero.find('.'+ doms[7]).on('click', cancel);
//点遮罩关闭
if(config.shadeClose){
$('#layui-layer-shade'+ that.index).on('click', function(){
layer.close(that.index);
});
}
//最小化
layero.find('.layui-layer-min').on('click', function(){
var min = config.min && config.min(layero);
min === false || layer.min(that.index, config);
});
//全屏/还原
layero.find('.layui-layer-max').on('click', function(){
if($(this).hasClass('layui-layer-maxmin')){
layer.restore(that.index);
config.restore && config.restore(layero);
} else {
layer.full(that.index, config);
setTimeout(function(){
config.full && config.full(layero);
}, 100);
}
});
config.end && (ready.end[that.index] = config.end);
};
//for ie6 恢复select
ready.reselect = function(){
$.each($('select'), function(index , value){
var sthis = $(this);
if(!sthis.parents('.'+doms[0])[0]){
(sthis.attr('layer') == 1 && $('.'+doms[0]).length < 1) && sthis.removeAttr('layer').show();
}
sthis = null;
});
};
Class.pt.IE6 = function(layero){
var that = this, _ieTop = layero.offset().top;
//ie6的固定与相对定位
function ie6Fix(){
layero.css({top : _ieTop + (that.config.fix ? win.scrollTop() : 0)});
};
ie6Fix();
win.scroll(ie6Fix);
//隐藏select
$('select').each(function(index , value){
var sthis = $(this);
if(!sthis.parents('.'+doms[0])[0]){
sthis.css('display') === 'none' || sthis.attr({'layer' : '1'}).hide();
}
sthis = null;
});
};
//需依赖原型的对外方法
Class.pt.openLayer = function(){
var that = this;
//置顶当前窗口
layer.zIndex = that.config.zIndex;
layer.setTop = function(layero){
var setZindex = function(){
layer.zIndex++;
layero.css('z-index', layer.zIndex + 1);
};
layer.zIndex = parseInt(layero[0].style.zIndex);
layero.on('mousedown', setZindex);
return layer.zIndex;
};
};
ready.record = function(layero){
var area = [
layero.width(),
layero.height(),
layero.position().top,
layero.position().left + parseFloat(layero.css('margin-left'))
];
layero.find('.layui-layer-max').addClass('layui-layer-maxmin');
layero.attr({area: area});
};
ready.rescollbar = function(index){
if(doms.html.attr('layer-full') == index){
if(doms.html[0].style.removeProperty){
doms.html[0].style.removeProperty('overflow');
} else {
doms.html[0].style.removeAttribute('overflow');
}
doms.html.removeAttr('layer-full');
}
};
/** 内置成员 */
window.layer = layer;
//获取子iframe的DOM
layer.getChildFrame = function(selector, index){
index = index || $('.'+doms[4]).attr('times');
return $('#'+ doms[0] + index).find('iframe').contents().find(selector);
};
//得到当前iframe层的索引,子iframe时使用
layer.getFrameIndex = function(name){
return $('#'+ name).parents('.'+doms[4]).attr('times');
};
//iframe层自适应宽高
layer.iframeAuto = function(index){
if(!index) return;
var heg = layer.getChildFrame('html', index).outerHeight();
var layero = $('#'+ doms[0] + index);
var titHeight = layero.find(doms[1]).outerHeight() || 0;
var btnHeight = layero.find('.'+doms[6]).outerHeight() || 0;
layero.css({height: heg + titHeight + btnHeight});
layero.find('iframe').css({height: heg});
};
//重置iframe url
layer.iframeSrc = function(index, url){
$('#'+ doms[0] + index).find('iframe').attr('src', url);
};
//设定层的样式
layer.style = function(index, options){
var layero = $('#'+ doms[0] + index), type = layero.attr('type');
var titHeight = layero.find(doms[1]).outerHeight() || 0;
var btnHeight = layero.find('.'+doms[6]).outerHeight() || 0;
if(type === ready.type[1] || type === ready.type[2]){
layero.css(options);
if(type === ready.type[2]){
layero.find('iframe').css({
height: parseFloat(options.height) - titHeight - btnHeight
});
}
}
};
//最小化
layer.min = function(index, options){
var layero = $('#'+ doms[0] + index);
var titHeight = layero.find(doms[1]).outerHeight() || 0;
ready.record(layero);
layer.style(index, {width: 180, height: titHeight, overflow: 'hidden'});
layero.find('.layui-layer-min').hide();
layero.attr('type') === 'page' && layero.find(doms[4]).hide();
ready.rescollbar(index);
};
//还原
layer.restore = function(index){
var layero = $('#'+ doms[0] + index), area = layero.attr('area').split(',');
var type = layero.attr('type');
layer.style(index, {
width: parseFloat(area[0]),
height: parseFloat(area[1]),
top: parseFloat(area[2]),
left: parseFloat(area[3]),
overflow: 'visible'
});
layero.find('.layui-layer-max').removeClass('layui-layer-maxmin');
layero.find('.layui-layer-min').show();
layero.attr('type') === 'page' && layero.find(doms[4]).show();
ready.rescollbar(index);
};
//全屏
layer.full = function(index){
var layero = $('#'+ doms[0] + index), timer;
ready.record(layero);
if(!doms.html.attr('layer-full')){
doms.html.css('overflow','hidden').attr('layer-full', index);
}
clearTimeout(timer);
timer = setTimeout(function(){
var isfix = layero.css('position') === 'fixed';
layer.style(index, {
top: isfix ? 0 : win.scrollTop(),
left: isfix ? 0 : win.scrollLeft(),
width: win.width(),
height: win.height()
});
layero.find('.layui-layer-min').hide();
}, 100);
};
//改变title
layer.title = function(name, index){
var title = $('#'+ doms[0] + (index||layer.index)).find(doms[1]);
title.html(name);
};
//关闭layer总方法
layer.close = function(index){
var layero = $('#'+ doms[0] + index), type = layero.attr('type');
if(!layero[0]) return;
if(type === ready.type[1] && layero.attr('conType') === 'object'){
layero.children(':not(.'+ doms[5] +')').remove();
for(var i = 0; i < 2; i++){
layero.find('.layui-layer-wrap').unwrap().hide();
}
} else {
//低版本IE 回收 iframe
if(type === ready.type[2]){
try {
var iframe = $('#'+doms[4]+index)[0];
iframe.contentWindow.document.write('');
iframe.contentWindow.close();
layero.find('.'+doms[5])[0].removeChild(iframe);
} catch(e){}
}
layero[0].innerHTML = '';
layero.remove();
}
$('#layui-layer-moves, #layui-layer-shade' + index).remove();
layer.ie6 && ready.reselect();
ready.rescollbar(index);
$(document).off('keydown', ready.enter);
typeof ready.end[index] === 'function' && ready.end[index]();
delete ready.end[index];
};
//关闭所有层
layer.closeAll = function(type){
$.each($('.'+doms[0]), function(){
var othis = $(this);
var is = type ? (othis.attr('type') === type) : 1;
is && layer.close(othis.attr('times'));
is = null;
});
};
/**
拓展模块,layui开始合并在一起
*/
var cache = layer.cache||{}, skin = function(type){
return (cache.skin ? (' ' + cache.skin + ' ' + cache.skin + '-'+type) : '');
};
//仿系统prompt
layer.prompt = function(options, yes){
options = options || {};
if(typeof options === 'function') yes = options;
var prompt, content = options.formType == 2 ? '<textarea class="layui-layer-input">'+ (options.value||'') +'</textarea>' : function(){
return '<input type="'+ (options.formType == 1 ? 'password' : 'text') +'" class="layui-layer-input" value="'+ (options.value||'') +'">';
}();
return layer.open($.extend({
btn: ['&#x786E;&#x5B9A;','&#x53D6;&#x6D88;'],
content: content,
skin: 'layui-layer-prompt' + skin('prompt'),
success: function(layero){
prompt = layero.find('.layui-layer-input');
prompt.focus();
}, yes: function(index){
var value = prompt.val();
if(value === ''){
prompt.focus();
} else if(value.length > (options.maxlength||500)) {
layer.tips('&#x6700;&#x591A;&#x8F93;&#x5165;'+ (options.maxlength || 500) +'&#x4E2A;&#x5B57;&#x6570;', prompt, {tips: 1});
} else {
yes && yes(value, index, prompt);
}
}
}, options));
};
//tab层
layer.tab = function(options){
options = options || {};
var tab = options.tab || {};
return layer.open($.extend({
type: 1,
skin: 'layui-layer-tab' + skin('tab'),
title: function(){
var len = tab.length, ii = 1, str = '';
if(len > 0){
str = '<span class="layui-layer-tabnow">'+ tab[0].title +'</span>';
for(; ii < len; ii++){
str += '<span>'+ tab[ii].title +'</span>';
}
}
return str;
}(),
content: '<ul class="layui-layer-tabmain">'+ function(){
var len = tab.length, ii = 1, str = '';
if(len > 0){
str = '<li class="layui-layer-tabli xubox_tab_layer">'+ (tab[0].content || 'no content') +'</li>';
for(; ii < len; ii++){
str += '<li class="layui-layer-tabli">'+ (tab[ii].content || 'no content') +'</li>';
}
}
return str;
}() +'</ul>',
success: function(layero){
var btn = layero.find('.layui-layer-title').children();
var main = layero.find('.layui-layer-tabmain').children();
btn.on('mousedown', function(e){
e.stopPropagation ? e.stopPropagation() : e.cancelBubble = true;
var othis = $(this), index = othis.index();
othis.addClass('layui-layer-tabnow').siblings().removeClass('layui-layer-tabnow');
main.eq(index).show().siblings().hide();
typeof options.change === 'function' && options.change(index);
});
}
}, options));
};
//相册层
layer.photos = function(options, loop, key){
var dict = {};
options = options || {};
if(!options.photos) return;
var type = options.photos.constructor === Object;
var photos = type ? options.photos : {}, data = photos.data || [];
var start = photos.start || 0;
dict.imgIndex = (start|0) + 1;
options.img = options.img || 'img';
if(!type){ //页面直接获取
var parent = $(options.photos), pushData = function(){
data = [];
parent.find(options.img).each(function(index){
var othis = $(this);
othis.attr('layer-index', index);
data.push({
alt: othis.attr('alt'),
pid: othis.attr('layer-pid'),
src: othis.attr('layer-src') || othis.attr('src'),
thumb: othis.attr('src')
});
})
};
pushData();
if (data.length === 0) return;
loop || parent.on('click', options.img, function(){
var othis = $(this), index = othis.attr('layer-index');
layer.photos($.extend(options, {
photos: {
start: index,
data: data,
tab: options.tab
},
full: options.full
}), true);
pushData();
})
//不直接弹出
if(!loop) return;
} else if (data.length === 0){
return layer.msg('&#x6CA1;&#x6709;&#x56FE;&#x7247;');
}
//上一张
dict.imgprev = function(key){
dict.imgIndex--;
if(dict.imgIndex < 1){
dict.imgIndex = data.length;
}
dict.tabimg(key);
};
//下一张
dict.imgnext = function(key,errorMsg){
dict.imgIndex++;
if(dict.imgIndex > data.length){
dict.imgIndex = 1;
if (errorMsg) {return};
}
dict.tabimg(key)
};
//方向键
dict.keyup = function(event){
if(!dict.end){
var code = event.keyCode;
event.preventDefault();
if(code === 37){
dict.imgprev(true);
} else if(code === 39) {
dict.imgnext(true);
} else if(code === 27) {
layer.close(dict.index);
}
}
}
//切换
dict.tabimg = function(key){
if(data.length <= 1) return;
photos.start = dict.imgIndex - 1;
layer.close(dict.index);
layer.photos(options, true, key);
}
//一些动作
dict.event = function(){
dict.bigimg.hover(function(){
dict.imgsee.show();
}, function(){
dict.imgsee.hide();
});
dict.bigimg.find('.layui-layer-imgprev').on('click', function(event){
event.preventDefault();
dict.imgprev();
});
dict.bigimg.find('.layui-layer-imgnext').on('click', function(event){
event.preventDefault();
dict.imgnext();
});
$(document).on('keyup', dict.keyup);
};
//图片预加载
function loadImage(url, callback, error) {
var img = new Image();
img.src = url;
if(img.complete){
return callback(img);
}
img.onload = function(){
img.onload = null;
callback(img);
};
img.onerror = function(e){
img.onerror = null;
error(e);
};
};
dict.loadi = layer.load(1, {
shade: 'shade' in options ? false : 0.9,
scrollbar: false
});
loadImage(data[start].src, function(img){
layer.close(dict.loadi);
dict.index = layer.open($.extend({
type: 1,
area: function(){
var imgarea = [img.width, img.height];
var winarea = [$(window).width() - 50, $(window).height() - 50];
if(!options.full && imgarea[0] > winarea[0]){
imgarea[0] = winarea[0];
imgarea[1] = imgarea[0]*img.height/img.width;
}
return [imgarea[0]+'px', imgarea[1]+'px'];
}(),
title: false,
shade: 0.9,
shadeClose: true,
closeBtn: false,
move: '.layui-layer-phimg img',
moveType: 1,
scrollbar: false,
moveOut: true,
shift: Math.random()*5|0,
skin: 'layui-layer-photos' + skin('photos'),
content: '<div class="layui-layer-phimg">'
+'<img src="'+ data[start].src +'" alt="'+ (data[start].alt||'') +'" layer-pid="'+ data[start].pid +'">'
+'<div class="layui-layer-imgsee">'
+(data.length > 1 ? '<span class="layui-layer-imguide"><a href="javascript:;" class="layui-layer-iconext layui-layer-imgprev"></a><a href="javascript:;" class="layui-layer-iconext layui-layer-imgnext"></a></span>' : '')
+'<div class="layui-layer-imgbar" style="display:'+ (key ? 'block' : '') +'"><span class="layui-layer-imgtit"><a href="javascript:;">'+ (data[start].alt||'') +'</a><em>'+ dict.imgIndex +'/'+ data.length +'</em></span></div>'
+'</div>'
+'</div>',
success: function(layero, index){
dict.bigimg = layero.find('.layui-layer-phimg');
dict.imgsee = layero.find('.layui-layer-imguide,.layui-layer-imgbar');
dict.event(layero);
options.tab && options.tab(data[start], layero);
}, end: function(){
dict.end = true;
$(document).off('keyup', dict.keyup);
}
}, options));
}, function(){
layer.close(dict.loadi);
layer.msg('&#x5F53;&#x524D;&#x56FE;&#x7247;&#x5730;&#x5740;&#x5F02;&#x5E38;<br>&#x662F;&#x5426;&#x7EE7;&#x7EED;&#x67E5;&#x770B;&#x4E0B;&#x4E00;&#x5F20;&#xFF1F;', {
time: 30000,
btn: ['&#x4E0B;&#x4E00;&#x5F20;', '&#x4E0D;&#x770B;&#x4E86;'],
yes: function(){
data.length > 1 && dict.imgnext(true,true);
}
});
});
};
//主入口
ready.run = function(){
$ = jQuery;
win = $(window);
doms.html = $('html');
layer.open = function(deliver){
var o = new Class(deliver);
return o.index;
};
};
'function' === typeof define ? define(function(){
ready.run();
return layer;
}) : function(){
ready.run();
layer.use('skin/layer.css');
}();
}(window);
\ No newline at end of file
/*! layer-v2.4.0 Web弹层组件 LGPL License http://layer.layui.com/ By 贤心 */
;!function(e,t){"use strict";var i,n,a={getPath:function(){var e=document.scripts,t=e[e.length-1],i=t.src;if(!t.getAttribute("merge"))return i.substring(0,i.lastIndexOf("/")+1)}(),enter:function(e){13===e.keyCode&&e.preventDefault()},config:{},end:{},btn:["&#x786E;&#x5B9A;","&#x53D6;&#x6D88;"],type:["dialog","page","iframe","loading","tips"]},o={v:"2.4",ie6:!!e.ActiveXObject&&!e.XMLHttpRequest,index:e.layer&&e.layer.v?1e5:0,path:a.getPath,config:function(e,t){var n=0;return e=e||{},o.cache=a.config=i.extend(a.config,e),o.path=a.config.path||o.path,"string"==typeof e.extend&&(e.extend=[e.extend]),o.use("skin/layer.css",e.extend&&e.extend.length>0?function r(){var i=e.extend;o.use(i[i[n]?n:n-1],n<i.length?function(){return++n,r}():t)}():t),this},use:function(e,t,n){var a=i("head")[0],e=e.replace(/\s/g,""),r=/\.css$/.test(e),l=document.createElement(r?"link":"script"),s="layui_layer_"+e.replace(/\.|\//g,"");if(o.path)return r&&(l.rel="stylesheet"),l[r?"href":"src"]=/^http:\/\//.test(e)?e:o.path+e,l.id=s,i("#"+s)[0]||a.appendChild(l),function c(){(r?1989===parseInt(i("#"+s).css("width")):o[n||s])?function(){t&&t();try{r||a.removeChild(l)}catch(e){}}():setTimeout(c,100)}(),this},ready:function(e,t){var n="function"==typeof e;return n&&(t=e),o.config(i.extend(a.config,function(){return n?{}:{path:e}}()),t),this},alert:function(e,t,n){var a="function"==typeof t;return a&&(n=t),o.open(i.extend({content:e,yes:n},a?{}:t))},confirm:function(e,t,n,r){var l="function"==typeof t;return l&&(r=n,n=t),o.open(i.extend({content:e,btn:a.btn,yes:n,btn2:r},l?{}:t))},msg:function(e,n,r){var s="function"==typeof n,c=a.config.skin,f=(c?c+" "+c+"-msg":"")||"layui-layer-msg",u=l.anim.length-1;return s&&(r=n),o.open(i.extend({content:e,time:3e3,shade:!1,skin:f,title:!1,closeBtn:!1,btn:!1,end:r},s&&!a.config.skin?{skin:f+" layui-layer-hui",shift:u}:function(){return n=n||{},(n.icon===-1||n.icon===t&&!a.config.skin)&&(n.skin=f+" "+(n.skin||"layui-layer-hui")),n}()))},load:function(e,t){return o.open(i.extend({type:3,icon:e||0,shade:.01},t))},tips:function(e,t,n){return o.open(i.extend({type:4,content:[e,t],closeBtn:!1,time:3e3,shade:!1,fix:!1,maxWidth:210},n))}},r=function(e){var t=this;t.index=++o.index,t.config=i.extend({},t.config,a.config,e),t.creat()};r.pt=r.prototype;var l=["layui-layer",".layui-layer-title",".layui-layer-main",".layui-layer-dialog","layui-layer-iframe","layui-layer-content","layui-layer-btn","layui-layer-close"];l.anim=["layer-anim","layer-anim-01","layer-anim-02","layer-anim-03","layer-anim-04","layer-anim-05","layer-anim-06"],r.pt.config={type:0,shade:.3,fix:!0,move:l[1],title:"&#x4FE1;&#x606F;",offset:"auto",area:"auto",closeBtn:1,time:0,zIndex:19891014,maxWidth:360,shift:0,icon:-1,scrollbar:!0,tips:2},r.pt.vessel=function(e,t){var i=this,n=i.index,o=i.config,r=o.zIndex+n,s="object"==typeof o.title,c=o.maxmin&&(1===o.type||2===o.type),f=o.title?'<div class="layui-layer-title" style="'+(s?o.title[1]:"")+'">'+(s?o.title[0]:o.title)+"</div>":"";return o.zIndex=r,t([o.shade?'<div class="layui-layer-shade" id="layui-layer-shade'+n+'" times="'+n+'" style="'+("z-index:"+(r-1)+"; background-color:"+(o.shade[1]||"#000")+"; opacity:"+(o.shade[0]||o.shade)+"; filter:alpha(opacity="+(100*o.shade[0]||100*o.shade)+");")+'"></div>':"",'<div class="'+l[0]+(" layui-layer-"+a.type[o.type])+(0!=o.type&&2!=o.type||o.shade?"":" layui-layer-border")+" "+(o.skin||"")+'" id="'+l[0]+n+'" type="'+a.type[o.type]+'" times="'+n+'" showtime="'+o.time+'" conType="'+(e?"object":"string")+'" style="z-index: '+r+"; width:"+o.area[0]+";height:"+o.area[1]+(o.fix?"":";position:absolute;")+'">'+(e&&2!=o.type?"":f)+'<div id="'+(o.id||"")+'" class="layui-layer-content'+(0==o.type&&o.icon!==-1?" layui-layer-padding":"")+(3==o.type?" layui-layer-loading"+o.icon:"")+'">'+(0==o.type&&o.icon!==-1?'<i class="layui-layer-ico layui-layer-ico'+o.icon+'"></i>':"")+(1==o.type&&e?"":o.content||"")+'</div><span class="layui-layer-setwin">'+function(){var e=c?'<a class="layui-layer-min" href="javascript:;"><cite></cite></a><a class="layui-layer-ico layui-layer-max" href="javascript:;"></a>':"";return o.closeBtn&&(e+='<a class="layui-layer-ico '+l[7]+" "+l[7]+(o.title?o.closeBtn:4==o.type?"1":"2")+'" href="javascript:;"></a>'),e}()+"</span>"+(o.btn?function(){var e="";"string"==typeof o.btn&&(o.btn=[o.btn]);for(var t=0,i=o.btn.length;t<i;t++)e+='<a class="'+l[6]+t+'">'+o.btn[t]+"</a>";return'<div class="'+l[6]+'">'+e+"</div>"}():"")+"</div>"],f),i},r.pt.creat=function(){var e=this,t=e.config,r=e.index,s=t.content,c="object"==typeof s;if(!i("#"+t.id)[0]){switch("string"==typeof t.area&&(t.area="auto"===t.area?["",""]:[t.area,""]),t.type){case 0:t.btn="btn"in t?t.btn:a.btn[0],o.closeAll("dialog");break;case 2:var s=t.content=c?t.content:[t.content||"http://layer.layui.com","auto"];t.content='<iframe scrolling="'+(t.content[1]||"auto")+'" allowtransparency="true" id="'+l[4]+r+'" name="'+l[4]+r+'" onload="this.className=\'\';" class="layui-layer-load" frameborder="0" src="'+t.content[0]+'"></iframe>';break;case 3:t.title=!1,t.closeBtn=!1,t.icon===-1&&0===t.icon,o.closeAll("loading");break;case 4:c||(t.content=[t.content,"body"]),t.follow=t.content[1],t.content=t.content[0]+'<i class="layui-layer-TipsG"></i>',t.title=!1,t.tips="object"==typeof t.tips?t.tips:[t.tips,!0],t.tipsMore||o.closeAll("tips")}e.vessel(c,function(n,a){i("body").append(n[0]),c?function(){2==t.type||4==t.type?function(){i("body").append(n[1])}():function(){s.parents("."+l[0])[0]||(s.show().addClass("layui-layer-wrap").wrap(n[1]),i("#"+l[0]+r).find("."+l[5]).before(a))}()}():i("body").append(n[1]),e.layero=i("#"+l[0]+r),t.scrollbar||l.html.css("overflow","hidden").attr("layer-full",r)}).auto(r),2==t.type&&o.ie6&&e.layero.find("iframe").attr("src",s[0]),i(document).off("keydown",a.enter).on("keydown",a.enter),e.layero.on("keydown",function(e){i(document).off("keydown",a.enter)}),4==t.type?e.tips():e.offset(),t.fix&&n.on("resize",function(){e.offset(),(/^\d+%$/.test(t.area[0])||/^\d+%$/.test(t.area[1]))&&e.auto(r),4==t.type&&e.tips()}),t.time<=0||setTimeout(function(){o.close(e.index)},t.time),e.move().callback(),l.anim[t.shift]&&e.layero.addClass(l.anim[t.shift])}},r.pt.auto=function(e){function t(e){e=r.find(e),e.height(s[1]-c-f-2*(0|parseFloat(e.css("padding"))))}var a=this,o=a.config,r=i("#"+l[0]+e);""===o.area[0]&&o.maxWidth>0&&(/MSIE 7/.test(navigator.userAgent)&&o.btn&&r.width(r.innerWidth()),r.outerWidth()>o.maxWidth&&r.width(o.maxWidth));var s=[r.innerWidth(),r.innerHeight()],c=r.find(l[1]).outerHeight()||0,f=r.find("."+l[6]).outerHeight()||0;switch(o.type){case 2:t("iframe");break;default:""===o.area[1]?o.fix&&s[1]>=n.height()&&(s[1]=n.height(),t("."+l[5])):t("."+l[5])}return a},r.pt.offset=function(){var e=this,t=e.config,i=e.layero,a=[i.outerWidth(),i.outerHeight()],o="object"==typeof t.offset;e.offsetTop=(n.height()-a[1])/2,e.offsetLeft=(n.width()-a[0])/2,o?(e.offsetTop=t.offset[0],e.offsetLeft=t.offset[1]||e.offsetLeft):"auto"!==t.offset&&(e.offsetTop=t.offset,"rb"===t.offset&&(e.offsetTop=n.height()-a[1],e.offsetLeft=n.width()-a[0])),t.fix||(e.offsetTop=/%$/.test(e.offsetTop)?n.height()*parseFloat(e.offsetTop)/100:parseFloat(e.offsetTop),e.offsetLeft=/%$/.test(e.offsetLeft)?n.width()*parseFloat(e.offsetLeft)/100:parseFloat(e.offsetLeft),e.offsetTop+=n.scrollTop(),e.offsetLeft+=n.scrollLeft()),i.css({top:e.offsetTop,left:e.offsetLeft})},r.pt.tips=function(){var e=this,t=e.config,a=e.layero,o=[a.outerWidth(),a.outerHeight()],r=i(t.follow);r[0]||(r=i("body"));var s={width:r.outerWidth(),height:r.outerHeight(),top:r.offset().top,left:r.offset().left},c=a.find(".layui-layer-TipsG"),f=t.tips[0];t.tips[1]||c.remove(),s.autoLeft=function(){s.left+o[0]-n.width()>0?(s.tipLeft=s.left+s.width-o[0],c.css({right:12,left:"auto"})):s.tipLeft=s.left},s.where=[function(){s.autoLeft(),s.tipTop=s.top-o[1]-10,c.removeClass("layui-layer-TipsB").addClass("layui-layer-TipsT").css("border-right-color",t.tips[1])},function(){s.tipLeft=s.left+s.width+10,s.tipTop=s.top,c.removeClass("layui-layer-TipsL").addClass("layui-layer-TipsR").css("border-bottom-color",t.tips[1])},function(){s.autoLeft(),s.tipTop=s.top+s.height+10,c.removeClass("layui-layer-TipsT").addClass("layui-layer-TipsB").css("border-right-color",t.tips[1])},function(){s.tipLeft=s.left-o[0]-10,s.tipTop=s.top,c.removeClass("layui-layer-TipsR").addClass("layui-layer-TipsL").css("border-bottom-color",t.tips[1])}],s.where[f-1](),1===f?s.top-(n.scrollTop()+o[1]+16)<0&&s.where[2]():2===f?n.width()-(s.left+s.width+o[0]+16)>0||s.where[3]():3===f?s.top-n.scrollTop()+s.height+o[1]+16-n.height()>0&&s.where[0]():4===f&&o[0]+16-s.left>0&&s.where[1](),a.find("."+l[5]).css({"background-color":t.tips[1],"padding-right":t.closeBtn?"30px":""}),a.css({left:s.tipLeft-(t.fix?n.scrollLeft():0),top:s.tipTop-(t.fix?n.scrollTop():0)})},r.pt.move=function(){var e=this,t=e.config,a={setY:0,moveLayer:function(){var e=a.layero,t=parseInt(e.css("margin-left")),i=parseInt(a.move.css("left"));0===t||(i-=t),"fixed"!==e.css("position")&&(i-=e.parent().offset().left,a.setY=0),e.css({left:i,top:parseInt(a.move.css("top"))-a.setY})}},o=e.layero.find(t.move);return t.move&&o.attr("move","ok"),o.css({cursor:t.move?"move":"auto"}),i(t.move).on("mousedown",function(e){if(e.preventDefault(),"ok"===i(this).attr("move")){a.ismove=!0,a.layero=i(this).parents("."+l[0]);var o=a.layero.offset().left,r=a.layero.offset().top,s=a.layero.outerWidth()-6,c=a.layero.outerHeight()-6;i("#layui-layer-moves")[0]||i("body").append('<div id="layui-layer-moves" class="layui-layer-moves" style="left:'+o+"px; top:"+r+"px; width:"+s+"px; height:"+c+'px; z-index:2147483584"></div>'),a.move=i("#layui-layer-moves"),t.moveType&&a.move.css({visibility:"hidden"}),a.moveX=e.pageX-a.move.position().left,a.moveY=e.pageY-a.move.position().top,"fixed"!==a.layero.css("position")||(a.setY=n.scrollTop())}}),i(document).mousemove(function(e){if(a.ismove){var i=e.pageX-a.moveX,o=e.pageY-a.moveY;if(e.preventDefault(),!t.moveOut){a.setY=n.scrollTop();var r=n.width()-a.move.outerWidth(),l=a.setY;i<0&&(i=0),i>r&&(i=r),o<l&&(o=l),o>n.height()-a.move.outerHeight()+a.setY&&(o=n.height()-a.move.outerHeight()+a.setY)}a.move.css({left:i,top:o}),t.moveType&&a.moveLayer(),i=o=r=l=null}}).mouseup(function(){try{a.ismove&&(a.moveLayer(),a.move.remove(),t.moveEnd&&t.moveEnd()),a.ismove=!1}catch(e){a.ismove=!1}}),e},r.pt.callback=function(){function e(){var e=r.cancel&&r.cancel(t.index,n);e===!1||o.close(t.index)}var t=this,n=t.layero,r=t.config;t.openLayer(),r.success&&(2==r.type?n.find("iframe").on("load",function(){r.success(n,t.index)}):r.success(n,t.index)),o.ie6&&t.IE6(n),n.find("."+l[6]).children("a").on("click",function(){var e=i(this).index();if(0===e)r.yes?r.yes(t.index,n):r.btn1?r.btn1(t.index,n):o.close(t.index);else{var a=r["btn"+(e+1)]&&r["btn"+(e+1)](t.index,n);a===!1||o.close(t.index)}}),n.find("."+l[7]).on("click",e),r.shadeClose&&i("#layui-layer-shade"+t.index).on("click",function(){o.close(t.index)}),n.find(".layui-layer-min").on("click",function(){var e=r.min&&r.min(n);e===!1||o.min(t.index,r)}),n.find(".layui-layer-max").on("click",function(){i(this).hasClass("layui-layer-maxmin")?(o.restore(t.index),r.restore&&r.restore(n)):(o.full(t.index,r),setTimeout(function(){r.full&&r.full(n)},100))}),r.end&&(a.end[t.index]=r.end)},a.reselect=function(){i.each(i("select"),function(e,t){var n=i(this);n.parents("."+l[0])[0]||1==n.attr("layer")&&i("."+l[0]).length<1&&n.removeAttr("layer").show(),n=null})},r.pt.IE6=function(e){function t(){e.css({top:o+(a.config.fix?n.scrollTop():0)})}var a=this,o=e.offset().top;t(),n.scroll(t),i("select").each(function(e,t){var n=i(this);n.parents("."+l[0])[0]||"none"===n.css("display")||n.attr({layer:"1"}).hide(),n=null})},r.pt.openLayer=function(){var e=this;o.zIndex=e.config.zIndex,o.setTop=function(e){var t=function(){o.zIndex++,e.css("z-index",o.zIndex+1)};return o.zIndex=parseInt(e[0].style.zIndex),e.on("mousedown",t),o.zIndex}},a.record=function(e){var t=[e.width(),e.height(),e.position().top,e.position().left+parseFloat(e.css("margin-left"))];e.find(".layui-layer-max").addClass("layui-layer-maxmin"),e.attr({area:t})},a.rescollbar=function(e){l.html.attr("layer-full")==e&&(l.html[0].style.removeProperty?l.html[0].style.removeProperty("overflow"):l.html[0].style.removeAttribute("overflow"),l.html.removeAttr("layer-full"))},e.layer=o,o.getChildFrame=function(e,t){return t=t||i("."+l[4]).attr("times"),i("#"+l[0]+t).find("iframe").contents().find(e)},o.getFrameIndex=function(e){return i("#"+e).parents("."+l[4]).attr("times")},o.iframeAuto=function(e){if(e){var t=o.getChildFrame("html",e).outerHeight(),n=i("#"+l[0]+e),a=n.find(l[1]).outerHeight()||0,r=n.find("."+l[6]).outerHeight()||0;n.css({height:t+a+r}),n.find("iframe").css({height:t})}},o.iframeSrc=function(e,t){i("#"+l[0]+e).find("iframe").attr("src",t)},o.style=function(e,t){var n=i("#"+l[0]+e),o=n.attr("type"),r=n.find(l[1]).outerHeight()||0,s=n.find("."+l[6]).outerHeight()||0;o!==a.type[1]&&o!==a.type[2]||(n.css(t),o===a.type[2]&&n.find("iframe").css({height:parseFloat(t.height)-r-s}))},o.min=function(e,t){var n=i("#"+l[0]+e),r=n.find(l[1]).outerHeight()||0;a.record(n),o.style(e,{width:180,height:r,overflow:"hidden"}),n.find(".layui-layer-min").hide(),"page"===n.attr("type")&&n.find(l[4]).hide(),a.rescollbar(e)},o.restore=function(e){var t=i("#"+l[0]+e),n=t.attr("area").split(",");t.attr("type");o.style(e,{width:parseFloat(n[0]),height:parseFloat(n[1]),top:parseFloat(n[2]),left:parseFloat(n[3]),overflow:"visible"}),t.find(".layui-layer-max").removeClass("layui-layer-maxmin"),t.find(".layui-layer-min").show(),"page"===t.attr("type")&&t.find(l[4]).show(),a.rescollbar(e)},o.full=function(e){var t,r=i("#"+l[0]+e);a.record(r),l.html.attr("layer-full")||l.html.css("overflow","hidden").attr("layer-full",e),clearTimeout(t),t=setTimeout(function(){var t="fixed"===r.css("position");o.style(e,{top:t?0:n.scrollTop(),left:t?0:n.scrollLeft(),width:n.width(),height:n.height()}),r.find(".layui-layer-min").hide()},100)},o.title=function(e,t){var n=i("#"+l[0]+(t||o.index)).find(l[1]);n.html(e)},o.close=function(e){var t=i("#"+l[0]+e),n=t.attr("type");if(t[0]){if(n===a.type[1]&&"object"===t.attr("conType")){t.children(":not(."+l[5]+")").remove();for(var r=0;r<2;r++)t.find(".layui-layer-wrap").unwrap().hide()}else{if(n===a.type[2])try{var s=i("#"+l[4]+e)[0];s.contentWindow.document.write(""),s.contentWindow.close(),t.find("."+l[5])[0].removeChild(s)}catch(c){}t[0].innerHTML="",t.remove()}i("#layui-layer-moves, #layui-layer-shade"+e).remove(),o.ie6&&a.reselect(),a.rescollbar(e),i(document).off("keydown",a.enter),"function"==typeof a.end[e]&&a.end[e](),delete a.end[e]}},o.closeAll=function(e){i.each(i("."+l[0]),function(){var t=i(this),n=e?t.attr("type")===e:1;n&&o.close(t.attr("times")),n=null})};var s=o.cache||{},c=function(e){return s.skin?" "+s.skin+" "+s.skin+"-"+e:""};o.prompt=function(e,t){e=e||{},"function"==typeof e&&(t=e);var n,a=2==e.formType?'<textarea class="layui-layer-input">'+(e.value||"")+"</textarea>":function(){return'<input type="'+(1==e.formType?"password":"text")+'" class="layui-layer-input" value="'+(e.value||"")+'">'}();return o.open(i.extend({btn:["&#x786E;&#x5B9A;","&#x53D6;&#x6D88;"],content:a,skin:"layui-layer-prompt"+c("prompt"),success:function(e){n=e.find(".layui-layer-input"),n.focus()},yes:function(i){var a=n.val();""===a?n.focus():a.length>(e.maxlength||500)?o.tips("&#x6700;&#x591A;&#x8F93;&#x5165;"+(e.maxlength||500)+"&#x4E2A;&#x5B57;&#x6570;",n,{tips:1}):t&&t(a,i,n)}},e))},o.tab=function(e){e=e||{};var t=e.tab||{};return o.open(i.extend({type:1,skin:"layui-layer-tab"+c("tab"),title:function(){var e=t.length,i=1,n="";if(e>0)for(n='<span class="layui-layer-tabnow">'+t[0].title+"</span>";i<e;i++)n+="<span>"+t[i].title+"</span>";return n}(),content:'<ul class="layui-layer-tabmain">'+function(){var e=t.length,i=1,n="";if(e>0)for(n='<li class="layui-layer-tabli xubox_tab_layer">'+(t[0].content||"no content")+"</li>";i<e;i++)n+='<li class="layui-layer-tabli">'+(t[i].content||"no content")+"</li>";return n}()+"</ul>",success:function(t){var n=t.find(".layui-layer-title").children(),a=t.find(".layui-layer-tabmain").children();n.on("mousedown",function(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0;var n=i(this),o=n.index();n.addClass("layui-layer-tabnow").siblings().removeClass("layui-layer-tabnow"),a.eq(o).show().siblings().hide(),"function"==typeof e.change&&e.change(o)})}},e))},o.photos=function(t,n,a){function r(e,t,i){var n=new Image;return n.src=e,n.complete?t(n):(n.onload=function(){n.onload=null,t(n)},void(n.onerror=function(e){n.onerror=null,i(e)}))}var l={};if(t=t||{},t.photos){var s=t.photos.constructor===Object,f=s?t.photos:{},u=f.data||[],d=f.start||0;if(l.imgIndex=(0|d)+1,t.img=t.img||"img",s){if(0===u.length)return o.msg("&#x6CA1;&#x6709;&#x56FE;&#x7247;")}else{var y=i(t.photos),p=function(){u=[],y.find(t.img).each(function(e){var t=i(this);t.attr("layer-index",e),u.push({alt:t.attr("alt"),pid:t.attr("layer-pid"),src:t.attr("layer-src")||t.attr("src"),thumb:t.attr("src")})})};if(p(),0===u.length)return;if(n||y.on("click",t.img,function(){var e=i(this),n=e.attr("layer-index");o.photos(i.extend(t,{photos:{start:n,data:u,tab:t.tab},full:t.full}),!0),p()}),!n)return}l.imgprev=function(e){l.imgIndex--,l.imgIndex<1&&(l.imgIndex=u.length),l.tabimg(e)},l.imgnext=function(e,t){l.imgIndex++,l.imgIndex>u.length&&(l.imgIndex=1,t)||l.tabimg(e)},l.keyup=function(e){if(!l.end){var t=e.keyCode;e.preventDefault(),37===t?l.imgprev(!0):39===t?l.imgnext(!0):27===t&&o.close(l.index)}},l.tabimg=function(e){u.length<=1||(f.start=l.imgIndex-1,o.close(l.index),o.photos(t,!0,e))},l.event=function(){l.bigimg.hover(function(){l.imgsee.show()},function(){l.imgsee.hide()}),l.bigimg.find(".layui-layer-imgprev").on("click",function(e){e.preventDefault(),l.imgprev()}),l.bigimg.find(".layui-layer-imgnext").on("click",function(e){e.preventDefault(),l.imgnext()}),i(document).on("keyup",l.keyup)},l.loadi=o.load(1,{shade:!("shade"in t)&&.9,scrollbar:!1}),r(u[d].src,function(n){o.close(l.loadi),l.index=o.open(i.extend({type:1,area:function(){var a=[n.width,n.height],o=[i(e).width()-50,i(e).height()-50];return!t.full&&a[0]>o[0]&&(a[0]=o[0],a[1]=a[0]*n.height/n.width),[a[0]+"px",a[1]+"px"]}(),title:!1,shade:.9,shadeClose:!0,closeBtn:!1,move:".layui-layer-phimg img",moveType:1,scrollbar:!1,moveOut:!0,shift:5*Math.random()|0,skin:"layui-layer-photos"+c("photos"),content:'<div class="layui-layer-phimg"><img src="'+u[d].src+'" alt="'+(u[d].alt||"")+'" layer-pid="'+u[d].pid+'"><div class="layui-layer-imgsee">'+(u.length>1?'<span class="layui-layer-imguide"><a href="javascript:;" class="layui-layer-iconext layui-layer-imgprev"></a><a href="javascript:;" class="layui-layer-iconext layui-layer-imgnext"></a></span>':"")+'<div class="layui-layer-imgbar" style="display:'+(a?"block":"")+'"><span class="layui-layer-imgtit"><a href="javascript:;">'+(u[d].alt||"")+"</a><em>"+l.imgIndex+"/"+u.length+"</em></span></div></div></div>",success:function(e,i){l.bigimg=e.find(".layui-layer-phimg"),l.imgsee=e.find(".layui-layer-imguide,.layui-layer-imgbar"),l.event(e),t.tab&&t.tab(u[d],e)},end:function(){l.end=!0,i(document).off("keyup",l.keyup)}},t))},function(){o.close(l.loadi),o.msg("&#x5F53;&#x524D;&#x56FE;&#x7247;&#x5730;&#x5740;&#x5F02;&#x5E38;<br>&#x662F;&#x5426;&#x7EE7;&#x7EED;&#x67E5;&#x770B;&#x4E0B;&#x4E00;&#x5F20;&#xFF1F;",{time:3e4,btn:["&#x4E0B;&#x4E00;&#x5F20;","&#x4E0D;&#x770B;&#x4E86;"],yes:function(){u.length>1&&l.imgnext(!0,!0)}})})}},a.run=function(){i=jQuery,n=i(e),l.html=i("html"),o.open=function(e){var t=new r(e);return t.index}},"function"==typeof define?define(function(){return a.run(),o}):function(){a.run(),o.use("skin/layer.css")}()}(window);
\ No newline at end of file
{
"status": 1,
"msg": "ok",
"data": [
{
"id": "100001",
"name": "Beaut-zihan",
"time": "10:23",
"face": "img/a1.jpg"
},
{
"id": "100002",
"name": "慕容晓晓",
"time": "昨天",
"face": "img/a2.jpg"
},
{
"id": "1000033",
"name": "乔峰",
"time": "2014-4.22",
"face": "img/a3.jpg"
},
{
"id": "10000333",
"name": "高圆圆",
"time": "2014-4.21",
"face": "img/a4.jpg"
}
]
}
{
"status": 1,
"msg": "ok",
"data": [
{
"name": "销售部",
"nums": 36,
"id": 1,
"item": [
{
"id": "100001",
"name": "郭敬明",
"face": "img/a5.jpg"
},
{
"id": "100002",
"name": "作家崔成浩",
"face": "img/a6.jpg"
},
{
"id": "1000022",
"name": "韩寒",
"face": "img/a7.jpg"
},
{
"id": "10000222",
"name": "范爷",
"face": "img/a8.jpg"
},
{
"id": "100002222",
"name": "小马哥",
"face": "img/a9.jpg"
}
]
},
{
"name": "大学同窗",
"nums": 16,
"id": 2,
"item": [
{
"id": "1000033",
"name": "苏醒",
"face": "img/a9.jpg"
},
{
"id": "10000333",
"name": "马云",
"face": "img/a8.jpg"
},
{
"id": "100003",
"name": "鬼脚七",
"face": "img/a7.jpg"
},
{
"id": "100004",
"name": "谢楠",
"face": "img/a6.jpg"
},
{
"id": "100005",
"name": "徐峥",
"face": "img/a5.jpg"
}
]
},
{
"name": "H+后台主题",
"nums": 38,
"id": 3,
"item": [
{
"id": "100006",
"name": "柏雪近在它香",
"face": "img/a4.jpg"
},
{
"id": "100007",
"name": "罗昌平",
"face": "img/a3.jpg"
},
{
"id": "100008",
"name": "Crystal影子",
"face": "img/a2.jpg"
},
{
"id": "100009",
"name": "艺小想",
"face": "img/a1.jpg"
},
{
"id": "100010",
"name": "天猫",
"face": "img/a8.jpg"
},
{
"id": "100011",
"name": "张泉灵",
"face": "img/a7.jpg"
}
]
}
]
}
{
"status": 1,
"msg": "ok",
"data": [
{
"name": "H+交流群",
"nums": 36,
"id": 1,
"item": [
{
"id": "101",
"name": "H+ Bug反馈",
"face": "http://tp2.sinaimg.cn/2211874245/180/40050524279/0"
},
{
"id": "102",
"name": "H+ 技术交流",
"face": "http://tp3.sinaimg.cn/1820711170/180/1286855219/1"
}
]
},
{
"name": "Bootstrap",
"nums": 16,
"id": 2,
"item": [
{
"id": "103",
"name": "Bootstrap中文",
"face": "http://tp2.sinaimg.cn/2211874245/180/40050524279/0"
},
{
"id": "104",
"name": "Bootstrap资源",
"face": "http://tp3.sinaimg.cn/1820711170/180/1286855219/1"
}
]
},
{
"name": "WebApp",
"nums": 106,
"id": 3,
"item": [
{
"id": "105",
"name": "移动开发",
"face": "http://tp2.sinaimg.cn/2211874245/180/40050524279/0"
},
{
"id": "106",
"name": "H5前言",
"face": "http://tp3.sinaimg.cn/1820711170/180/1286855219/1"
}
]
}
]
}
{
"status": 1,
"msg": "ok",
"data": [
{
"id": "100001",
"name": "無言的蒁説",
"face": "img/a1.jpg"
},
{
"id": "100002",
"name": "婷宝奢侈品",
"face": "img/a2.jpg"
},
{
"id": "100003",
"name": "忆恨思爱",
"face": "img/a3.jpg"
},
{
"id": "100004",
"name": "天涯奥拓慢",
"face": "img/a4.jpg"
},
{
"id": "100005",
"name": "雨落无声的天空",
"face": "img/a5.jpg"
},
{
"id": "100006",
"name": "李越LycorisRadiate",
"face": "img/a6.jpg"
},
{
"id": "100007",
"name": "冯胖妞张直丑",
"face": "img/a7.jpg"
},
{
"id": "100008",
"name": "陈龙hmmm",
"face": "img/a8.jpg"
},
{
"id": "100009",
"name": "别闹哥胆儿小",
"face": "img/a9.jpg"
},
{
"id": "100010",
"name": "锅锅锅锅萌哒哒 ",
"face": "img/a10.jpg"
}
]
}
/*
@Name: layim WebIM 1.0.0
@Author:贤心(子涵修改)
@Date: 2014-04-25
@Blog: http://sentsin.com
*/
body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,input,button,textarea,p,blockquote,th,td,form{margin:0; padding:0;}
input,button,textarea,select,optgroup,option{font-family:inherit; font-size:inherit; font-style:inherit; font-weight:inherit; outline: 0;}
li{list-style:none;}
.xxim_icon, .xxim_main i, .layim_chatbox i{position:absolute;}
.loading{background:url(loading.gif) no-repeat center center;}
.layim_chatbox a, .layim_chatbox a:hover{color:#343434; text-decoration:none; }
.layim_zero{position:absolute; width:0; height:0; border-style:dashed; border-color:transparent; overflow:hidden;}
.xxim_main{position:fixed; right:1px; bottom:1px; width:230px; border:1px solid #BEBEBE; background-color:#fff; font-size:12px; box-shadow: 0 0 10px rgba(0,0,0,.2); z-index:99999999}
.layim_chatbox textarea{resize:none;}
.xxim_main em, .xxim_main i, .layim_chatbox em, .layim_chatbox i{font-style:normal; font-weight:400;}
.xxim_main h5{font-size:100%; font-weight:400;}
/* 搜索栏 */
.xxim_search{position:relative; padding-left:40px; height:40px; border-bottom:1px solid #DCDCDC; background-color:#fff;}
.xxim_search i{left:10px; top:12px; width:16px; height:16px;font-size: 16px;color:#999;}
.xxim_search input{border:none; background:none; width: 180px; margin-top:10px; line-height:20px;}
.xxim_search span{display:none; position:absolute; right:10px; top:10px; height:18px; line-height:18px;width:18px;text-align: center;background-color:#AFAFAF; color:#fff; cursor:pointer; border-radius:2px; font-size:12px; font-weight:900;}
.xxim_search span:hover{background-color:#FCBE00;}
/* 主面板tab */
.xxim_tabs{height:45px; border-bottom:1px solid #DBDBDB; background-color:#F4F4F4; font-size:0;}
.xxim_tabs span{position:relative; display:inline-block; *display:inline; *zoom:1; vertical-align:top; width:76px; height:45px; border-right:1px solid #DBDBDB; cursor:pointer; font-size:12px;}
.xxim_tabs span i{top:12px; left:50%; width:20px; margin-left:-10px; height:20px;font-size:20px;color:#ccc;}
.xxim_tabs .xxim_tabnow{height:46px; background-color:#fff;}
.xxim_tabs .xxim_tabnow i{color:#1ab394;}
.xxim_tabs .xxim_latechat{border-right:none;}
.xxim_tabs .xxim_tabfriend i{width:14px; margin-left:-7px;}
/* 主面板列表 */
.xxim_list{display:none; height:350px; padding:5px 0; overflow:hidden;}
.xxim_list:hover{ overflow-y:auto;}
.xxim_list h5{position:relative; padding-left:32px; height:26px; line-height:26px; cursor:pointer; color:#000; font-size:0;}
.xxim_list h5 span{display:inline-block; *display:inline; *zoom:1; vertical-align:top; max-width:140px; overflow:hidden; text-overflow: ellipsis; white-space:nowrap; font-size:12px;}
.xxim_list h5 i{left:15px; top:8px; width:10px; height:10px;font-size:10px;color:#666;}
.xxim_list h5 *{font-size:12px;}
.xxim_list .xxim_chatlist{display:none;}
.xxim_list .xxim_liston h5 i{width:8px; height:7px;}
.xxim_list .xxim_liston .xxim_chatlist{display:block;}
.xxim_chatlist {}
.xxim_chatlist li{position:relative; height:40px; line-height:30px; padding:5px 10px; font-size:0; cursor:pointer;}
.xxim_chatlist li:hover{background-color:#F2F4F8}
.xxim_chatlist li *{display:inline-block; *display:inline; *zoom:1; vertical-align:top; font-size:12px;}
.xxim_chatlist li span{padding-left:10px; max-width:120px; overflow:hidden; text-overflow: ellipsis; white-space:nowrap;}
.xxim_chatlist li img{width:30px; height:30px;}
.xxim_chatlist li .xxim_time{position:absolute; right:10px; color:#999;}
.xxim_list .xxim_errormsg{text-align:center; margin:50px 0; color:#999;}
.xxim_searchmain{position:absolute; width:230px; height:491px; left:0; top:41px; z-index:10; background-color:#fff;}
/* 主面板底部 */
.xxim_bottom{height:34px; border-top:1px solid #D0DCF3; background-color:#F2F4F8;}
.xxim_expend{border-left:1px solid #D0DCF3; border-bottom:1px solid #D0DCF3;}
.xxim_bottom li{position:relative; width:50px; height:32px; line-height:32px; float:left; border-right:1px solid #D0DCF3; cursor:pointer;}
.xxim_bottom li i{ top:9px;}
.xxim_bottom .xxim_hide{border-right:none;}
.xxim_bottom .xxim_online{width:72px; padding-left:35px;}
.xxim_online i{left:13px; width:14px; height:14px;font-size:14px;color:#FFA00A;}
.xxim_setonline{display:none; position:absolute; left:-79px; bottom:-1px; border:1px solid #DCDCDC; background-color:#fff;}
.xxim_setonline span{position:relative; display:block; width:32px;width: 77px; padding:0 10px 0 35px;}
.xxim_setonline span:hover{background-color:#F2F4F8;}
.xxim_offline .xxim_nowstate, .xxim_setoffline i{color:#999;}
.xxim_mymsg i{left:18px; width:14px; height:14px;font-size: 14px;}
.xxim_mymsg a{position:absolute; left:0; top:0; width:50px; height:32px;}
.xxim_seter i{left:18px; width:14px; height:14px;font-size: 14px;}
.xxim_hide i{left:18px; width:14px; height:14px;font-size: 14px;}
.xxim_show i{}
.xxim_bottom .xxim_on{position:absolute; left:-17px; top:50%; width:16px;text-align: center;color:#999;line-height: 97px; height:97px; margin-top:-49px;border:solid 1px #BEBEBE;border-right: none; background:#F2F4F8;}
.xxim_bottom .xxim_off{}
/* 聊天窗口 */
.layim_chatbox{width:620px; border:1px solid #BEBEBE; background-color:#fff; font-size:12px; box-shadow: 0 0 10px rgba(0,0,0,.2);}
.layim_chatbox h6{position:relative; height:40px; border-bottom:1px solid #D9D9D9; background-color:#FCFDFA}
.layim_move{position:absolute; height:40px; width: 620px; z-index:0;}
.layim_face{position:absolute; bottom:-1px; left:10px; width:64px; height:64px;padding:1px;background: #fff; border:1px solid #ccc;}
.layim_face img{width:60px; height:60px;}
.layim_names{position:absolute; left:90px; max-width:300px; line-height:40px; color:#000; overflow:hidden; text-overflow: ellipsis; white-space:nowrap; font-size:14px;}
.layim_rightbtn{position:absolute; right:15px; top:12px; font-size:20px;}
.layim_rightbtn i{position:relative; width:16px; height:16px; display:inline-block; *display:inline; *zoom:1; vertical-align:top; cursor:pointer; transition: all .3s;text-align: center;line-height: 16px;}
.layim_rightbtn .layim_close{background: #FFA00A;color:#fff;}
.layim_rightbtn .layim_close:hover{-webkit-transform: rotate(180deg); -moz-transform: rotate(180deg);}
.layim_rightbtn .layer_setmin{margin-right:5px;color:#999;font-size:14px;font-weight: 700;}
.layim_chat, .layim_chatmore,.layim_groups{height:450px; overflow:hidden;}
.layim_chatmore{display:none; float:left; width:135px; border-right:1px solid #BEBEBE; background-color:#F2F2F2}
.layim_chatlist li, .layim_groups li{position:relative; height:30px; line-height:30px; padding:0 10px; overflow:hidden; text-overflow: ellipsis; white-space:nowrap; cursor:pointer;}
.layim_chatlist li{padding:0 20px 0 10px;}
.layim_chatlist li:hover{background-color:#E3E3E3;}
.layim_chatlist li span{display:inline-block; *display:inline; *zoom:1; vertical-align:top; width:90px; overflow:hidden; text-overflow: ellipsis; white-space:nowrap;}
.layim_chatlist li em{display:none; position:absolute; top:6px; right:10px; height:18px; line-height:18px;width:18px;text-align: center;font-size:14px;font-weight:900; border-radius:3px;}
.layim_chatlist li em:hover{background-color: #FCBE00; color:#fff;}
.layim_chatlist .layim_chatnow,.layim_chatlist .layim_chatnow:hover{/*border-top:1px solid #D9D9D9; border-bottom:1px solid #D9D9D9;*/ background-color:#fff;}
.layim_chat{}
.layim_chatarea{height:280px;}
.layim_chatview{display:none; height:280px; overflow:hidden;}
.layim_chatmore:hover, .layim_groups:hover, .layim_chatview:hover{overflow-y:auto;}
.layim_chatview li{margin-bottom:10px; clear:both; *zoom:1;}
.layim_chatview li:after{content:'\20'; clear:both; *zoom:1; display:block; height:0;}
.layim_chatthis{display:block;}
.layim_chatuser{float:left; padding:15px; font-size:0;}
.layim_chatuser *{display:inline-block; *display:inline; *zoom:1; vertical-align:top; line-height:30px; font-size:12px; padding-right:10px;}
.layim_chatuser img{width:30px; height:30px;padding-right: 0;margin-right: 15px;}
.layim_chatuser .layim_chatname{max-width:230px; overflow:hidden; text-overflow: ellipsis; white-space:nowrap;}
.layim_chatuser .layim_chattime{color:#999; padding-left:10px;}
.layim_chatsay{position:relative; float:left; margin:0 15px; padding:10px; line-height:20px; background-color:#F3F3F3; border-radius:3px; clear:both;}
.layim_chatsay .layim_zero{left:5px; top:-8px; border-width:8px; border-right-style:solid; border-right-color:#F3F3F3;}
.layim_chateme .layim_chatuser{float:right;}
.layim_chateme .layim_chatuser *{padding-right:0; padding-left:10px;}
.layim_chateme .layim_chatuser img{margin-left:15px;padding-left: 0;}
.layim_chateme .layim_chatsay .layim_zero{left:auto; right:10px;}
.layim_chateme .layim_chatuser .layim_chattime{padding-left:0; padding-right:10px;}
.layim_chateme .layim_chatsay{float:right; background-color:#EBFBE3}
.layim_chateme .layim_zero{border-right-color:#EBFBE3;}
.layim_groups{display:none; float:right; width:130px; border-left:1px solid #D9D9D9; background-color:#fff;}
.layim_groups ul{display:none;}
.layim_groups ul.layim_groupthis{display:block;}
.layim_groups li *{display:inline-block; *display:inline; *zoom:1; vertical-align:top; margin-right:10px;}
.layim_groups li img{width:20px; height:20px; margin-top:5px;}
.layim_groups li span{max-width:80px; overflow:hidden; text-overflow: ellipsis; white-space:nowrap;}
.layim_groups li:hover{background-color:#F3F3F3;}
.layim_groups .layim_errors{text-align:center; color:#999;}
.layim_tool{position:relative; height:35px; line-height:35px; padding-left:10px; background-color:#F3F3F3;}
.layim_tool i{position:relative; top:10px; display:inline-block; *display:inline; *zoom:1; vertical-align:top; width:16px; height:16px; margin-right:10px; cursor:pointer;font-size:16px;color:#999;font-weight: 700;}
.layim_tool i:hover{color:#FFA00A;}
.layim_tool .layim_seechatlog{position:absolute; right:15px;}
.layim_tool .layim_seechatlog i{}
.layim_write{display:block; border:none; width:98%; height:90px; line-height:20px; margin:5px auto 0;}
.layim_send{position:relative; height:40px; background-color:#F3F3F3;}
.layim_sendbtn{position:absolute; height:26px; line-height:26px; right:10px; top:8px; padding:0 40px 0 20px; background-color:#FFA00A; color:#fff; border-radius:3px; cursor:pointer;}
.layim_enter{position:absolute; right:0; border-left:1px solid #FFB94F; width:24px; height:26px;}
.layim_enter:hover{background-color:#E68A00; border-radius:0 3px 3px 0;}
.layim_enter .layim_zero{left:7px; top:11px; border-width:5px; border-top-style:solid; border-top-color:#FFE0B3;}
.layim_sendtype{display:none; position:absolute; right:10px; bottom:37px; border:1px solid #D9D9D9; background-color:#fff; text-align:left;}
.layim_sendtype span{display:block; line-height:24px; padding:0 10px 0 25px; cursor:pointer;}
.layim_sendtype span:hover{background-color:#F3F3F3;}
.layim_sendtype span i{left:5px;}
.layim_min{display:none; position:absolute; left:-190px; bottom:-1px; width:160px; height:32px; line-height:32px; padding:0 10px; overflow:hidden; text-overflow: ellipsis; white-space:nowrap; border:1px solid #ccc; box-shadow: 0 0 5px rgba(0,0,75,.2); background-color:#FCFDFA; cursor:pointer;}
/*
@Name: layui WebIM 1.0.0
@Author:贤心
@Date: 2014-04-25
@Blog: http://sentsin.com
*/
;!function(win, undefined){
var config = {
msgurl: 'mailbox.html?msg=',
chatlogurl: 'mailbox.html?user=',
aniTime: 200,
right: -232,
api: {
friend: 'js/plugins/layer/layim/data/friend.json', //好友列表接口
group: 'js/plugins/layer/layim/data/group.json', //群组列表接口
chatlog: 'js/plugins/layer/layim/data/chatlog.json', //聊天记录接口
groups: 'js/plugins/layer/layim/data/groups.json', //群组成员接口
sendurl: '' //发送消息接口
},
user: { //当前用户信息
name: '游客',
face: 'img/a1.jpg'
},
//自动回复内置文案,也可动态读取数据库配置
autoReplay: [
'您好,我现在有事不在,一会再和您联系。',
'你没发错吧?',
'洗澡中,请勿打扰,偷窥请购票,个体四十,团体八折,订票电话:一般人我不告诉他!',
'你好,我是主人的美女秘书,有什么事就跟我说吧,等他回来我会转告他的。',
'我正在拉磨,没法招呼您,因为我们家毛驴去动物保护协会把我告了,说我剥夺它休产假的权利。',
'<(@ ̄︶ ̄@)>',
'你要和我说话?你真的要和我说话?你确定自己想说吗?你一定非说不可吗?那你说吧,这是自动回复。',
'主人正在开机自检,键盘鼠标看好机会出去凉快去了,我是他的电冰箱,我打字比较慢,你慢慢说,别急……',
'(*^__^*) 嘻嘻,是贤心吗?'
],
chating: {},
hosts: (function(){
var dk = location.href.match(/\:\d+/);
dk = dk ? dk[0] : '';
return 'http://' + document.domain + dk + '/';
})(),
json: function(url, data, callback, error){
return $.ajax({
type: 'POST',
url: url,
data: data,
dataType: 'json',
success: callback,
error: error
});
},
stopMP: function(e){
e ? e.stopPropagation() : e.cancelBubble = true;
}
}, dom = [$(window), $(document), $('html'), $('body')], xxim = {};
//主界面tab
xxim.tabs = function(index){
var node = xxim.node;
node.tabs.eq(index).addClass('xxim_tabnow').siblings().removeClass('xxim_tabnow');
node.list.eq(index).show().siblings('.xxim_list').hide();
if(node.list.eq(index).find('li').length === 0){
xxim.getDates(index);
}
};
//节点
xxim.renode = function(){
var node = xxim.node = {
tabs: $('#xxim_tabs>span'),
list: $('.xxim_list'),
online: $('.xxim_online'),
setonline: $('.xxim_setonline'),
onlinetex: $('#xxim_onlinetex'),
xximon: $('#xxim_on'),
layimFooter: $('#xxim_bottom'),
xximHide: $('#xxim_hide'),
xximSearch: $('#xxim_searchkey'),
searchMian: $('#xxim_searchmain'),
closeSearch: $('#xxim_closesearch'),
layimMin: $('#layim_min')
};
};
//主界面缩放
xxim.expend = function(){
var node = xxim.node;
if(xxim.layimNode.attr('state') !== '1'){
xxim.layimNode.stop().animate({right: config.right}, config.aniTime, function(){
node.xximon.addClass('xxim_off');
try{
localStorage.layimState = 1;
}catch(e){}
xxim.layimNode.attr({state: 1});
node.layimFooter.addClass('xxim_expend').stop().animate({marginLeft: config.right}, config.aniTime/2);
node.xximHide.addClass('xxim_show');
});
} else {
xxim.layimNode.stop().animate({right: 1}, config.aniTime, function(){
node.xximon.removeClass('xxim_off');
try{
localStorage.layimState = 2;
}catch(e){}
xxim.layimNode.removeAttr('state');
node.layimFooter.removeClass('xxim_expend');
node.xximHide.removeClass('xxim_show');
});
node.layimFooter.stop().animate({marginLeft: 0}, config.aniTime);
}
};
//初始化窗口格局
xxim.layinit = function(){
var node = xxim.node;
//主界面
try{
/*
if(!localStorage.layimState){
config.aniTime = 0;
localStorage.layimState = 1;
}
*/
if(localStorage.layimState === '1'){
xxim.layimNode.attr({state: 1}).css({right: config.right});
node.xximon.addClass('xxim_off');
node.layimFooter.addClass('xxim_expend').css({marginLeft: config.right});
node.xximHide.addClass('xxim_show');
}
}catch(e){
//layer.msg(e.message, 5, -1);
}
};
//聊天窗口
xxim.popchat = function(param){
var node = xxim.node, log = {};
log.success = function(layero){
layer.setMove();
xxim.chatbox = layero.find('#layim_chatbox');
log.chatlist = xxim.chatbox.find('.layim_chatmore>ul');
log.chatlist.html('<li data-id="'+ param.id +'" type="'+ param.type +'" id="layim_user'+ param.type + param.id +'"><span>'+ param.name +'</span><em>×</em></li>')
xxim.tabchat(param, xxim.chatbox);
//最小化聊天窗
xxim.chatbox.find('.layer_setmin').on('click', function(){
var indexs = layero.attr('times');
layero.hide();
node.layimMin.text(xxim.nowchat.name).show();
});
//关闭窗口
xxim.chatbox.find('.layim_close').on('click', function(){
var indexs = layero.attr('times');
layer.close(indexs);
xxim.chatbox = null;
config.chating = {};
config.chatings = 0;
});
//关闭某个聊天
log.chatlist.on('mouseenter', 'li', function(){
$(this).find('em').show();
}).on('mouseleave', 'li', function(){
$(this).find('em').hide();
});
log.chatlist.on('click', 'li em', function(e){
var parents = $(this).parent(), dataType = parents.attr('type');
var dataId = parents.attr('data-id'), index = parents.index();
var chatlist = log.chatlist.find('li'), indexs;
config.stopMP(e);
delete config.chating[dataType + dataId];
config.chatings--;
parents.remove();
$('#layim_area'+ dataType + dataId).remove();
if(dataType === 'group'){
$('#layim_group'+ dataType + dataId).remove();
}
if(parents.hasClass('layim_chatnow')){
if(index === config.chatings){
indexs = index - 1;
} else {
indexs = index + 1;
}
xxim.tabchat(config.chating[chatlist.eq(indexs).attr('type') + chatlist.eq(indexs).attr('data-id')]);
}
if(log.chatlist.find('li').length === 1){
log.chatlist.parent().hide();
}
});
//聊天选项卡
log.chatlist.on('click', 'li', function(){
var othis = $(this), dataType = othis.attr('type'), dataId = othis.attr('data-id');
xxim.tabchat(config.chating[dataType + dataId]);
});
//发送热键切换
log.sendType = $('#layim_sendtype'), log.sendTypes = log.sendType.find('span');
$('#layim_enter').on('click', function(e){
config.stopMP(e);
log.sendType.show();
});
log.sendTypes.on('click', function(){
log.sendTypes.find('i').text('')
$(this).find('i').text('√');
});
xxim.transmit();
};
log.html = '<div class="layim_chatbox" id="layim_chatbox">'
+'<h6>'
+'<span class="layim_move"></span>'
+' <a href="'+ param.url +'" class="layim_face" target="_blank"><img src="'+ param.face +'" ></a>'
+' <a href="'+ param.url +'" class="layim_names" target="_blank">'+ param.name +'</a>'
+' <span class="layim_rightbtn">'
+' <i class="layer_setmin">—</i>'
+' <i class="layim_close">&times;</i>'
+' </span>'
+'</h6>'
+'<div class="layim_chatmore" id="layim_chatmore">'
+' <ul class="layim_chatlist"></ul>'
+'</div>'
+'<div class="layim_groups" id="layim_groups"></div>'
+'<div class="layim_chat">'
+' <div class="layim_chatarea" id="layim_chatarea">'
+' <ul class="layim_chatview layim_chatthis" id="layim_area'+ param.type + param.id +'"></ul>'
+' </div>'
+' <div class="layim_tool">'
+' <i class="layim_addface fa fa-meh-o" title="发送表情"></i>'
+' <a href="javascript:;"><i class="layim_addimage fa fa-picture-o" title="上传图片"></i></a>'
+' <a href="javascript:;"><i class="layim_addfile fa fa-paperclip" title="上传附件"></i></a>'
+' <a href="" target="_blank" class="layim_seechatlog"><i class="fa fa-comment-o"></i>聊天记录</a>'
+' </div>'
+' <textarea class="layim_write" id="layim_write"></textarea>'
+' <div class="layim_send">'
+' <div class="layim_sendbtn" id="layim_sendbtn">发送<span class="layim_enter" id="layim_enter"><em class="layim_zero"></em></span></div>'
+' <div class="layim_sendtype" id="layim_sendtype">'
+' <span><i>√</i>按Enter键发送</span>'
+' <span><i></i>按Ctrl+Enter键发送</span>'
+' </div>'
+' </div>'
+'</div>'
+'</div>';
if(config.chatings < 1){
$.layer({
type: 1,
border: [0],
title: false,
shade: [0],
area: ['620px', '493px'],
move: '.layim_chatbox .layim_move',
moveType: 1,
closeBtn: false,
offset: [(($(window).height() - 493)/2)+'px', ''],
page: {
html: log.html
}, success: function(layero){
log.success(layero);
}
})
} else {
log.chatmore = xxim.chatbox.find('#layim_chatmore');
log.chatarea = xxim.chatbox.find('#layim_chatarea');
log.chatmore.show();
log.chatmore.find('ul>li').removeClass('layim_chatnow');
log.chatmore.find('ul').append('<li data-id="'+ param.id +'" type="'+ param.type +'" id="layim_user'+ param.type + param.id +'" class="layim_chatnow"><span>'+ param.name +'</span><em>×</em></li>');
log.chatarea.find('.layim_chatview').removeClass('layim_chatthis');
log.chatarea.append('<ul class="layim_chatview layim_chatthis" id="layim_area'+ param.type + param.id +'"></ul>');
xxim.tabchat(param);
}
//群组
log.chatgroup = xxim.chatbox.find('#layim_groups');
if(param.type === 'group'){
log.chatgroup.find('ul').removeClass('layim_groupthis');
log.chatgroup.append('<ul class="layim_groupthis" id="layim_group'+ param.type + param.id +'"></ul>');
xxim.getGroups(param);
}
//点击群员切换聊天窗
log.chatgroup.on('click', 'ul>li', function(){
xxim.popchatbox($(this));
});
};
//定位到某个聊天队列
xxim.tabchat = function(param){
var node = xxim.node, log = {}, keys = param.type + param.id;
xxim.nowchat = param;
xxim.chatbox.find('#layim_user'+ keys).addClass('layim_chatnow').siblings().removeClass('layim_chatnow');
xxim.chatbox.find('#layim_area'+ keys).addClass('layim_chatthis').siblings().removeClass('layim_chatthis');
xxim.chatbox.find('#layim_group'+ keys).addClass('layim_groupthis').siblings().removeClass('layim_groupthis');
xxim.chatbox.find('.layim_face>img').attr('src', param.face);
xxim.chatbox.find('.layim_face, .layim_names').attr('href', param.href);
xxim.chatbox.find('.layim_names').text(param.name);
xxim.chatbox.find('.layim_seechatlog').attr('href', config.chatlogurl + param.id);
log.groups = xxim.chatbox.find('.layim_groups');
if(param.type === 'group'){
log.groups.show();
} else {
log.groups.hide();
}
$('#layim_write').focus();
};
//弹出聊天窗
xxim.popchatbox = function(othis){
var node = xxim.node, dataId = othis.attr('data-id'), param = {
id: dataId, //用户ID
type: othis.attr('type'),
name: othis.find('.xxim_onename').text(), //用户名
face: othis.find('.xxim_oneface').attr('src'), //用户头像
href: 'profile.html?user=' + dataId //用户主页
}, key = param.type + dataId;
if(!config.chating[key]){
xxim.popchat(param);
config.chatings++;
} else {
xxim.tabchat(param);
}
config.chating[key] = param;
var chatbox = $('#layim_chatbox');
if(chatbox[0]){
node.layimMin.hide();
chatbox.parents('.xubox_layer').show();
}
};
//请求群员
xxim.getGroups = function(param){
var keys = param.type + param.id, str = '',
groupss = xxim.chatbox.find('#layim_group'+ keys);
groupss.addClass('loading');
config.json(config.api.groups, {}, function(datas){
if(datas.status === 1){
var ii = 0, lens = datas.data.length;
if(lens > 0){
for(; ii < lens; ii++){
str += '<li data-id="'+ datas.data[ii].id +'" type="one"><img src="'+ datas.data[ii].face +'" class="xxim_oneface"><span class="xxim_onename">'+ datas.data[ii].name +'</span></li>';
}
} else {
str = '<li class="layim_errors">没有群员</li>';
}
} else {
str = '<li class="layim_errors">'+ datas.msg +'</li>';
}
groupss.removeClass('loading');
groupss.html(str);
}, function(){
groupss.removeClass('loading');
groupss.html('<li class="layim_errors">请求异常</li>');
});
};
//消息传输
xxim.transmit = function(){
var node = xxim.node, log = {};
node.sendbtn = $('#layim_sendbtn');
node.imwrite = $('#layim_write');
//发送
log.send = function(){
var data = {
content: node.imwrite.val(),
id: xxim.nowchat.id,
sign_key: '', //密匙
_: +new Date
};
if(data.content.replace(/\s/g, '') === ''){
layer.tips('说点啥呗!', '#layim_write', 2);
node.imwrite.focus();
} else {
//此处皆为模拟
var keys = xxim.nowchat.type + xxim.nowchat.id;
//聊天模版
log.html = function(param, type){
return '<li class="'+ (type === 'me' ? 'layim_chateme' : '') +'">'
+'<div class="layim_chatuser">'
+ function(){
if(type === 'me'){
return '<span class="layim_chattime">'+ param.time +'</span>'
+'<span class="layim_chatname">'+ param.name +'</span>'
+'<img src="'+ param.face +'" >';
} else {
return '<img src="'+ param.face +'" >'
+'<span class="layim_chatname">'+ param.name +'</span>'
+'<span class="layim_chattime">'+ param.time +'</span>';
}
}()
+'</div>'
+'<div class="layim_chatsay">'+ param.content +'<em class="layim_zero"></em></div>'
+'</li>';
};
log.imarea = xxim.chatbox.find('#layim_area'+ keys);
log.imarea.append(log.html({
time: '2014-04-26 0:37',
name: config.user.name,
face: config.user.face,
content: data.content
}, 'me'));
node.imwrite.val('').focus();
log.imarea.scrollTop(log.imarea[0].scrollHeight);
setTimeout(function(){
log.imarea.append(log.html({
time: '2014-04-26 0:38',
name: xxim.nowchat.name,
face: xxim.nowchat.face,
content: config.autoReplay[(Math.random()*config.autoReplay.length) | 0]
}));
log.imarea.scrollTop(log.imarea[0].scrollHeight);
}, 500);
/*
that.json(config.api.sendurl, data, function(datas){
});
*/
}
};
node.sendbtn.on('click', log.send);
node.imwrite.keyup(function(e){
if(e.keyCode === 13){
log.send();
}
});
};
//事件
xxim.event = function(){
var node = xxim.node;
//主界面tab
node.tabs.eq(0).addClass('xxim_tabnow');
node.tabs.on('click', function(){
var othis = $(this), index = othis.index();
xxim.tabs(index);
});
//列表展收
node.list.on('click', 'h5', function(){
var othis = $(this), chat = othis.siblings('.xxim_chatlist'), parentss = othis.find("i");
if(parentss.hasClass('fa-caret-down')){
chat.hide();
parentss.attr('class','fa fa-caret-right');
} else {
chat.show();
parentss.attr('class','fa fa-caret-down');
}
});
//设置在线隐身
node.online.on('click', function(e){
config.stopMP(e);
node.setonline.show();
});
node.setonline.find('span').on('click', function(e){
var index = $(this).index();
config.stopMP(e);
if(index === 0){
node.onlinetex.html('在线');
node.online.removeClass('xxim_offline');
} else if(index === 1) {
node.onlinetex.html('隐身');
node.online.addClass('xxim_offline');
}
node.setonline.hide();
});
node.xximon.on('click', xxim.expend);
node.xximHide.on('click', xxim.expend);
//搜索
node.xximSearch.keyup(function(){
var val = $(this).val().replace(/\s/g, '');
if(val !== ''){
node.searchMian.show();
node.closeSearch.show();
//此处的搜索ajax参考xxim.getDates
node.list.eq(3).html('<li class="xxim_errormsg">没有符合条件的结果</li>');
} else {
node.searchMian.hide();
node.closeSearch.hide();
}
});
node.closeSearch.on('click', function(){
$(this).hide();
node.searchMian.hide();
node.xximSearch.val('').focus();
});
//弹出聊天窗
config.chatings = 0;
node.list.on('click', '.xxim_childnode', function(){
var othis = $(this);
xxim.popchatbox(othis);
});
//点击最小化栏
node.layimMin.on('click', function(){
$(this).hide();
$('#layim_chatbox').parents('.xubox_layer').show();
});
//document事件
dom[1].on('click', function(){
node.setonline.hide();
$('#layim_sendtype').hide();
});
};
//请求列表数据
xxim.getDates = function(index){
var api = [config.api.friend, config.api.group, config.api.chatlog],
node = xxim.node, myf = node.list.eq(index);
myf.addClass('loading');
config.json(api[index], {}, function(datas){
if(datas.status === 1){
var i = 0, myflen = datas.data.length, str = '', item;
if(myflen > 1){
if(index !== 2){
for(; i < myflen; i++){
str += '<li data-id="'+ datas.data[i].id +'" class="xxim_parentnode">'
+'<h5><i class="fa fa-caret-right"></i><span class="xxim_parentname">'+ datas.data[i].name +'</span><em class="xxim_nums">('+ datas.data[i].nums +')</em></h5>'
+'<ul class="xxim_chatlist">';
item = datas.data[i].item;
for(var j = 0; j < item.length; j++){
str += '<li data-id="'+ item[j].id +'" class="xxim_childnode" type="'+ (index === 0 ? 'one' : 'group') +'"><img src="'+ item[j].face +'" class="xxim_oneface"><span class="xxim_onename">'+ item[j].name +'</span></li>';
}
str += '</ul></li>';
}
} else {
str += '<li class="xxim_liston">'
+'<ul class="xxim_chatlist">';
for(; i < myflen; i++){
str += '<li data-id="'+ datas.data[i].id +'" class="xxim_childnode" type="one"><img src="'+ datas.data[i].face +'" class="xxim_oneface"><span class="xxim_onename">'+ datas.data[i].name +'</span><em class="xxim_time">'+ datas.data[i].time +'</em></li>';
}
str += '</ul></li>';
}
myf.html(str);
} else {
myf.html('<li class="xxim_errormsg">没有任何数据</li>');
}
myf.removeClass('loading');
} else {
myf.html('<li class="xxim_errormsg">'+ datas.msg +'</li>');
}
}, function(){
myf.html('<li class="xxim_errormsg">请求失败</li>');
myf.removeClass('loading');
});
};
//渲染骨架
xxim.view = (function(){
var xximNode = xxim.layimNode = $('<div id="xximmm" class="xxim_main">'
+'<div class="xxim_top" id="xxim_top">'
+' <div class="xxim_search"><i class="fa fa-search"></i><input id="xxim_searchkey" /><span id="xxim_closesearch">×</span></div>'
+' <div class="xxim_tabs" id="xxim_tabs"><span class="xxim_tabfriend" title="好友"><i class="fa fa-user"></i></span><span class="xxim_tabgroup" title="群组"><i class="fa fa-users"></i></span><span class="xxim_latechat" title="最近聊天"><i class="fa fa-clock-o"></i></span></div>'
+' <ul class="xxim_list" style="display:block"></ul>'
+' <ul class="xxim_list"></ul>'
+' <ul class="xxim_list"></ul>'
+' <ul class="xxim_list xxim_searchmain" id="xxim_searchmain"></ul>'
+'</div>'
+'<ul class="xxim_bottom" id="xxim_bottom">'
+'<li class="xxim_online" id="xxim_online">'
+'<i class="xxim_nowstate fa fa-check-circle"></i><span id="xxim_onlinetex">在线</span>'
+'<div class="xxim_setonline">'
+'<span><i class="fa fa-check-circle"></i>在线</span>'
+'<span class="xxim_setoffline"><i class="fa fa-check-circle"></i>隐身</span>'
+'</div>'
+'</li>'
+'<li class="xxim_mymsg" id="xxim_mymsg" title="我的私信"><i class="fa fa-comment"></i><a href="'+ config.msgurl +'" target="_blank"></a></li>'
+'<li class="xxim_seter" id="xxim_seter" title="设置">'
+'<i class="fa fa-gear"></i>'
+'<div>'
+'</div>'
+'</li>'
+'<li class="xxim_hide" id="xxim_hide"><i class="fa fa-exchange"></i></li>'
+'<li id="xxim_on" class="xxim_icon xxim_on fa fa-ellipsis-v"></li>'
+'<div class="layim_min" id="layim_min"></div>'
+'</ul>'
+'</div>');
dom[3].append(xximNode);
xxim.renode();
xxim.getDates(0);
xxim.event();
xxim.layinit();
}());
}(window);
/**
@Name: layer
@Author: 贤心
**/
*html{background-image:url(about:blank); background-attachment:fixed;}
html #layui_layer_skindefaultlayercss{display:none; position: absolute; width:1989px;}
/* common */
.layui-layer-shade, .layui-layer{position:fixed; _position:absolute; pointer-events: auto;}
.layui-layer-shade{top:0; left:0; width:100%; height:100%; _height:expression(document.body.offsetHeight+"px");}
.layui-layer{-webkit-overflow-scrolling: touch;}
.layui-layer{top:150px; left: 0; margin:0; padding:0; background-color:#fff; -webkit-background-clip: content; box-shadow: 1px 1px 50px rgba(0,0,0,.3);}
.layui-layer-close{position:absolute;}
.layui-layer-content{position:relative;}
.layui-layer-border{border:1px solid #B2B2B2; border:1px solid rgba(0,0,0,.3); box-shadow: 1px 1px 5px rgba(0,0,0,.2);}
.layui-layer-moves{position:absolute; border:3px solid #666; border:3px solid rgba(0,0,0,.5); cursor:move; background-color:#fff; background-color:rgba(255,255,255,.3); filter:alpha(opacity=50);}
.layui-layer-load{background:url(./default/loading-0.gif) #fff center center no-repeat;}
.layui-layer-ico{ background:url(./default/icon.png) no-repeat;}
.layui-layer-dialog .layui-layer-ico,
.layui-layer-setwin a,
.layui-layer-btn a{display:inline-block; *display:inline; *zoom:1; vertical-align:top;}
/* 动画 */
.layui-layer{border-radius:0px; -webkit-animation-fill-mode: both; animation-fill-mode: both; -webkit-animation-duration:.3s; animation-duration:.3s;}
@-webkit-keyframes bounceIn { /* 默认 */
0% {
opacity: 0;
-webkit-transform: scale(.5);
transform: scale(.5)
}
100% {
opacity: 1;
-webkit-transform: scale(1);
transform: scale(1)
}
}
@keyframes bounceIn {
0% {
opacity: 0;
-webkit-transform: scale(.5);
-ms-transform: scale(.5);
transform: scale(.5)
}
100% {
opacity: 1;
-webkit-transform: scale(1);
-ms-transform: scale(1);
transform: scale(1)
}
}
.layer-anim{-webkit-animation-name: bounceIn;animation-name: bounceIn}
@-webkit-keyframes bounceOut {
100% {
opacity: 0;
-webkit-transform: scale(.7);
transform: scale(.7)
}
30% {
-webkit-transform: scale(1.03);
transform: scale(1.03)
}
0% {
-webkit-transform: scale(1);
transform: scale(1);
}
}
@keyframes bounceOut {
100% {
opacity: 0;
-webkit-transform: scale(.7);
-ms-transform: scale(.7);
transform: scale(.7)
}
30% {
-webkit-transform: scale(1.03);
-ms-transform: scale(1.03);
transform: scale(1.03)
}
0% {
-webkit-transform: scale(1);
-ms-transform: scale(1);
transform: scale(1)
}
}
.layer-anim-close{-webkit-animation-name: bounceOut;animation-name: bounceOut; -webkit-animation-duration:.2s; animation-duration:.2s;}
@-webkit-keyframes zoomInDown{0%{opacity:0;-webkit-transform:scale(.1) translateY(-2000px);transform:scale(.1) translateY(-2000px);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}60%{opacity:1;-webkit-transform:scale(.475) translateY(60px);transform:scale(.475) translateY(60px);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}}@keyframes zoomInDown{0%{opacity:0;-webkit-transform:scale(.1) translateY(-2000px);-ms-transform:scale(.1) translateY(-2000px);transform:scale(.1) translateY(-2000px);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}60%{opacity:1;-webkit-transform:scale(.475) translateY(60px);-ms-transform:scale(.475) translateY(60px);transform:scale(.475) translateY(60px);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}}.layer-anim-01{-webkit-animation-name:zoomInDown;animation-name:zoomInDown}
@-webkit-keyframes fadeInUpBig{0%{opacity:0;-webkit-transform:translateY(2000px);transform:translateY(2000px)}100%{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes fadeInUpBig{0%{opacity:0;-webkit-transform:translateY(2000px);-ms-transform:translateY(2000px);transform:translateY(2000px)}100%{opacity:1;-webkit-transform:translateY(0);-ms-transform:translateY(0);transform:translateY(0)}}.layer-anim-02{-webkit-animation-name:fadeInUpBig;animation-name:fadeInUpBig}
@-webkit-keyframes zoomInLeft{0%{opacity:0;-webkit-transform:scale(.1) translateX(-2000px);transform:scale(.1) translateX(-2000px);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}60%{opacity:1;-webkit-transform:scale(.475) translateX(48px);transform:scale(.475) translateX(48px);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}}@keyframes zoomInLeft{0%{opacity:0;-webkit-transform:scale(.1) translateX(-2000px);-ms-transform:scale(.1) translateX(-2000px);transform:scale(.1) translateX(-2000px);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}60%{opacity:1;-webkit-transform:scale(.475) translateX(48px);-ms-transform:scale(.475) translateX(48px);transform:scale(.475) translateX(48px);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}}.layer-anim-03{-webkit-animation-name:zoomInLeft;animation-name:zoomInLeft}
@-webkit-keyframes rollIn{0%{opacity:0;-webkit-transform:translateX(-100%) rotate(-120deg);transform:translateX(-100%) rotate(-120deg)}100%{opacity:1;-webkit-transform:translateX(0px) rotate(0deg);transform:translateX(0px) rotate(0deg)}}@keyframes rollIn{0%{opacity:0;-webkit-transform:translateX(-100%) rotate(-120deg);-ms-transform:translateX(-100%) rotate(-120deg);transform:translateX(-100%) rotate(-120deg)}100%{opacity:1;-webkit-transform:translateX(0px) rotate(0deg);-ms-transform:translateX(0px) rotate(0deg);transform:translateX(0px) rotate(0deg)}}.layer-anim-04{-webkit-animation-name:rollIn;animation-name:rollIn}
@keyframes fadeIn{0%{opacity:0}100%{opacity:1}}.layer-anim-05{-webkit-animation-name:fadeIn;animation-name:fadeIn}
@-webkit-keyframes shake{0%,100%{-webkit-transform:translateX(0);transform:translateX(0)}10%,30%,50%,70%,90%{-webkit-transform:translateX(-10px);transform:translateX(-10px)}20%,40%,60%,80%{-webkit-transform:translateX(10px);transform:translateX(10px)}}@keyframes shake{0%,100%{-webkit-transform:translateX(0);-ms-transform:translateX(0);transform:translateX(0)}10%,30%,50%,70%,90%{-webkit-transform:translateX(-10px);-ms-transform:translateX(-10px);transform:translateX(-10px)}20%,40%,60%,80%{-webkit-transform:translateX(10px);-ms-transform:translateX(10px);transform:translateX(10px)}}.layer-anim-06{-webkit-animation-name:shake;animation-name:shake}@-webkit-keyframes fadeIn{0%{opacity:0}100%{opacity:1}}
/* 标题栏 */
.layui-layer-title{font-weight:bold;padding:0 80px 0 20px; height:42px; line-height:42px; border-bottom:1px solid #eee; font-size:14px; color:#333; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background-color: #F8F8F8; border-radius: 2px 2px 0 0;}
.layui-layer-setwin{position:absolute; right:15px; *right:0; top:15px; font-size:0; line-height: initial;}
.layui-layer-setwin a{position:relative; width: 16px; height:16px; margin-left:10px; font-size:12px; _overflow:hidden;}
.layui-layer-setwin .layui-layer-min cite{position:absolute; width:14px; height:2px; left:0; top:50%; margin-top:-1px; background-color:#2E2D3C; cursor:pointer; _overflow:hidden;}
.layui-layer-setwin .layui-layer-min:hover cite{background-color:#2D93CA; }
.layui-layer-setwin .layui-layer-max{background-position:-32px -40px;}
.layui-layer-setwin .layui-layer-max:hover{background-position:-16px -40px;}
.layui-layer-setwin .layui-layer-maxmin{background-position:-65px -40px;}
.layui-layer-setwin .layui-layer-maxmin:hover{background-position:-49px -40px;}
.layui-layer-setwin .layui-layer-close1{background-position:0 -40px; cursor:pointer;}
.layui-layer-setwin .layui-layer-close1:hover{opacity:0.7;}
.layui-layer-setwin .layui-layer-close2{position:absolute; right:-28px; top:-28px; width:30px; height:30px; margin-left:0; background-position:-149px -31px; *right:-18px; _display:none;}
.layui-layer-setwin .layui-layer-close2:hover{ background-position:-180px -31px;}
/* 按钮栏 */
.layui-layer-btn{text-align: right; padding:5px 10px; pointer-events: auto;border-top: 1px solid #e7eaec;}
.layui-layer-btn a{font-size: 14px;height:31px; line-height:31px; margin: 0 6px; padding: 0 15px; border:1px #dedede solid; background-color:#f1f1f1; color: #333; border-radius:0px; font-weight:400; cursor:pointer; text-decoration: none;}
.layui-layer-btn a:hover{opacity:0.9; text-decoration: none;}
.layui-layer-btn a:active{opacity:0.7;}
.layui-layer-btn .layui-layer-btn0{border-color: #4898d5; background-color: #2e8ded; color:#fff;}
/* 定制化 */
.layui-layer-dialog{min-width:260px;}
.layui-layer-dialog .layui-layer-content{position: relative; padding:20px; line-height:24px; word-break: break-all; overflow:hidden; font-size:14px; overflow-x: hidden; overflow-y:auto;}
.layui-layer-dialog .layui-layer-content .layui-layer-ico{position:absolute; top:16px; left:15px; _left:-40px; width:30px; height:30px;}
.layui-layer-ico1{background-position:-30px 0 }
.layui-layer-ico2{background-position:-60px 0;}
.layui-layer-ico3{background-position:-90px 0;}
.layui-layer-ico4{background-position:-120px 0;}
.layui-layer-ico5{background-position:-150px 0;}
.layui-layer-ico6{background-position:-180px 0;}
.layui-layer-rim{border:6px solid #8D8D8D; border:6px solid rgba(0,0,0,.3); border-radius:5px; box-shadow: none;}
.layui-layer-msg{min-width:180px; border:1px solid #D3D4D3; box-shadow: none;}
.layui-layer-hui{min-width:100px; background-color:#000; filter:alpha(opacity=60); background-color: rgba(0,0,0,0.6); color: #fff; border:none;}
.layui-layer-hui .layui-layer-content{padding:12px 25px; text-align:center;}
.layui-layer-dialog .layui-layer-padding{padding: 20px 20px 20px 55px; text-align: left;}
.layui-layer-page .layui-layer-content{position:relative; overflow:auto;}
.layui-layer-page .layui-layer-btn,.layui-layer-iframe .layui-layer-btn{padding-top:6px;}
.layui-layer-nobg{background:none;}
.layui-layer-iframe .layui-layer-content{-webkit-overflow-scrolling: touch; overflow-y: auto;}
.layui-layer-iframe iframe{display:block; width:100%;}
.layui-layer-loading{border-radius:100%; background:none; box-shadow:none; border:none;}
.layui-layer-loading .layui-layer-content{width:60px; height:24px; background:url(loading-0.gif) no-repeat;}
.layui-layer-loading .layui-layer-loading1{width:37px; height:37px; background:url(loading-1.gif) no-repeat;}
.layui-layer-loading .layui-layer-loading2, .layui-layer-ico16{width:32px; height:32px; background:url(loading-2.gif) no-repeat;}
.layui-layer-tips{background:none; box-shadow:none; border:none;}
.layui-layer-tips .layui-layer-content{position:relative; line-height:22px; min-width: 12px; padding:5px 10px; font-size:12px; _float:left; border-radius:3px; box-shadow: 1px 1px 3px rgba(0,0,0,.3); background-color:#FF9900; color:#fff;}
.layui-layer-tips .layui-layer-close{right:-2px; top:-1px;}
.layui-layer-tips i.layui-layer-TipsG{ position:absolute; width:0; height:0; border-width:8px; border-color:transparent; border-style:dashed; *overflow:hidden;}
.layui-layer-tips i.layui-layer-TipsT, .layui-layer-tips i.layui-layer-TipsB{left:5px; border-right-style:solid; border-right-color:#FF9900;}
.layui-layer-tips i.layui-layer-TipsT{bottom:-8px;}
.layui-layer-tips i.layui-layer-TipsB{top:-8px;}
.layui-layer-tips i.layui-layer-TipsR, .layui-layer-tips i.layui-layer-TipsL{top:1px; border-bottom-style:solid; border-bottom-color:#FF9900;}
.layui-layer-tips i.layui-layer-TipsR{left:-8px;}
.layui-layer-tips i.layui-layer-TipsL{right:-8px;}
/* skin */
.layui-layer-lan[type="dialog"]{min-width:280px;}
.layui-layer-lan .layui-layer-title{background:#4476A7; color:#fff; border: none;}
.layui-layer-lan .layui-layer-btn{padding:10px; text-align: right; border-top:1px solid #E9E7E7}
.layui-layer-lan .layui-layer-btn a{background:#BBB5B5; border:none;}
.layui-layer-lan .layui-layer-btn .layui-layer-btn1{background:#C9C5C5;}
.layui-layer-molv .layui-layer-title{background:#009f95; color:#fff; border: none;}
.layui-layer-molv .layui-layer-btn a{background:#009f95;}
.layui-layer-molv .layui-layer-btn .layui-layer-btn1{background:#92B8B1;}
/**
@Name: layer拓展样式
*/
.layui-layer-iconext{background:url(./default/icon-ext.png) no-repeat;}
/* prompt模式 */
.layui-layer-prompt .layui-layer-input{display:block; width:220px; height:30px; margin:0 auto; line-height:30px; padding: 0 5px; border: 1px solid #ccc; box-shadow: 1px 1px 5px rgba(0,0,0,.1) inset; color:#333;}
.layui-layer-prompt textarea.layui-layer-input{width:300px; height:100px; line-height:20px;}
/* tab模式 */
.layui-layer-tab{box-shadow:1px 1px 50px rgba(0,0,0,.4);}
.layui-layer-tab .layui-layer-title{padding-left:0; border-bottom:1px solid #ccc; background-color:#eee; overflow: visible;}
.layui-layer-tab .layui-layer-title span{position:relative; float:left; min-width:80px; max-width:260px; padding:0 20px; text-align:center; cursor:default; text-overflow: ellipsis; overflow: hidden; white-space: nowrap;}
.layui-layer-tab .layui-layer-title span.layui-layer-tabnow{height:43px; border-left:1px solid #ccc; border-right:1px solid #ccc; background-color:#fff; z-index:10;}
.layui-layer-tab .layui-layer-title span:first-child{border-left:none;}
.layui-layer-tabmain{line-height:24px; clear:both;}
.layui-layer-tabmain .layui-layer-tabli{display:none;}
.layui-layer-tabmain .layui-layer-tabli.xubox_tab_layer{display:block;}
.xubox_tabclose{position:absolute; right:10px; top:5px; cursor:pointer;}
/* photo模式 */
.layui-layer-photos{-webkit-animation-duration:1s; animation-duration:1s;}
.layui-layer-photos .layui-layer-content{overflow:hidden; text-align: center;}
.layui-layer-photos .layui-layer-phimg img{position: relative; width:100%; display: inline-block; *display:inline; *zoom:1; vertical-align:top;}
.layui-layer-imguide,.layui-layer-imgbar{display:none;}
.layui-layer-imgprev, .layui-layer-imgnext{position:absolute; top:50%; width:27px; _width:44px; height:44px; margin-top:-22px; outline:none;blr:expression(this.onFocus=this.blur());}
.layui-layer-imgprev{left:10px; background-position:-5px -5px; _background-position:-70px -5px;}
.layui-layer-imgprev:hover{background-position:-33px -5px; _background-position:-120px -5px;}
.layui-layer-imgnext{right:10px; _right:8px; background-position:-5px -50px; _background-position:-70px -50px;}
.layui-layer-imgnext:hover{background-position:-33px -50px; _background-position:-120px -50px;}
.layui-layer-imgbar{position:absolute; left:0; bottom:0; width:100%; height:32px; line-height:32px; background-color:rgba(0,0,0,.8); background-color:#000\9; filter:Alpha(opacity=80); color:#fff; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; font-size:0;}
.layui-layer-imgtit{/*position:absolute; left:20px;*/}
.layui-layer-imgtit *{display:inline-block; *display:inline; *zoom:1; vertical-align:top; font-size:12px;}
.layui-layer-imgtit a{max-width:65%; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; color:#fff;}
.layui-layer-imgtit a:hover{color:#fff; text-decoration:underline;}
.layui-layer-imgtit em{padding-left:10px; font-style: normal;}
/*!
@Name: layer拓展样式
@Date: 2012.12.13
@Author: 贤心
@blog: sentsin.com
*/.layui-layer-imgbar,.layui-layer-imgtit a,.layui-layer-tab .layui-layer-title span{text-overflow:ellipsis;white-space:nowrap}.layui-layer-iconext{background:url(default/icon-ext.png) no-repeat}html #layui_layer_skinlayerextcss{display:none;position:absolute;width:1989px}.layui-layer-prompt .layui-layer-input{display:block;width:220px;height:30px;margin:0 auto;line-height:30px;padding:0 5px;border:1px solid #ccc;box-shadow:1px 1px 5px rgba(0,0,0,.1) inset;color:#333}.layui-layer-prompt textarea.layui-layer-input{width:300px;height:100px;line-height:20px}.layui-layer-tab{box-shadow:1px 1px 50px rgba(0,0,0,.4)}.layui-layer-tab .layui-layer-title{padding-left:0;border-bottom:1px solid #ccc;background-color:#eee;overflow:visible}.layui-layer-tab .layui-layer-title span{position:relative;float:left;min-width:80px;max-width:260px;padding:0 20px;text-align:center;cursor:default;overflow:hidden}.layui-layer-tab .layui-layer-title span.layui-layer-tabnow{height:43px;border-left:1px solid #ccc;border-right:1px solid #ccc;background-color:#fff;z-index:10}.layui-layer-tab .layui-layer-title span:first-child{border-left:none}.layui-layer-tabmain{line-height:24px;clear:both}.layui-layer-tabmain .layui-layer-tabli{display:none}.layui-layer-tabmain .layui-layer-tabli.xubox_tab_layer{display:block}.xubox_tabclose{position:absolute;right:10px;top:5px;cursor:pointer}.layui-layer-photos{-webkit-animation-duration:1s;animation-duration:1s;background:url(default/xubox_loading1.gif) center center no-repeat #000}.layui-layer-photos .layui-layer-content{overflow:hidden;text-align:center}.layui-layer-photos .layui-layer-phimg img{position:relative;width:100%;display:inline-block;*display:inline;*zoom:1;vertical-align:top}.layui-layer-imgbar,.layui-layer-imguide{display:none}.layui-layer-imgnext,.layui-layer-imgprev{position:absolute;top:50%;width:27px;_width:44px;height:44px;margin-top:-22px;outline:0;blr:expression(this.onFocus=this.blur())}.layui-layer-imgprev{left:10px;background-position:-5px -5px;_background-position:-70px -5px}.layui-layer-imgprev:hover{background-position:-33px -5px;_background-position:-120px -5px}.layui-layer-imgnext{right:10px;_right:8px;background-position:-5px -50px;_background-position:-70px -50px}.layui-layer-imgnext:hover{background-position:-33px -50px;_background-position:-120px -50px}.layui-layer-imgbar{position:absolute;left:0;bottom:0;width:100%;height:32px;line-height:32px;background-color:rgba(0,0,0,.8);background-color:#000\9;filter:Alpha(opacity=80);color:#fff;overflow:hidden;font-size:0}.layui-layer-imgtit *{display:inline-block;*display:inline;*zoom:1;vertical-align:top;font-size:12px}.layui-layer-imgtit a{max-width:65%;overflow:hidden;color:#fff}.layui-layer-imgtit a:hover{color:#fff;text-decoration:underline}.layui-layer-imgtit em{padding-left:10px;font-style:normal}
/*
* layer皮肤
* 作者:一☆隐☆一
* QQ:9073194
* 请保留这里的信息 谢谢!虽然你不保留我也不能把你怎么样!
*/
html #layui_layer_skinmoonstylecss {
display: none;
position: absolute;
width: 1989px;
}
body .layer-ext-moon[type="dialog"] {
min-width: 320px;
}
body .layer-ext-moon-msg[type="dialog"]{min-width:200px;}
body .layer-ext-moon .layui-layer-title {
background: #f6f6f6;
color: #212a31;
font-size: 16px;
font-weight: bold;
height: 46px;
line-height: 46px;
}
body .layer-ext-moon .layui-layer-content .layui-layer-ico {
height: 32px;
width: 32px;
top:18.5px;
}
body .layer-ext-moon .layui-layer-ico0 {
background: url(default.png) no-repeat -96px 0;
;
}
body .layer-ext-moon .layui-layer-ico1 {
background: url(default.png) no-repeat -224px 0;
;
}
body .layer-ext-moon .layui-layer-ico2 {
background: url(default.png) no-repeat -192px 0;
}
body .layer-ext-moon .layui-layer-ico3 {
background: url(default.png) no-repeat -160px 0;
}
body .layer-ext-moon .layui-layer-ico4 {
background: url(default.png) no-repeat -320px 0;
}
body .layer-ext-moon .layui-layer-ico5 {
background: url(default.png) no-repeat -288px 0;
}
body .layer-ext-moon .layui-layer-ico6 {
background: url(default.png) -256px 0;
}
body .layer-ext-moon .layui-layer-ico7 {
background: url(default.png) no-repeat -128px 0;
}
body .layer-ext-moon .layui-layer-setwin {
top: 15px;
right: 15px;
}
body .layer-ext-moon .layui-layer-setwin a {
width: 16px;
height: 16px;
}
body .layer-ext-moon .layui-layer-setwin .layui-layer-min cite:hover {
background-color: #56abe4;
}
body .layer-ext-moon .layui-layer-setwin .layui-layer-max {
background: url(default.png) no-repeat -80px 0;
}
body .layer-ext-moon .layui-layer-setwin .layui-layer-max:hover {
background: url(default.png) no-repeat -64px 0;
}
body .layer-ext-moon .layui-layer-setwin .layui-layer-maxmin {
background: url(default.png) no-repeat -32px 0;
}
body .layer-ext-moon .layui-layer-setwin .layui-layer-maxmin:hover {
background: url(default.png) no-repeat -16px 0;
}
body .layer-ext-moon .layui-layer-setwin .layui-layer-close1,body .layer-ext-moon .layui-layer-setwin .layui-layer-close2 {
background: url(default.png) 0 0;
}
body .layer-ext-moon .layui-layer-setwin .layui-layer-close1:hover,body .layer-ext-moon .layui-layer-setwin .layui-layer-close2:hover {
background: url(default.png) -48px 0;
}
body .layer-ext-moon .layui-layer-padding{padding-top: 24px;}
body .layer-ext-moon .layui-layer-btn {
padding: 15px 0;
background: #f0f4f7;
border-top: 1px #c7c7c7 solid;
}
body .layer-ext-moon .layui-layer-btn a {
font-size: 12px;
font-weight: normal;
margin: 0 3px;
margin-right: 7px;
margin-left: 7px;
padding: 6px 20px;
color: #fff;
border: 1px solid #0064b6;
background: #0071ce;
border-radius: 3px;
display: inline-block;
height: 20px;
line-height: 20px;
text-align: center;
vertical-align: middle;
background-repeat: no-repeat;
text-decoration: none;
outline: none;
-moz-box-sizing: content-box;
-webkit-box-sizing: content-box;
box-sizing: content-box;
}
body .layer-ext-moon .layui-layer-btn .layui-layer-btn0 {
background: #0071ce;
}
body .layer-ext-moon .layui-layer-btn .layui-layer-btn1 {
background: #fff;
color: #404a58;
border: 1px solid #c0c4cd;
border-radius: 3px;
}
body .layer-ext-moon .layui-layer-btn .layui-layer-btn2 {
background: #f60;
color: #fff;
border: 1px solid #f60;
border-radius: 3px;
}
body .layer-ext-moon .layui-layer-btn .layui-layer-btn3 {
background: #f00;
color: #fff;
border: 1px solid #f00;
border-radius: 3px;
}
body .layer-ext-moon .layui-layer-title span.layui-layer-tabnow{
height:46px;
}
/*! pace 0.5.1 */
(function(){var a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W=[].slice,X={}.hasOwnProperty,Y=function(a,b){function c(){this.constructor=a}for(var d in b)X.call(b,d)&&(a[d]=b[d]);return c.prototype=b.prototype,a.prototype=new c,a.__super__=b.prototype,a},Z=[].indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(b in this&&this[b]===a)return b;return-1};for(t={catchupTime:500,initialRate:.03,minTime:500,ghostTime:500,maxProgressPerFrame:10,easeFactor:1.25,startOnPageLoad:!0,restartOnPushState:!0,restartOnRequestAfter:500,target:"body",elements:{checkInterval:100,selectors:["body"]},eventLag:{minSamples:10,sampleCount:3,lagThreshold:3},ajax:{trackMethods:["GET"],trackWebSockets:!0,ignoreURLs:[]}},B=function(){var a;return null!=(a="undefined"!=typeof performance&&null!==performance?"function"==typeof performance.now?performance.now():void 0:void 0)?a:+new Date},D=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame,s=window.cancelAnimationFrame||window.mozCancelAnimationFrame,null==D&&(D=function(a){return setTimeout(a,50)},s=function(a){return clearTimeout(a)}),F=function(a){var b,c;return b=B(),(c=function(){var d;return d=B()-b,d>=33?(b=B(),a(d,function(){return D(c)})):setTimeout(c,33-d)})()},E=function(){var a,b,c;return c=arguments[0],b=arguments[1],a=3<=arguments.length?W.call(arguments,2):[],"function"==typeof c[b]?c[b].apply(c,a):c[b]},u=function(){var a,b,c,d,e,f,g;for(b=arguments[0],d=2<=arguments.length?W.call(arguments,1):[],f=0,g=d.length;g>f;f++)if(c=d[f])for(a in c)X.call(c,a)&&(e=c[a],null!=b[a]&&"object"==typeof b[a]&&null!=e&&"object"==typeof e?u(b[a],e):b[a]=e);return b},p=function(a){var b,c,d,e,f;for(c=b=0,e=0,f=a.length;f>e;e++)d=a[e],c+=Math.abs(d),b++;return c/b},w=function(a,b){var c,d,e;if(null==a&&(a="options"),null==b&&(b=!0),e=document.querySelector("[data-pace-"+a+"]")){if(c=e.getAttribute("data-pace-"+a),!b)return c;try{return JSON.parse(c)}catch(f){return d=f,"undefined"!=typeof console&&null!==console?console.error("Error parsing inline pace options",d):void 0}}},g=function(){function a(){}return a.prototype.on=function(a,b,c,d){var e;return null==d&&(d=!1),null==this.bindings&&(this.bindings={}),null==(e=this.bindings)[a]&&(e[a]=[]),this.bindings[a].push({handler:b,ctx:c,once:d})},a.prototype.once=function(a,b,c){return this.on(a,b,c,!0)},a.prototype.off=function(a,b){var c,d,e;if(null!=(null!=(d=this.bindings)?d[a]:void 0)){if(null==b)return delete this.bindings[a];for(c=0,e=[];c<this.bindings[a].length;)this.bindings[a][c].handler===b?e.push(this.bindings[a].splice(c,1)):e.push(c++);return e}},a.prototype.trigger=function(){var a,b,c,d,e,f,g,h,i;if(c=arguments[0],a=2<=arguments.length?W.call(arguments,1):[],null!=(g=this.bindings)?g[c]:void 0){for(e=0,i=[];e<this.bindings[c].length;)h=this.bindings[c][e],d=h.handler,b=h.ctx,f=h.once,d.apply(null!=b?b:this,a),f?i.push(this.bindings[c].splice(e,1)):i.push(e++);return i}},a}(),null==window.Pace&&(window.Pace={}),u(Pace,g.prototype),C=Pace.options=u({},t,window.paceOptions,w()),T=["ajax","document","eventLag","elements"],P=0,R=T.length;R>P;P++)J=T[P],C[J]===!0&&(C[J]=t[J]);i=function(a){function b(){return U=b.__super__.constructor.apply(this,arguments)}return Y(b,a),b}(Error),b=function(){function a(){this.progress=0}return a.prototype.getElement=function(){var a;if(null==this.el){if(a=document.querySelector(C.target),!a)throw new i;this.el=document.createElement("div"),this.el.className="pace pace-active",document.body.className=document.body.className.replace(/pace-done/g,""),document.body.className+=" pace-running",this.el.innerHTML='<div class="pace-progress">\n <div class="pace-progress-inner"></div>\n</div>\n<div class="pace-activity"></div>',null!=a.firstChild?a.insertBefore(this.el,a.firstChild):a.appendChild(this.el)}return this.el},a.prototype.finish=function(){var a;return a=this.getElement(),a.className=a.className.replace("pace-active",""),a.className+=" pace-inactive",document.body.className=document.body.className.replace("pace-running",""),document.body.className+=" pace-done"},a.prototype.update=function(a){return this.progress=a,this.render()},a.prototype.destroy=function(){try{this.getElement().parentNode.removeChild(this.getElement())}catch(a){i=a}return this.el=void 0},a.prototype.render=function(){var a,b;return null==document.querySelector(C.target)?!1:(a=this.getElement(),a.children[0].style.width=""+this.progress+"%",(!this.lastRenderedProgress||this.lastRenderedProgress|0!==this.progress|0)&&(a.children[0].setAttribute("data-progress-text",""+(0|this.progress)+"%"),this.progress>=100?b="99":(b=this.progress<10?"0":"",b+=0|this.progress),a.children[0].setAttribute("data-progress",""+b)),this.lastRenderedProgress=this.progress)},a.prototype.done=function(){return this.progress>=100},a}(),h=function(){function a(){this.bindings={}}return a.prototype.trigger=function(a,b){var c,d,e,f,g;if(null!=this.bindings[a]){for(f=this.bindings[a],g=[],d=0,e=f.length;e>d;d++)c=f[d],g.push(c.call(this,b));return g}},a.prototype.on=function(a,b){var c;return null==(c=this.bindings)[a]&&(c[a]=[]),this.bindings[a].push(b)},a}(),O=window.XMLHttpRequest,N=window.XDomainRequest,M=window.WebSocket,v=function(a,b){var c,d,e,f;f=[];for(d in b.prototype)try{e=b.prototype[d],null==a[d]&&"function"!=typeof e?f.push(a[d]=e):f.push(void 0)}catch(g){c=g}return f},z=[],Pace.ignore=function(){var a,b,c;return b=arguments[0],a=2<=arguments.length?W.call(arguments,1):[],z.unshift("ignore"),c=b.apply(null,a),z.shift(),c},Pace.track=function(){var a,b,c;return b=arguments[0],a=2<=arguments.length?W.call(arguments,1):[],z.unshift("track"),c=b.apply(null,a),z.shift(),c},I=function(a){var b;if(null==a&&(a="GET"),"track"===z[0])return"force";if(!z.length&&C.ajax){if("socket"===a&&C.ajax.trackWebSockets)return!0;if(b=a.toUpperCase(),Z.call(C.ajax.trackMethods,b)>=0)return!0}return!1},j=function(a){function b(){var a,c=this;b.__super__.constructor.apply(this,arguments),a=function(a){var b;return b=a.open,a.open=function(d,e){return I(d)&&c.trigger("request",{type:d,url:e,request:a}),b.apply(a,arguments)}},window.XMLHttpRequest=function(b){var c;return c=new O(b),a(c),c},v(window.XMLHttpRequest,O),null!=N&&(window.XDomainRequest=function(){var b;return b=new N,a(b),b},v(window.XDomainRequest,N)),null!=M&&C.ajax.trackWebSockets&&(window.WebSocket=function(a,b){var d;return d=null!=b?new M(a,b):new M(a),I("socket")&&c.trigger("request",{type:"socket",url:a,protocols:b,request:d}),d},v(window.WebSocket,M))}return Y(b,a),b}(h),Q=null,x=function(){return null==Q&&(Q=new j),Q},H=function(a){var b,c,d,e;for(e=C.ajax.ignoreURLs,c=0,d=e.length;d>c;c++)if(b=e[c],"string"==typeof b){if(-1!==a.indexOf(b))return!0}else if(b.test(a))return!0;return!1},x().on("request",function(b){var c,d,e,f,g;return f=b.type,e=b.request,g=b.url,H(g)?void 0:Pace.running||C.restartOnRequestAfter===!1&&"force"!==I(f)?void 0:(d=arguments,c=C.restartOnRequestAfter||0,"boolean"==typeof c&&(c=0),setTimeout(function(){var b,c,g,h,i,j;if(b="socket"===f?e.readyState<2:0<(h=e.readyState)&&4>h){for(Pace.restart(),i=Pace.sources,j=[],c=0,g=i.length;g>c;c++){if(J=i[c],J instanceof a){J.watch.apply(J,d);break}j.push(void 0)}return j}},c))}),a=function(){function a(){var a=this;this.elements=[],x().on("request",function(){return a.watch.apply(a,arguments)})}return a.prototype.watch=function(a){var b,c,d,e;return d=a.type,b=a.request,e=a.url,H(e)?void 0:(c="socket"===d?new m(b):new n(b),this.elements.push(c))},a}(),n=function(){function a(a){var b,c,d,e,f,g,h=this;if(this.progress=0,null!=window.ProgressEvent)for(c=null,a.addEventListener("progress",function(a){return h.progress=a.lengthComputable?100*a.loaded/a.total:h.progress+(100-h.progress)/2}),g=["load","abort","timeout","error"],d=0,e=g.length;e>d;d++)b=g[d],a.addEventListener(b,function(){return h.progress=100});else f=a.onreadystatechange,a.onreadystatechange=function(){var b;return 0===(b=a.readyState)||4===b?h.progress=100:3===a.readyState&&(h.progress=50),"function"==typeof f?f.apply(null,arguments):void 0}}return a}(),m=function(){function a(a){var b,c,d,e,f=this;for(this.progress=0,e=["error","open"],c=0,d=e.length;d>c;c++)b=e[c],a.addEventListener(b,function(){return f.progress=100})}return a}(),d=function(){function a(a){var b,c,d,f;for(null==a&&(a={}),this.elements=[],null==a.selectors&&(a.selectors=[]),f=a.selectors,c=0,d=f.length;d>c;c++)b=f[c],this.elements.push(new e(b))}return a}(),e=function(){function a(a){this.selector=a,this.progress=0,this.check()}return a.prototype.check=function(){var a=this;return document.querySelector(this.selector)?this.done():setTimeout(function(){return a.check()},C.elements.checkInterval)},a.prototype.done=function(){return this.progress=100},a}(),c=function(){function a(){var a,b,c=this;this.progress=null!=(b=this.states[document.readyState])?b:100,a=document.onreadystatechange,document.onreadystatechange=function(){return null!=c.states[document.readyState]&&(c.progress=c.states[document.readyState]),"function"==typeof a?a.apply(null,arguments):void 0}}return a.prototype.states={loading:0,interactive:50,complete:100},a}(),f=function(){function a(){var a,b,c,d,e,f=this;this.progress=0,a=0,e=[],d=0,c=B(),b=setInterval(function(){var g;return g=B()-c-50,c=B(),e.push(g),e.length>C.eventLag.sampleCount&&e.shift(),a=p(e),++d>=C.eventLag.minSamples&&a<C.eventLag.lagThreshold?(f.progress=100,clearInterval(b)):f.progress=100*(3/(a+3))},50)}return a}(),l=function(){function a(a){this.source=a,this.last=this.sinceLastUpdate=0,this.rate=C.initialRate,this.catchup=0,this.progress=this.lastProgress=0,null!=this.source&&(this.progress=E(this.source,"progress"))}return a.prototype.tick=function(a,b){var c;return null==b&&(b=E(this.source,"progress")),b>=100&&(this.done=!0),b===this.last?this.sinceLastUpdate+=a:(this.sinceLastUpdate&&(this.rate=(b-this.last)/this.sinceLastUpdate),this.catchup=(b-this.progress)/C.catchupTime,this.sinceLastUpdate=0,this.last=b),b>this.progress&&(this.progress+=this.catchup*a),c=1-Math.pow(this.progress/100,C.easeFactor),this.progress+=c*this.rate*a,this.progress=Math.min(this.lastProgress+C.maxProgressPerFrame,this.progress),this.progress=Math.max(0,this.progress),this.progress=Math.min(100,this.progress),this.lastProgress=this.progress,this.progress},a}(),K=null,G=null,q=null,L=null,o=null,r=null,Pace.running=!1,y=function(){return C.restartOnPushState?Pace.restart():void 0},null!=window.history.pushState&&(S=window.history.pushState,window.history.pushState=function(){return y(),S.apply(window.history,arguments)}),null!=window.history.replaceState&&(V=window.history.replaceState,window.history.replaceState=function(){return y(),V.apply(window.history,arguments)}),k={ajax:a,elements:d,document:c,eventLag:f},(A=function(){var a,c,d,e,f,g,h,i;for(Pace.sources=K=[],g=["ajax","elements","document","eventLag"],c=0,e=g.length;e>c;c++)a=g[c],C[a]!==!1&&K.push(new k[a](C[a]));for(i=null!=(h=C.extraSources)?h:[],d=0,f=i.length;f>d;d++)J=i[d],K.push(new J(C));return Pace.bar=q=new b,G=[],L=new l})(),Pace.stop=function(){return Pace.trigger("stop"),Pace.running=!1,q.destroy(),r=!0,null!=o&&("function"==typeof s&&s(o),o=null),A()},Pace.restart=function(){return Pace.trigger("restart"),Pace.stop(),Pace.start()},Pace.go=function(){var a;return Pace.running=!0,q.render(),a=B(),r=!1,o=F(function(b,c){var d,e,f,g,h,i,j,k,m,n,o,p,s,t,u,v;for(k=100-q.progress,e=o=0,f=!0,i=p=0,t=K.length;t>p;i=++p)for(J=K[i],n=null!=G[i]?G[i]:G[i]=[],h=null!=(v=J.elements)?v:[J],j=s=0,u=h.length;u>s;j=++s)g=h[j],m=null!=n[j]?n[j]:n[j]=new l(g),f&=m.done,m.done||(e++,o+=m.tick(b));return d=o/e,q.update(L.tick(b,d)),q.done()||f||r?(q.update(100),Pace.trigger("done"),setTimeout(function(){return q.finish(),Pace.running=!1,Pace.trigger("hide")},Math.max(C.ghostTime,Math.max(C.minTime-(B()-a),0)))):c()})},Pace.start=function(a){u(C,a),Pace.running=!0;try{q.render()}catch(b){i=b}return document.querySelector(".pace")?(Pace.trigger("start"),Pace.go()):setTimeout(Pace.start,50)},"function"==typeof define&&define.amd?define(function(){return Pace}):"object"==typeof exports?module.exports=Pace:C.startOnPageLoad&&Pace.start()}).call(this);
/*!
* Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome
* License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License)
*/@font-face{font-family:'FontAwesome';src:url('../fonts/fontawesome-webfont.eot?v=4.7.0');src:url('../fonts/fontawesome-webfont.eot?#iefix&v=4.7.0') format('embedded-opentype'),url('../fonts/fontawesome-webfont.woff2?v=4.7.0') format('woff2'),url('../fonts/fontawesome-webfont.woff?v=4.7.0') format('woff'),url('../fonts/fontawesome-webfont.ttf?v=4.7.0') format('truetype'),url('../fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular') format('svg');font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{left:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left{margin-right:.3em}.fa.fa-pull-right{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);-ms-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);-ms-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:"\f000"}.fa-music:before{content:"\f001"}.fa-search:before{content:"\f002"}.fa-envelope-o:before{content:"\f003"}.fa-heart:before{content:"\f004"}.fa-star:before{content:"\f005"}.fa-star-o:before{content:"\f006"}.fa-user:before{content:"\f007"}.fa-film:before{content:"\f008"}.fa-th-large:before{content:"\f009"}.fa-th:before{content:"\f00a"}.fa-th-list:before{content:"\f00b"}.fa-check:before{content:"\f00c"}.fa-remove:before,.fa-close:before,.fa-times:before{content:"\f00d"}.fa-search-plus:before{content:"\f00e"}.fa-search-minus:before{content:"\f010"}.fa-power-off:before{content:"\f011"}.fa-signal:before{content:"\f012"}.fa-gear:before,.fa-cog:before{content:"\f013"}.fa-trash-o:before{content:"\f014"}.fa-home:before{content:"\f015"}.fa-file-o:before{content:"\f016"}.fa-clock-o:before{content:"\f017"}.fa-road:before{content:"\f018"}.fa-download:before{content:"\f019"}.fa-arrow-circle-o-down:before{content:"\f01a"}.fa-arrow-circle-o-up:before{content:"\f01b"}.fa-inbox:before{content:"\f01c"}.fa-play-circle-o:before{content:"\f01d"}.fa-rotate-right:before,.fa-repeat:before{content:"\f01e"}.fa-refresh:before{content:"\f021"}.fa-list-alt:before{content:"\f022"}.fa-lock:before{content:"\f023"}.fa-flag:before{content:"\f024"}.fa-headphones:before{content:"\f025"}.fa-volume-off:before{content:"\f026"}.fa-volume-down:before{content:"\f027"}.fa-volume-up:before{content:"\f028"}.fa-qrcode:before{content:"\f029"}.fa-barcode:before{content:"\f02a"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-book:before{content:"\f02d"}.fa-bookmark:before{content:"\f02e"}.fa-print:before{content:"\f02f"}.fa-camera:before{content:"\f030"}.fa-font:before{content:"\f031"}.fa-bold:before{content:"\f032"}.fa-italic:before{content:"\f033"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-align-left:before{content:"\f036"}.fa-align-center:before{content:"\f037"}.fa-align-right:before{content:"\f038"}.fa-align-justify:before{content:"\f039"}.fa-list:before{content:"\f03a"}.fa-dedent:before,.fa-outdent:before{content:"\f03b"}.fa-indent:before{content:"\f03c"}.fa-video-camera:before{content:"\f03d"}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:"\f03e"}.fa-pencil:before{content:"\f040"}.fa-map-marker:before{content:"\f041"}.fa-adjust:before{content:"\f042"}.fa-tint:before{content:"\f043"}.fa-edit:before,.fa-pencil-square-o:before{content:"\f044"}.fa-share-square-o:before{content:"\f045"}.fa-check-square-o:before{content:"\f046"}.fa-arrows:before{content:"\f047"}.fa-step-backward:before{content:"\f048"}.fa-fast-backward:before{content:"\f049"}.fa-backward:before{content:"\f04a"}.fa-play:before{content:"\f04b"}.fa-pause:before{content:"\f04c"}.fa-stop:before{content:"\f04d"}.fa-forward:before{content:"\f04e"}.fa-fast-forward:before{content:"\f050"}.fa-step-forward:before{content:"\f051"}.fa-eject:before{content:"\f052"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-plus-circle:before{content:"\f055"}.fa-minus-circle:before{content:"\f056"}.fa-times-circle:before{content:"\f057"}.fa-check-circle:before{content:"\f058"}.fa-question-circle:before{content:"\f059"}.fa-info-circle:before{content:"\f05a"}.fa-crosshairs:before{content:"\f05b"}.fa-times-circle-o:before{content:"\f05c"}.fa-check-circle-o:before{content:"\f05d"}.fa-ban:before{content:"\f05e"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrow-down:before{content:"\f063"}.fa-mail-forward:before,.fa-share:before{content:"\f064"}.fa-expand:before{content:"\f065"}.fa-compress:before{content:"\f066"}.fa-plus:before{content:"\f067"}.fa-minus:before{content:"\f068"}.fa-asterisk:before{content:"\f069"}.fa-exclamation-circle:before{content:"\f06a"}.fa-gift:before{content:"\f06b"}.fa-leaf:before{content:"\f06c"}.fa-fire:before{content:"\f06d"}.fa-eye:before{content:"\f06e"}.fa-eye-slash:before{content:"\f070"}.fa-warning:before,.fa-exclamation-triangle:before{content:"\f071"}.fa-plane:before{content:"\f072"}.fa-calendar:before{content:"\f073"}.fa-random:before{content:"\f074"}.fa-comment:before{content:"\f075"}.fa-magnet:before{content:"\f076"}.fa-chevron-up:before{content:"\f077"}.fa-chevron-down:before{content:"\f078"}.fa-retweet:before{content:"\f079"}.fa-shopping-cart:before{content:"\f07a"}.fa-folder:before{content:"\f07b"}.fa-folder-open:before{content:"\f07c"}.fa-arrows-v:before{content:"\f07d"}.fa-arrows-h:before{content:"\f07e"}.fa-bar-chart-o:before,.fa-bar-chart:before{content:"\f080"}.fa-twitter-square:before{content:"\f081"}.fa-facebook-square:before{content:"\f082"}.fa-camera-retro:before{content:"\f083"}.fa-key:before{content:"\f084"}.fa-gears:before,.fa-cogs:before{content:"\f085"}.fa-comments:before{content:"\f086"}.fa-thumbs-o-up:before{content:"\f087"}.fa-thumbs-o-down:before{content:"\f088"}.fa-star-half:before{content:"\f089"}.fa-heart-o:before{content:"\f08a"}.fa-sign-out:before{content:"\f08b"}.fa-linkedin-square:before{content:"\f08c"}.fa-thumb-tack:before{content:"\f08d"}.fa-external-link:before{content:"\f08e"}.fa-sign-in:before{content:"\f090"}.fa-trophy:before{content:"\f091"}.fa-github-square:before{content:"\f092"}.fa-upload:before{content:"\f093"}.fa-lemon-o:before{content:"\f094"}.fa-phone:before{content:"\f095"}.fa-square-o:before{content:"\f096"}.fa-bookmark-o:before{content:"\f097"}.fa-phone-square:before{content:"\f098"}.fa-twitter:before{content:"\f099"}.fa-facebook-f:before,.fa-facebook:before{content:"\f09a"}.fa-github:before{content:"\f09b"}.fa-unlock:before{content:"\f09c"}.fa-credit-card:before{content:"\f09d"}.fa-feed:before,.fa-rss:before{content:"\f09e"}.fa-hdd-o:before{content:"\f0a0"}.fa-bullhorn:before{content:"\f0a1"}.fa-bell:before{content:"\f0f3"}.fa-certificate:before{content:"\f0a3"}.fa-hand-o-right:before{content:"\f0a4"}.fa-hand-o-left:before{content:"\f0a5"}.fa-hand-o-up:before{content:"\f0a6"}.fa-hand-o-down:before{content:"\f0a7"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-globe:before{content:"\f0ac"}.fa-wrench:before{content:"\f0ad"}.fa-tasks:before{content:"\f0ae"}.fa-filter:before{content:"\f0b0"}.fa-briefcase:before{content:"\f0b1"}.fa-arrows-alt:before{content:"\f0b2"}.fa-group:before,.fa-users:before{content:"\f0c0"}.fa-chain:before,.fa-link:before{content:"\f0c1"}.fa-cloud:before{content:"\f0c2"}.fa-flask:before{content:"\f0c3"}.fa-cut:before,.fa-scissors:before{content:"\f0c4"}.fa-copy:before,.fa-files-o:before{content:"\f0c5"}.fa-paperclip:before{content:"\f0c6"}.fa-save:before,.fa-floppy-o:before{content:"\f0c7"}.fa-square:before{content:"\f0c8"}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:"\f0c9"}.fa-list-ul:before{content:"\f0ca"}.fa-list-ol:before{content:"\f0cb"}.fa-strikethrough:before{content:"\f0cc"}.fa-underline:before{content:"\f0cd"}.fa-table:before{content:"\f0ce"}.fa-magic:before{content:"\f0d0"}.fa-truck:before{content:"\f0d1"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-square:before{content:"\f0d3"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-plus:before{content:"\f0d5"}.fa-money:before{content:"\f0d6"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-up:before{content:"\f0d8"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-columns:before{content:"\f0db"}.fa-unsorted:before,.fa-sort:before{content:"\f0dc"}.fa-sort-down:before,.fa-sort-desc:before{content:"\f0dd"}.fa-sort-up:before,.fa-sort-asc:before{content:"\f0de"}.fa-envelope:before{content:"\f0e0"}.fa-linkedin:before{content:"\f0e1"}.fa-rotate-left:before,.fa-undo:before{content:"\f0e2"}.fa-legal:before,.fa-gavel:before{content:"\f0e3"}.fa-dashboard:before,.fa-tachometer:before{content:"\f0e4"}.fa-comment-o:before{content:"\f0e5"}.fa-comments-o:before{content:"\f0e6"}.fa-flash:before,.fa-bolt:before{content:"\f0e7"}.fa-sitemap:before{content:"\f0e8"}.fa-umbrella:before{content:"\f0e9"}.fa-paste:before,.fa-clipboard:before{content:"\f0ea"}.fa-lightbulb-o:before{content:"\f0eb"}.fa-exchange:before{content:"\f0ec"}.fa-cloud-download:before{content:"\f0ed"}.fa-cloud-upload:before{content:"\f0ee"}.fa-user-md:before{content:"\f0f0"}.fa-stethoscope:before{content:"\f0f1"}.fa-suitcase:before{content:"\f0f2"}.fa-bell-o:before{content:"\f0a2"}.fa-coffee:before{content:"\f0f4"}.fa-cutlery:before{content:"\f0f5"}.fa-file-text-o:before{content:"\f0f6"}.fa-building-o:before{content:"\f0f7"}.fa-hospital-o:before{content:"\f0f8"}.fa-ambulance:before{content:"\f0f9"}.fa-medkit:before{content:"\f0fa"}.fa-fighter-jet:before{content:"\f0fb"}.fa-beer:before{content:"\f0fc"}.fa-h-square:before{content:"\f0fd"}.fa-plus-square:before{content:"\f0fe"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angle-down:before{content:"\f107"}.fa-desktop:before{content:"\f108"}.fa-laptop:before{content:"\f109"}.fa-tablet:before{content:"\f10a"}.fa-mobile-phone:before,.fa-mobile:before{content:"\f10b"}.fa-circle-o:before{content:"\f10c"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-spinner:before{content:"\f110"}.fa-circle:before{content:"\f111"}.fa-mail-reply:before,.fa-reply:before{content:"\f112"}.fa-github-alt:before{content:"\f113"}.fa-folder-o:before{content:"\f114"}.fa-folder-open-o:before{content:"\f115"}.fa-smile-o:before{content:"\f118"}.fa-frown-o:before{content:"\f119"}.fa-meh-o:before{content:"\f11a"}.fa-gamepad:before{content:"\f11b"}.fa-keyboard-o:before{content:"\f11c"}.fa-flag-o:before{content:"\f11d"}.fa-flag-checkered:before{content:"\f11e"}.fa-terminal:before{content:"\f120"}.fa-code:before{content:"\f121"}.fa-mail-reply-all:before,.fa-reply-all:before{content:"\f122"}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:"\f123"}.fa-location-arrow:before{content:"\f124"}.fa-crop:before{content:"\f125"}.fa-code-fork:before{content:"\f126"}.fa-unlink:before,.fa-chain-broken:before{content:"\f127"}.fa-question:before{content:"\f128"}.fa-info:before{content:"\f129"}.fa-exclamation:before{content:"\f12a"}.fa-superscript:before{content:"\f12b"}.fa-subscript:before{content:"\f12c"}.fa-eraser:before{content:"\f12d"}.fa-puzzle-piece:before{content:"\f12e"}.fa-microphone:before{content:"\f130"}.fa-microphone-slash:before{content:"\f131"}.fa-shield:before{content:"\f132"}.fa-calendar-o:before{content:"\f133"}.fa-fire-extinguisher:before{content:"\f134"}.fa-rocket:before{content:"\f135"}.fa-maxcdn:before{content:"\f136"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-html5:before{content:"\f13b"}.fa-css3:before{content:"\f13c"}.fa-anchor:before{content:"\f13d"}.fa-unlock-alt:before{content:"\f13e"}.fa-bullseye:before{content:"\f140"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-rss-square:before{content:"\f143"}.fa-play-circle:before{content:"\f144"}.fa-ticket:before{content:"\f145"}.fa-minus-square:before{content:"\f146"}.fa-minus-square-o:before{content:"\f147"}.fa-level-up:before{content:"\f148"}.fa-level-down:before{content:"\f149"}.fa-check-square:before{content:"\f14a"}.fa-pencil-square:before{content:"\f14b"}.fa-external-link-square:before{content:"\f14c"}.fa-share-square:before{content:"\f14d"}.fa-compass:before{content:"\f14e"}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:"\f150"}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:"\f151"}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:"\f152"}.fa-euro:before,.fa-eur:before{content:"\f153"}.fa-gbp:before{content:"\f154"}.fa-dollar:before,.fa-usd:before{content:"\f155"}.fa-rupee:before,.fa-inr:before{content:"\f156"}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:"\f157"}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:"\f158"}.fa-won:before,.fa-krw:before{content:"\f159"}.fa-bitcoin:before,.fa-btc:before{content:"\f15a"}.fa-file:before{content:"\f15b"}.fa-file-text:before{content:"\f15c"}.fa-sort-alpha-asc:before{content:"\f15d"}.fa-sort-alpha-desc:before{content:"\f15e"}.fa-sort-amount-asc:before{content:"\f160"}.fa-sort-amount-desc:before{content:"\f161"}.fa-sort-numeric-asc:before{content:"\f162"}.fa-sort-numeric-desc:before{content:"\f163"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbs-down:before{content:"\f165"}.fa-youtube-square:before{content:"\f166"}.fa-youtube:before{content:"\f167"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-youtube-play:before{content:"\f16a"}.fa-dropbox:before{content:"\f16b"}.fa-stack-overflow:before{content:"\f16c"}.fa-instagram:before{content:"\f16d"}.fa-flickr:before{content:"\f16e"}.fa-adn:before{content:"\f170"}.fa-bitbucket:before{content:"\f171"}.fa-bitbucket-square:before{content:"\f172"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-long-arrow-down:before{content:"\f175"}.fa-long-arrow-up:before{content:"\f176"}.fa-long-arrow-left:before{content:"\f177"}.fa-long-arrow-right:before{content:"\f178"}.fa-apple:before{content:"\f179"}.fa-windows:before{content:"\f17a"}.fa-android:before{content:"\f17b"}.fa-linux:before{content:"\f17c"}.fa-dribbble:before{content:"\f17d"}.fa-skype:before{content:"\f17e"}.fa-foursquare:before{content:"\f180"}.fa-trello:before{content:"\f181"}.fa-female:before{content:"\f182"}.fa-male:before{content:"\f183"}.fa-gittip:before,.fa-gratipay:before{content:"\f184"}.fa-sun-o:before{content:"\f185"}.fa-moon-o:before{content:"\f186"}.fa-archive:before{content:"\f187"}.fa-bug:before{content:"\f188"}.fa-vk:before{content:"\f189"}.fa-weibo:before{content:"\f18a"}.fa-renren:before{content:"\f18b"}.fa-pagelines:before{content:"\f18c"}.fa-stack-exchange:before{content:"\f18d"}.fa-arrow-circle-o-right:before{content:"\f18e"}.fa-arrow-circle-o-left:before{content:"\f190"}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:"\f191"}.fa-dot-circle-o:before{content:"\f192"}.fa-wheelchair:before{content:"\f193"}.fa-vimeo-square:before{content:"\f194"}.fa-turkish-lira:before,.fa-try:before{content:"\f195"}.fa-plus-square-o:before{content:"\f196"}.fa-space-shuttle:before{content:"\f197"}.fa-slack:before{content:"\f198"}.fa-envelope-square:before{content:"\f199"}.fa-wordpress:before{content:"\f19a"}.fa-openid:before{content:"\f19b"}.fa-institution:before,.fa-bank:before,.fa-university:before{content:"\f19c"}.fa-mortar-board:before,.fa-graduation-cap:before{content:"\f19d"}.fa-yahoo:before{content:"\f19e"}.fa-google:before{content:"\f1a0"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-square:before{content:"\f1a2"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-stumbleupon:before{content:"\f1a4"}.fa-delicious:before{content:"\f1a5"}.fa-digg:before{content:"\f1a6"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-drupal:before{content:"\f1a9"}.fa-joomla:before{content:"\f1aa"}.fa-language:before{content:"\f1ab"}.fa-fax:before{content:"\f1ac"}.fa-building:before{content:"\f1ad"}.fa-child:before{content:"\f1ae"}.fa-paw:before{content:"\f1b0"}.fa-spoon:before{content:"\f1b1"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-recycle:before{content:"\f1b8"}.fa-automobile:before,.fa-car:before{content:"\f1b9"}.fa-cab:before,.fa-taxi:before{content:"\f1ba"}.fa-tree:before{content:"\f1bb"}.fa-spotify:before{content:"\f1bc"}.fa-deviantart:before{content:"\f1bd"}.fa-soundcloud:before{content:"\f1be"}.fa-database:before{content:"\f1c0"}.fa-file-pdf-o:before{content:"\f1c1"}.fa-file-word-o:before{content:"\f1c2"}.fa-file-excel-o:before{content:"\f1c3"}.fa-file-powerpoint-o:before{content:"\f1c4"}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:"\f1c5"}.fa-file-zip-o:before,.fa-file-archive-o:before{content:"\f1c6"}.fa-file-sound-o:before,.fa-file-audio-o:before{content:"\f1c7"}.fa-file-movie-o:before,.fa-file-video-o:before{content:"\f1c8"}.fa-file-code-o:before{content:"\f1c9"}.fa-vine:before{content:"\f1ca"}.fa-codepen:before{content:"\f1cb"}.fa-jsfiddle:before{content:"\f1cc"}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:"\f1cd"}.fa-circle-o-notch:before{content:"\f1ce"}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:"\f1d0"}.fa-ge:before,.fa-empire:before{content:"\f1d1"}.fa-git-square:before{content:"\f1d2"}.fa-git:before{content:"\f1d3"}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:"\f1d4"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-qq:before{content:"\f1d6"}.fa-wechat:before,.fa-weixin:before{content:"\f1d7"}.fa-send:before,.fa-paper-plane:before{content:"\f1d8"}.fa-send-o:before,.fa-paper-plane-o:before{content:"\f1d9"}.fa-history:before{content:"\f1da"}.fa-circle-thin:before{content:"\f1db"}.fa-header:before{content:"\f1dc"}.fa-paragraph:before{content:"\f1dd"}.fa-sliders:before{content:"\f1de"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-bomb:before{content:"\f1e2"}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:"\f1e3"}.fa-tty:before{content:"\f1e4"}.fa-binoculars:before{content:"\f1e5"}.fa-plug:before{content:"\f1e6"}.fa-slideshare:before{content:"\f1e7"}.fa-twitch:before{content:"\f1e8"}.fa-yelp:before{content:"\f1e9"}.fa-newspaper-o:before{content:"\f1ea"}.fa-wifi:before{content:"\f1eb"}.fa-calculator:before{content:"\f1ec"}.fa-paypal:before{content:"\f1ed"}.fa-google-wallet:before{content:"\f1ee"}.fa-cc-visa:before{content:"\f1f0"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-bell-slash:before{content:"\f1f6"}.fa-bell-slash-o:before{content:"\f1f7"}.fa-trash:before{content:"\f1f8"}.fa-copyright:before{content:"\f1f9"}.fa-at:before{content:"\f1fa"}.fa-eyedropper:before{content:"\f1fb"}.fa-paint-brush:before{content:"\f1fc"}.fa-birthday-cake:before{content:"\f1fd"}.fa-area-chart:before{content:"\f1fe"}.fa-pie-chart:before{content:"\f200"}.fa-line-chart:before{content:"\f201"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-bicycle:before{content:"\f206"}.fa-bus:before{content:"\f207"}.fa-ioxhost:before{content:"\f208"}.fa-angellist:before{content:"\f209"}.fa-cc:before{content:"\f20a"}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:"\f20b"}.fa-meanpath:before{content:"\f20c"}.fa-buysellads:before{content:"\f20d"}.fa-connectdevelop:before{content:"\f20e"}.fa-dashcube:before{content:"\f210"}.fa-forumbee:before{content:"\f211"}.fa-leanpub:before{content:"\f212"}.fa-sellsy:before{content:"\f213"}.fa-shirtsinbulk:before{content:"\f214"}.fa-simplybuilt:before{content:"\f215"}.fa-skyatlas:before{content:"\f216"}.fa-cart-plus:before{content:"\f217"}.fa-cart-arrow-down:before{content:"\f218"}.fa-diamond:before{content:"\f219"}.fa-ship:before{content:"\f21a"}.fa-user-secret:before{content:"\f21b"}.fa-motorcycle:before{content:"\f21c"}.fa-street-view:before{content:"\f21d"}.fa-heartbeat:before{content:"\f21e"}.fa-venus:before{content:"\f221"}.fa-mars:before{content:"\f222"}.fa-mercury:before{content:"\f223"}.fa-intersex:before,.fa-transgender:before{content:"\f224"}.fa-transgender-alt:before{content:"\f225"}.fa-venus-double:before{content:"\f226"}.fa-mars-double:before{content:"\f227"}.fa-venus-mars:before{content:"\f228"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-v:before{content:"\f22a"}.fa-mars-stroke-h:before{content:"\f22b"}.fa-neuter:before{content:"\f22c"}.fa-genderless:before{content:"\f22d"}.fa-facebook-official:before{content:"\f230"}.fa-pinterest-p:before{content:"\f231"}.fa-whatsapp:before{content:"\f232"}.fa-server:before{content:"\f233"}.fa-user-plus:before{content:"\f234"}.fa-user-times:before{content:"\f235"}.fa-hotel:before,.fa-bed:before{content:"\f236"}.fa-viacoin:before{content:"\f237"}.fa-train:before{content:"\f238"}.fa-subway:before{content:"\f239"}.fa-medium:before{content:"\f23a"}.fa-yc:before,.fa-y-combinator:before{content:"\f23b"}.fa-optin-monster:before{content:"\f23c"}.fa-opencart:before{content:"\f23d"}.fa-expeditedssl:before{content:"\f23e"}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:"\f240"}.fa-battery-3:before,.fa-battery-three-quarters:before{content:"\f241"}.fa-battery-2:before,.fa-battery-half:before{content:"\f242"}.fa-battery-1:before,.fa-battery-quarter:before{content:"\f243"}.fa-battery-0:before,.fa-battery-empty:before{content:"\f244"}.fa-mouse-pointer:before{content:"\f245"}.fa-i-cursor:before{content:"\f246"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-sticky-note:before{content:"\f249"}.fa-sticky-note-o:before{content:"\f24a"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-diners-club:before{content:"\f24c"}.fa-clone:before{content:"\f24d"}.fa-balance-scale:before{content:"\f24e"}.fa-hourglass-o:before{content:"\f250"}.fa-hourglass-1:before,.fa-hourglass-start:before{content:"\f251"}.fa-hourglass-2:before,.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-3:before,.fa-hourglass-end:before{content:"\f253"}.fa-hourglass:before{content:"\f254"}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:"\f255"}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:"\f256"}.fa-hand-scissors-o:before{content:"\f257"}.fa-hand-lizard-o:before{content:"\f258"}.fa-hand-spock-o:before{content:"\f259"}.fa-hand-pointer-o:before{content:"\f25a"}.fa-hand-peace-o:before{content:"\f25b"}.fa-trademark:before{content:"\f25c"}.fa-registered:before{content:"\f25d"}.fa-creative-commons:before{content:"\f25e"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-tripadvisor:before{content:"\f262"}.fa-odnoklassniki:before{content:"\f263"}.fa-odnoklassniki-square:before{content:"\f264"}.fa-get-pocket:before{content:"\f265"}.fa-wikipedia-w:before{content:"\f266"}.fa-safari:before{content:"\f267"}.fa-chrome:before{content:"\f268"}.fa-firefox:before{content:"\f269"}.fa-opera:before{content:"\f26a"}.fa-internet-explorer:before{content:"\f26b"}.fa-tv:before,.fa-television:before{content:"\f26c"}.fa-contao:before{content:"\f26d"}.fa-500px:before{content:"\f26e"}.fa-amazon:before{content:"\f270"}.fa-calendar-plus-o:before{content:"\f271"}.fa-calendar-minus-o:before{content:"\f272"}.fa-calendar-times-o:before{content:"\f273"}.fa-calendar-check-o:before{content:"\f274"}.fa-industry:before{content:"\f275"}.fa-map-pin:before{content:"\f276"}.fa-map-signs:before{content:"\f277"}.fa-map-o:before{content:"\f278"}.fa-map:before{content:"\f279"}.fa-commenting:before{content:"\f27a"}.fa-commenting-o:before{content:"\f27b"}.fa-houzz:before{content:"\f27c"}.fa-vimeo:before{content:"\f27d"}.fa-black-tie:before{content:"\f27e"}.fa-fonticons:before{content:"\f280"}.fa-reddit-alien:before{content:"\f281"}.fa-edge:before{content:"\f282"}.fa-credit-card-alt:before{content:"\f283"}.fa-codiepie:before{content:"\f284"}.fa-modx:before{content:"\f285"}.fa-fort-awesome:before{content:"\f286"}.fa-usb:before{content:"\f287"}.fa-product-hunt:before{content:"\f288"}.fa-mixcloud:before{content:"\f289"}.fa-scribd:before{content:"\f28a"}.fa-pause-circle:before{content:"\f28b"}.fa-pause-circle-o:before{content:"\f28c"}.fa-stop-circle:before{content:"\f28d"}.fa-stop-circle-o:before{content:"\f28e"}.fa-shopping-bag:before{content:"\f290"}.fa-shopping-basket:before{content:"\f291"}.fa-hashtag:before{content:"\f292"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-percent:before{content:"\f295"}.fa-gitlab:before{content:"\f296"}.fa-wpbeginner:before{content:"\f297"}.fa-wpforms:before{content:"\f298"}.fa-envira:before{content:"\f299"}.fa-universal-access:before{content:"\f29a"}.fa-wheelchair-alt:before{content:"\f29b"}.fa-question-circle-o:before{content:"\f29c"}.fa-blind:before{content:"\f29d"}.fa-audio-description:before{content:"\f29e"}.fa-volume-control-phone:before{content:"\f2a0"}.fa-braille:before{content:"\f2a1"}.fa-assistive-listening-systems:before{content:"\f2a2"}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:"\f2a3"}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:"\f2a4"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-signing:before,.fa-sign-language:before{content:"\f2a7"}.fa-low-vision:before{content:"\f2a8"}.fa-viadeo:before{content:"\f2a9"}.fa-viadeo-square:before{content:"\f2aa"}.fa-snapchat:before{content:"\f2ab"}.fa-snapchat-ghost:before{content:"\f2ac"}.fa-snapchat-square:before{content:"\f2ad"}.fa-pied-piper:before{content:"\f2ae"}.fa-first-order:before{content:"\f2b0"}.fa-yoast:before{content:"\f2b1"}.fa-themeisle:before{content:"\f2b2"}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:"\f2b3"}.fa-fa:before,.fa-font-awesome:before{content:"\f2b4"}.fa-handshake-o:before{content:"\f2b5"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-open-o:before{content:"\f2b7"}.fa-linode:before{content:"\f2b8"}.fa-address-book:before{content:"\f2b9"}.fa-address-book-o:before{content:"\f2ba"}.fa-vcard:before,.fa-address-card:before{content:"\f2bb"}.fa-vcard-o:before,.fa-address-card-o:before{content:"\f2bc"}.fa-user-circle:before{content:"\f2bd"}.fa-user-circle-o:before{content:"\f2be"}.fa-user-o:before{content:"\f2c0"}.fa-id-badge:before{content:"\f2c1"}.fa-drivers-license:before,.fa-id-card:before{content:"\f2c2"}.fa-drivers-license-o:before,.fa-id-card-o:before{content:"\f2c3"}.fa-quora:before{content:"\f2c4"}.fa-free-code-camp:before{content:"\f2c5"}.fa-telegram:before{content:"\f2c6"}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:"\f2c7"}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-thermometer-2:before,.fa-thermometer-half:before{content:"\f2c9"}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:"\f2ca"}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:"\f2cb"}.fa-shower:before{content:"\f2cc"}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:"\f2cd"}.fa-podcast:before{content:"\f2ce"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-times-rectangle:before,.fa-window-close:before{content:"\f2d3"}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:"\f2d4"}.fa-bandcamp:before{content:"\f2d5"}.fa-grav:before{content:"\f2d6"}.fa-etsy:before{content:"\f2d7"}.fa-imdb:before{content:"\f2d8"}.fa-ravelry:before{content:"\f2d9"}.fa-eercast:before{content:"\f2da"}.fa-microchip:before{content:"\f2db"}.fa-snowflake-o:before{content:"\f2dc"}.fa-superpowers:before{content:"\f2dd"}.fa-wpexplorer:before{content:"\f2de"}.fa-meetup:before{content:"\f2e0"}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}
/*!
* Viewer.js v1.3.5
* https://fengyuanchen.github.io/viewerjs
*
* Copyright 2015-present Chen Fengyuan
* Released under the MIT license
*
* Date: 2019-07-04T11:00:13.705Z
*/
.viewer-zoom-in::before,
.viewer-zoom-out::before,
.viewer-one-to-one::before,
.viewer-reset::before,
.viewer-prev::before,
.viewer-play::before,
.viewer-next::before,
.viewer-rotate-left::before,
.viewer-rotate-right::before,
.viewer-flip-horizontal::before,
.viewer-flip-vertical::before,
.viewer-fullscreen::before,
.viewer-fullscreen-exit::before,
.viewer-close::before {
background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAARgAAAAUCAYAAABWOyJDAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAABx0RVh0U29mdHdhcmUAQWRvYmUgRmlyZXdvcmtzIENTNui8sowAAAQPSURBVHic7Zs/iFxVFMa/0U2UaJGksUgnIVhYxVhpjDbZCBmLdAYECxsRFBTUamcXUiSNncgKQbSxsxH8gzAP3FU2jY0kKKJNiiiIghFlccnP4p3nPCdv3p9778vsLOcHB2bfveeb7955c3jvvNkBIMdxnD64a94GHMfZu3iBcRynN7zAOI7TG15gHCeeNUkr8zaxG2lbYDYsdgMbktBsP03jdQwljSXdtBhLOmtjowC9Mg9L+knSlcD8TNKpSA9lBpK2JF2VdDSR5n5J64m0qli399hNFMUlpshQii5jbXTbHGviB0nLNeNDSd9VO4A2UdB2fp+x0eCnaXxWXGA2X0au/3HgN9P4LFCjIANOJdrLr0zzZ+BEpNYDwKbpnQMeAw4m8HjQtM6Z9qa917zPQwFr3M5KgA6J5rTJCdFZJj9/lyvGhsDvwFNVuV2MhhjrK6b9bFiE+j1r87eBl4HDwCF7/U/k+ofAX5b/EXBv5JoLMuILzf3Ap6Z3EzgdqHMCuF7hcQf4HDgeoHnccncqdK/TvSDWffFXI/exICY/xZyqc6XLWF1UFZna4gJ7q8BsRvgd2/xXpo6P+D9dfT7PpECtA3cnWPM0GXGFZh/wgWltA+cDNC7X+AP4GzjZQe+k5dRxuYPeiuXU7e1qwLpDz7dFjXKRaSwuMLvAlG8zZlG+YmiK1HoFqT7wP2z+4Q45TfEGcMt01xLoNZEBTwRqD4BLpnMLeC1A41UmVxsXgXeBayV/Wx20rpTyrpnWRft7p6O/FdqzGrDukPNtkaMoMo3FBdBSQMOnYBCReyf05s126fU9ytfX98+mY54Kxnp7S9K3kj6U9KYdG0h6UdLbkh7poFXMfUnSOyVvL0h6VtIXHbS6nOP+s/Zm9mvyXW1uuC9ohZ72E9uDmXWLJOB1GxsH+DxPftsB8B6wlGDN02TAkxG6+4D3TWsbeC5CS8CDFce+AW500LhhOW2020TRjK3b21HEmgti9m0RonxbdMZeVzV+/4tF3cBpP7E9mKHNL5q8h5g0eYsCMQz0epq8gQrwMXAgcs0FGXGFRcB9wCemF9PkbYqM/Bas7fxLwNeJPdTdpo4itQti8lPMqTpXuozVRVXPpbHI3KkNTB1NfkL81j2mvhDp91HgV9MKuRIqrykj3WPq4rHyL+axj8/qGPmTqi6F9YDlHOvJU6oYcTsh/TYSzWmTE6JT19CtLTJt32D6CmHe0eQn1O8z5AXgT4sx4Vcu0/EQecMydB8z0hUWkTd2t4CrwNEePqMBcAR4mrBbwyXLPWJa8zrXmmLEhNBmfpkuY2102xxrih+pb+ieAb6vGhuA97UcJ5KR8gZ77K+99xxeYBzH6Q3/Z0fHcXrDC4zjOL3hBcZxnN74F+zlvXFWXF9PAAAAAElFTkSuQmCC');
background-repeat: no-repeat;
background-size: 280px;
color: transparent;
display: block;
font-size: 0;
height: 20px;
line-height: 0;
width: 20px;
}
.viewer-zoom-in::before {
background-position: 0 0;
content: 'Zoom In';
}
.viewer-zoom-out::before {
background-position: -20px 0;
content: 'Zoom Out';
}
.viewer-one-to-one::before {
background-position: -40px 0;
content: 'One to One';
}
.viewer-reset::before {
background-position: -60px 0;
content: 'Reset';
}
.viewer-prev::before {
background-position: -80px 0;
content: 'Previous';
}
.viewer-play::before {
background-position: -100px 0;
content: 'Play';
}
.viewer-next::before {
background-position: -120px 0;
content: 'Next';
}
.viewer-rotate-left::before {
background-position: -140px 0;
content: 'Rotate Left';
}
.viewer-rotate-right::before {
background-position: -160px 0;
content: 'Rotate Right';
}
.viewer-flip-horizontal::before {
background-position: -180px 0;
content: 'Flip Horizontal';
}
.viewer-flip-vertical::before {
background-position: -200px 0;
content: 'Flip Vertical';
}
.viewer-fullscreen::before {
background-position: -220px 0;
content: 'Enter Full Screen';
}
.viewer-fullscreen-exit::before {
background-position: -240px 0;
content: 'Exit Full Screen';
}
.viewer-close::before {
background-position: -260px 0;
content: 'Close';
}
.viewer-container {
bottom: 0;
direction: ltr;
font-size: 0;
left: 0;
line-height: 0;
overflow: hidden;
position: absolute;
right: 0;
-webkit-tap-highlight-color: transparent;
top: 0;
-ms-touch-action: none;
touch-action: none;
-webkit-touch-callout: none;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.viewer-container::-moz-selection,
.viewer-container *::-moz-selection {
background-color: transparent;
}
.viewer-container::selection,
.viewer-container *::selection {
background-color: transparent;
}
.viewer-container img {
display: block;
height: auto;
max-height: none !important;
max-width: none !important;
min-height: 0 !important;
min-width: 0 !important;
width: 100%;
}
.viewer-canvas {
bottom: 0;
left: 0;
overflow: hidden;
position: absolute;
right: 0;
top: 0;
}
.viewer-canvas > img {
height: auto;
margin: 15px auto;
max-width: 90% !important;
width: auto;
}
.viewer-footer {
bottom: 0;
left: 0;
overflow: hidden;
position: absolute;
right: 0;
text-align: center;
}
.viewer-navbar {
background-color: rgba(0, 0, 0, 0.5);
overflow: hidden;
}
.viewer-list {
-webkit-box-sizing: content-box;
box-sizing: content-box;
height: 50px;
margin: 0;
overflow: hidden;
padding: 1px 0;
}
.viewer-list > li {
color: transparent;
cursor: pointer;
float: left;
font-size: 0;
height: 50px;
line-height: 0;
opacity: 0.5;
overflow: hidden;
-webkit-transition: opacity 0.15s;
transition: opacity 0.15s;
width: 30px;
}
.viewer-list > li:hover {
opacity: 0.75;
}
.viewer-list > li + li {
margin-left: 1px;
}
.viewer-list > .viewer-loading {
position: relative;
}
.viewer-list > .viewer-loading::after {
border-width: 2px;
height: 20px;
margin-left: -10px;
margin-top: -10px;
width: 20px;
}
.viewer-list > .viewer-active,
.viewer-list > .viewer-active:hover {
opacity: 1;
}
.viewer-player {
background-color: #000;
bottom: 0;
cursor: none;
display: none;
left: 0;
position: absolute;
right: 0;
top: 0;
}
.viewer-player > img {
left: 0;
position: absolute;
top: 0;
}
.viewer-toolbar > ul {
display: inline-block;
margin: 0 auto 5px;
overflow: hidden;
padding: 3px 0;
}
.viewer-toolbar > ul > li {
background-color: rgba(0, 0, 0, 0.5);
border-radius: 50%;
cursor: pointer;
float: left;
height: 24px;
overflow: hidden;
-webkit-transition: background-color 0.15s;
transition: background-color 0.15s;
width: 24px;
}
.viewer-toolbar > ul > li:hover {
background-color: rgba(0, 0, 0, 0.8);
}
.viewer-toolbar > ul > li::before {
margin: 2px;
}
.viewer-toolbar > ul > li + li {
margin-left: 1px;
}
.viewer-toolbar > ul > .viewer-small {
height: 18px;
margin-bottom: 3px;
margin-top: 3px;
width: 18px;
}
.viewer-toolbar > ul > .viewer-small::before {
margin: -1px;
}
.viewer-toolbar > ul > .viewer-large {
height: 30px;
margin-bottom: -3px;
margin-top: -3px;
width: 30px;
}
.viewer-toolbar > ul > .viewer-large::before {
margin: 5px;
}
.viewer-tooltip {
background-color: rgba(0, 0, 0, 0.8);
border-radius: 10px;
color: #fff;
display: none;
font-size: 12px;
height: 20px;
left: 50%;
line-height: 20px;
margin-left: -25px;
margin-top: -10px;
position: absolute;
text-align: center;
top: 50%;
width: 50px;
}
.viewer-title {
color: #ccc;
display: inline-block;
font-size: 12px;
line-height: 1;
margin: 0 5% 5px;
max-width: 90%;
opacity: 0.8;
overflow: hidden;
text-overflow: ellipsis;
-webkit-transition: opacity 0.15s;
transition: opacity 0.15s;
white-space: nowrap;
}
.viewer-title:hover {
opacity: 1;
}
.viewer-button {
background-color: rgba(0, 0, 0, 0.5);
border-radius: 50%;
cursor: pointer;
height: 80px;
overflow: hidden;
position: absolute;
right: -40px;
top: -40px;
-webkit-transition: background-color 0.15s;
transition: background-color 0.15s;
width: 80px;
}
.viewer-button:focus,
.viewer-button:hover {
background-color: rgba(0, 0, 0, 0.8);
}
.viewer-button::before {
bottom: 15px;
left: 15px;
position: absolute;
}
.viewer-fixed {
position: fixed;
}
.viewer-open {
overflow: hidden;
}
.viewer-show {
display: block;
}
.viewer-hide {
display: none;
}
.viewer-backdrop {
background-color: rgba(0, 0, 0, 0.5);
}
.viewer-invisible {
visibility: hidden;
}
.viewer-move {
cursor: move;
cursor: -webkit-grab;
cursor: grab;
}
.viewer-fade {
opacity: 0;
}
.viewer-in {
opacity: 1;
}
.viewer-transition {
-webkit-transition: all 0.3s;
transition: all 0.3s;
}
@-webkit-keyframes viewer-spinner {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes viewer-spinner {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
.viewer-loading::after {
-webkit-animation: viewer-spinner 1s linear infinite;
animation: viewer-spinner 1s linear infinite;
border: 4px solid rgba(255, 255, 255, 0.1);
border-left-color: rgba(255, 255, 255, 0.5);
border-radius: 50%;
content: '';
display: inline-block;
height: 40px;
left: 50%;
margin-left: -20px;
margin-top: -20px;
position: absolute;
top: 50%;
width: 40px;
z-index: 1;
}
@media (max-width: 767px) {
.viewer-hide-xs-down {
display: none;
}
}
@media (max-width: 991px) {
.viewer-hide-sm-down {
display: none;
}
}
@media (max-width: 1199px) {
.viewer-hide-md-down {
display: none;
}
}
/*! jQuery v3.4.1 -ajax,-ajax/jsonp,-ajax/load,-ajax/parseXML,-ajax/script,-ajax/var/location,-ajax/var/nonce,-ajax/var/rquery,-ajax/xhr,-manipulation/_evalUrl,-event/ajax,-effects,-effects/Tween,-effects/animatedSelector | (c) JS Foundation and other contributors | jquery.org/license */
!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(g,e){"use strict";var t=[],v=g.document,r=Object.getPrototypeOf,s=t.slice,y=t.concat,u=t.push,i=t.indexOf,n={},o=n.toString,m=n.hasOwnProperty,a=m.toString,l=a.call(Object),b={},x=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},w=function(e){return null!=e&&e===e.window},c={type:!0,src:!0,nonce:!0,noModule:!0};function C(e,t,n){var r,i,o=(n=n||v).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function T(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.4.1 -ajax,-ajax/jsonp,-ajax/load,-ajax/parseXML,-ajax/script,-ajax/var/location,-ajax/var/nonce,-ajax/var/rquery,-ajax/xhr,-manipulation/_evalUrl,-event/ajax,-effects,-effects/Tween,-effects/animatedSelector",E=function(e,t){return new E.fn.init(e,t)},d=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function p(e){var t=!!e&&"length"in e&&e.length,n=T(e);return!x(e)&&!w(e)&&("array"===n||0===t||"number"==typeof t&&0<t&&t-1 in e)}E.fn=E.prototype={jquery:f,constructor:E,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=E.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return E.each(this,e)},map:function(n){return this.pushStack(E.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},E.extend=E.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||x(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],"__proto__"!==t&&a!==r&&(l&&r&&(E.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||E.isPlainObject(n)?n:{},i=!1,a[t]=E.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},E.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==o.call(e))&&(!(t=r(e))||"function"==typeof(n=m.call(t,"constructor")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t){C(e,{nonce:t&&t.nonce})},each:function(e,t){var n,r=0;if(p(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},trim:function(e){return null==e?"":(e+"").replace(d,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(p(Object(e))?E.merge(n,"string"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,o=0,a=[];if(p(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return y.apply([],a)},guid:1,support:b}),"function"==typeof Symbol&&(E.fn[Symbol.iterator]=t[Symbol.iterator]),E.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){n["[object "+t+"]"]=t.toLowerCase()});var h=function(n){var e,p,x,o,i,h,f,g,w,u,l,C,T,a,E,v,s,c,y,N="sizzle"+1*new Date,m=n.document,A=0,r=0,d=ue(),b=ue(),k=ue(),S=ue(),D=function(e,t){return e===t&&(l=!0),0},L={}.hasOwnProperty,t=[],j=t.pop,q=t.push,O=t.push,P=t.slice,H=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},I="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",R="[\\x20\\t\\r\\n\\f]",B="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",M="\\["+R+"*("+B+")(?:"+R+"*([*^$|!~]?=)"+R+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+B+"))|)"+R+"*\\]",W=":("+B+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+M+")*)|.*)\\)|)",$=new RegExp(R+"+","g"),F=new RegExp("^"+R+"+|((?:^|[^\\\\])(?:\\\\.)*)"+R+"+$","g"),z=new RegExp("^"+R+"*,"+R+"*"),_=new RegExp("^"+R+"*([>+~]|"+R+")"+R+"*"),U=new RegExp(R+"|>"),V=new RegExp(W),X=new RegExp("^"+B+"$"),Q={ID:new RegExp("^#("+B+")"),CLASS:new RegExp("^\\.("+B+")"),TAG:new RegExp("^("+B+"|[*])"),ATTR:new RegExp("^"+M),PSEUDO:new RegExp("^"+W),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+R+"*(even|odd|(([+-]|)(\\d*)n|)"+R+"*(?:([+-]|)"+R+"*(\\d+)|))"+R+"*\\)|)","i"),bool:new RegExp("^(?:"+I+")$","i"),needsContext:new RegExp("^"+R+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+R+"*((?:-\\d)?\\d*)"+R+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,G=/^(?:input|select|textarea|button)$/i,K=/^h\d$/i,J=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\([\\da-f]{1,6}"+R+"?|("+R+")|.)","ig"),ne=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){C()},ae=xe(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{O.apply(t=P.call(m.childNodes),m.childNodes),t[m.childNodes.length].nodeType}catch(e){O={apply:t.length?function(e,t){q.apply(e,P.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,d=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==d&&9!==d&&11!==d)return n;if(!r&&((e?e.ownerDocument||e:m)!==T&&C(e),e=e||T,E)){if(11!==d&&(u=Z.exec(t)))if(i=u[1]){if(9===d){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return O.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&p.getElementsByClassName&&e.getElementsByClassName)return O.apply(n,e.getElementsByClassName(i)),n}if(p.qsa&&!S[t+" "]&&(!v||!v.test(t))&&(1!==d||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===d&&U.test(t)){(s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=N),o=(l=h(t)).length;while(o--)l[o]="#"+s+" "+be(l[o]);c=l.join(","),f=ee.test(t)&&ye(e.parentNode)||e}try{return O.apply(n,f.querySelectorAll(c)),n}catch(e){S(t,!0)}finally{s===N&&e.removeAttribute("id")}}}return g(t.replace(F,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>x.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[N]=!0,e}function ce(e){var t=T.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)x.attrHandle[n[r]]=t}function de(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function pe(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in p=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},C=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:m;return r!==T&&9===r.nodeType&&r.documentElement&&(a=(T=r).documentElement,E=!i(T),m!==T&&(n=T.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),p.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),p.getElementsByTagName=ce(function(e){return e.appendChild(T.createComment("")),!e.getElementsByTagName("*").length}),p.getElementsByClassName=J.test(T.getElementsByClassName),p.getById=ce(function(e){return a.appendChild(e).id=N,!T.getElementsByName||!T.getElementsByName(N).length}),p.getById?(x.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},x.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(x.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},x.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),x.find.TAG=p.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):p.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},x.find.CLASS=p.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(p.qsa=J.test(T.querySelectorAll))&&(ce(function(e){a.appendChild(e).innerHTML="<a id='"+N+"'></a><select id='"+N+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+R+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+R+"*(?:value|"+I+")"),e.querySelectorAll("[id~="+N+"-]").length||v.push("~="),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+N+"+*").length||v.push(".#.+[+~]")}),ce(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=T.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+R+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(p.matchesSelector=J.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){p.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",W)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=J.test(a.compareDocumentPosition),y=t||J.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!p.sortDetached&&t.compareDocumentPosition(e)===n?e===T||e.ownerDocument===m&&y(m,e)?-1:t===T||t.ownerDocument===m&&y(m,t)?1:u?H(u,e)-H(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===T?-1:t===T?1:i?-1:o?1:u?H(u,e)-H(u,t):0;if(i===o)return de(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?de(a[r],s[r]):a[r]===m?-1:s[r]===m?1:0}),T},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==T&&C(e),p.matchesSelector&&E&&!S[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||p.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){S(t,!0)}return 0<se(t,T,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!==T&&C(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!==T&&C(e);var n=x.attrHandle[t.toLowerCase()],r=n&&L.call(x.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:p.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+"").replace(re,ie)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!p.detectDuplicates,u=!p.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else while(t=e[r++])n+=o(t);return n},(x=se.selectors={cacheLength:50,createPseudo:le,match:Q,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return Q.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&V.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=d[e+" "];return t||(t=new RegExp("(^|"+R+")"+e+"("+R+"|$)"))&&d(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1<t.indexOf(i):"$="===r?i&&t.slice(-i.length)===i:"~="===r?-1<(" "+t.replace($," ")+" ").indexOf(i):"|="===r&&(t===i||t.slice(0,i.length+1)===i+"-"))}},CHILD:function(h,e,t,g,v){var y="nth"!==h.slice(0,3),m="last"!==h.slice(-4),b="of-type"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?"nextSibling":"previousSibling",c=e.parentNode,f=b&&e.nodeName.toLowerCase(),d=!n&&!b,p=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(b?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l="only"===h&&!u&&"nextSibling"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&d){p=(s=(r=(i=(o=(a=c)[N]||(a[N]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===A&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(p=s=0)||u.pop())if(1===a.nodeType&&++p&&a===e){i[h]=[A,s,p];break}}else if(d&&(p=s=(r=(i=(o=(a=e)[N]||(a[N]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===A&&r[1]),!1===p)while(a=++s&&a&&a[l]||(p=s=0)||u.pop())if((b?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++p&&(d&&((i=(o=a[N]||(a[N]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[A,p]),a===e))break;return(p-=v)===g||p%g==0&&0<=p/g}}},PSEUDO:function(e,o){var t,a=x.pseudos[e]||x.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return a[N]?a(o):1<a.length?(t=[e,e,"",o],x.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=H(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace(F,"$1"));return s[N]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return X.test(n||"")||se.error("unsupported lang: "+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(t=t.toLowerCase())===n||0===t.indexOf(n+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===a},focus:function(e){return e===T.activeElement&&(!T.hasFocus||T.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!x.pseudos.empty(e)},header:function(e){return K.test(e.nodeName)},input:function(e){return G.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=x.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})x.pseudos[e]=pe(e);for(e in{submit:!0,reset:!0})x.pseudos[e]=he(e);function me(){}function be(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function xe(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&"parentNode"===c,d=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[A,d];if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[N]||(e[N]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===A&&r[1]===d)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Ce(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Te(p,h,g,v,y,e){return v&&!v[N]&&(v=Te(v)),y&&!y[N]&&(y=Te(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||"*",n.nodeType?[n]:n,[]),f=!p||!e&&h?c:Ce(c,s,p,n,r),d=g?y||(e?p:l||v)?[]:t:f;if(g&&g(f,d,n,r),v){i=Ce(d,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(d[u[o]]=!(f[u[o]]=a))}if(e){if(y||p){if(y){i=[],o=d.length;while(o--)(a=d[o])&&i.push(f[o]=a);y(null,d=[],i,r)}o=d.length;while(o--)(a=d[o])&&-1<(i=y?H(e,a):s[o])&&(e[i]=!(t[i]=a))}}else d=Ce(d===t?d.splice(l,d.length):d),y?y(null,t,d,r):O.apply(t,d)})}function Ee(e){for(var i,t,n,r=e.length,o=x.relative[e[0].type],a=o||x.relative[" "],s=o?1:0,u=xe(function(e){return e===i},a,!0),l=xe(function(e){return-1<H(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=x.relative[e[s].type])c=[xe(we(c),t)];else{if((t=x.filter[e[s].type].apply(null,e[s].matches))[N]){for(n=++s;n<r;n++)if(x.relative[e[n].type])break;return Te(1<s&&we(c),1<s&&be(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace(F,"$1"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&be(e))}c.push(t)}return we(c)}return me.prototype=x.filters=x.pseudos,x.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=b[e+" "];if(l)return t?0:l.slice(0);a=e,s=[],u=x.preFilter;while(a){for(o in n&&!(r=z.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=_.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace(F," ")}),a=a.slice(n.length)),x.filter)!(r=Q[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):b(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,b,r,i=[],o=[],a=k[e+" "];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[N]?i.push(a):o.push(a);(a=k(e,(v=o,m=0<(y=i).length,b=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l="0",c=e&&[],f=[],d=w,p=e||b&&x.find.TAG("*",i),h=A+=null==d?1:Math.random()||.1,g=p.length;for(i&&(w=t===T||t||i);l!==g&&null!=(o=p[l]);l++){if(b&&o){a=0,t||o.ownerDocument===T||(C(o),n=!E);while(s=v[a++])if(s(o,t||T,n)){r.push(o);break}i&&(A=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=j.call(r));f=Ce(f)}O.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(A=h,w=d),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l="function"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&"ID"===(a=o[0]).type&&9===t.nodeType&&E&&x.relative[o[1].type]){if(!(t=(x.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=Q.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],x.relative[s=a.type])break;if((u=x.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&be(o)))return O.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},p.sortStable=N.split("").sort(D).join("")===N,p.detectDuplicates=!!l,C(),p.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(T.createElement("fieldset"))}),ce(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||fe("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),p.attributes&&ce(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||fe("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute("disabled")})||fe(I,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(g);E.find=h,E.expr=h.selectors,E.expr[":"]=E.expr.pseudos,E.uniqueSort=E.unique=h.uniqueSort,E.text=h.getText,E.isXMLDoc=h.isXML,E.contains=h.contains,E.escapeSelector=h.escape;var N=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&E(e).is(n))break;r.push(e)}return r},A=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=E.expr.match.needsContext;function S(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var D=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function L(e,n,r){return x(n)?E.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?E.grep(e,function(e){return e===n!==r}):"string"!=typeof n?E.grep(e,function(e){return-1<i.call(n,e)!==r}):E.filter(n,e,r)}E.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?E.find.matchesSelector(r,e)?[r]:[]:E.find.matches(e,E.grep(t,function(e){return 1===e.nodeType}))},E.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(E(e).filter(function(){for(t=0;t<r;t++)if(E.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)E.find(e,i[t],n);return 1<r?E.uniqueSort(n):n},filter:function(e){return this.pushStack(L(this,e||[],!1))},not:function(e){return this.pushStack(L(this,e||[],!0))},is:function(e){return!!L(this,"string"==typeof e&&k.test(e)?E(e):e||[],!1).length}});var j,q=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(E.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof E?t[0]:t,E.merge(this,E.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:v,!0)),D.test(r[1])&&E.isPlainObject(t))for(r in t)x(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=v.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):x(e)?void 0!==n.ready?n.ready(e):e(E):E.makeArray(e,this)}).prototype=E.fn,j=E(v);var O=/^(?:parents|prev(?:Until|All))/,P={children:!0,contents:!0,next:!0,prev:!0};function H(e,t){while((e=e[t])&&1!==e.nodeType);return e}E.fn.extend({has:function(e){var t=E(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(E.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&E(e);if(!k.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&E.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?E.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?i.call(E(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(E.uniqueSort(E.merge(this.get(),E(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),E.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return N(e,"parentNode")},parentsUntil:function(e,t,n){return N(e,"parentNode",n)},next:function(e){return H(e,"nextSibling")},prev:function(e){return H(e,"previousSibling")},nextAll:function(e){return N(e,"nextSibling")},prevAll:function(e){return N(e,"previousSibling")},nextUntil:function(e,t,n){return N(e,"nextSibling",n)},prevUntil:function(e,t,n){return N(e,"previousSibling",n)},siblings:function(e){return A((e.parentNode||{}).firstChild,e)},children:function(e){return A(e.firstChild)},contents:function(e){return"undefined"!=typeof e.contentDocument?e.contentDocument:(S(e,"template")&&(e=e.content||e),E.merge([],e.childNodes))}},function(r,i){E.fn[r]=function(e,t){var n=E.map(this,i,e);return"Until"!==r.slice(-5)&&(t=e),t&&"string"==typeof t&&(n=E.filter(t,n)),1<this.length&&(P[r]||E.uniqueSort(n),O.test(r)&&n.reverse()),this.pushStack(n)}});var I=/[^\x20\t\r\n\f]+/g;function R(e){return e}function B(e){throw e}function M(e,t,n,r){var i;try{e&&x(i=e.promise)?i.call(e).done(t).fail(n):e&&x(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}E.Callbacks=function(r){var e,n;r="string"==typeof r?(e=r,n={},E.each(e.match(I)||[],function(e,t){n[t]=!0}),n):E.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:"")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){E.each(e,function(e,t){x(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&"string"!==T(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return E.each(arguments,function(e,t){var n;while(-1<(n=E.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<E.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t="",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=""),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},E.extend({Deferred:function(e){var o=[["notify","progress",E.Callbacks("memory"),E.Callbacks("memory"),2],["resolve","done",E.Callbacks("once memory"),E.Callbacks("once memory"),0,"resolved"],["reject","fail",E.Callbacks("once memory"),E.Callbacks("once memory"),1,"rejected"]],i="pending",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},"catch":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return E.Deferred(function(r){E.each(o,function(e,t){var n=x(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&x(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+"With"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError("Thenable self-resolution");t=e&&("object"==typeof e||"function"==typeof e)&&e.then,x(t)?s?t.call(e,l(u,o,R,s),l(u,o,B,s)):(u++,t.call(e,l(u,o,R,s),l(u,o,B,s),l(u,o,R,o.notifyWith))):(a!==R&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){E.Deferred.exceptionHook&&E.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==B&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(E.Deferred.getStackHook&&(t.stackTrace=E.Deferred.getStackHook()),g.setTimeout(t))}}return E.Deferred(function(e){o[0][3].add(l(0,e,x(r)?r:R,e.notifyWith)),o[1][3].add(l(0,e,x(t)?t:R)),o[2][3].add(l(0,e,x(n)?n:B))}).promise()},promise:function(e){return null!=e?E.extend(e,a):a}},s={};return E.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+"With"](this===s?void 0:this,arguments),this},s[t[0]+"With"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=E.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(M(e,o.done(a(t)).resolve,o.reject,!n),"pending"===o.state()||x(i[t]&&i[t].then)))return o.then();while(t--)M(i[t],a(t),o.reject);return o.promise()}});var W=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;E.Deferred.exceptionHook=function(e,t){g.console&&g.console.warn&&e&&W.test(e.name)&&g.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},E.readyException=function(e){g.setTimeout(function(){throw e})};var $=E.Deferred();function F(){v.removeEventListener("DOMContentLoaded",F),g.removeEventListener("load",F),E.ready()}E.fn.ready=function(e){return $.then(e)["catch"](function(e){E.readyException(e)}),this},E.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--E.readyWait:E.isReady)||(E.isReady=!0)!==e&&0<--E.readyWait||$.resolveWith(v,[E])}}),E.ready.then=$.then,"complete"===v.readyState||"loading"!==v.readyState&&!v.documentElement.doScroll?g.setTimeout(E.ready):(v.addEventListener("DOMContentLoaded",F),g.addEventListener("load",F));var z=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===T(n))for(s in i=!0,n)z(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,x(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(E(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},_=/^-ms-/,U=/-([a-z])/g;function V(e,t){return t.toUpperCase()}function X(e){return e.replace(_,"ms-").replace(U,V)}var Q=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function Y(){this.expando=E.expando+Y.uid++}Y.uid=1,Y.prototype={cache:function(e){var t=e[this.expando];return t||(t={},Q(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[X(t)]=n;else for(r in t)i[X(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][X(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(X):(t=X(t))in r?[t]:t.match(I)||[]).length;while(n--)delete r[t[n]]}(void 0===t||E.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!E.isEmptyObject(t)}};var G=new Y,K=new Y,J=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Z=/[A-Z]/g;function ee(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(Z,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n="true"===(i=n)||"false"!==i&&("null"===i?null:i===+i+""?+i:J.test(i)?JSON.parse(i):i)}catch(e){}K.set(e,t,n)}else n=void 0;return n}E.extend({hasData:function(e){return K.hasData(e)||G.hasData(e)},data:function(e,t,n){return K.access(e,t,n)},removeData:function(e,t){K.remove(e,t)},_data:function(e,t,n){return G.access(e,t,n)},_removeData:function(e,t){G.remove(e,t)}}),E.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=K.get(o),1===o.nodeType&&!G.get(o,"hasDataAttrs"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf("data-")&&(r=X(r.slice(5)),ee(o,r,i[r]));G.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof n?this.each(function(){K.set(this,n)}):z(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=K.get(o,n))?t:void 0!==(t=ee(o,n))?t:void 0;this.each(function(){K.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){K.remove(this,e)})}}),E.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=G.get(e,t),n&&(!r||Array.isArray(n)?r=G.access(e,t,E.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=E.queue(e,t),r=n.length,i=n.shift(),o=E._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,function(){E.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return G.get(e,n)||G.access(e,n,{empty:E.Callbacks("once memory").add(function(){G.remove(e,[t+"queue",n])})})}}),E.fn.extend({queue:function(t,n){var e=2;return"string"!=typeof t&&(n=t,t="fx",e--),arguments.length<e?E.queue(this[0],t):void 0===n?this:this.each(function(){var e=E.queue(this,t,n);E._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&E.dequeue(this,t)})},dequeue:function(e){return this.each(function(){E.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=E.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};"string"!=typeof e&&(t=e,e=void 0),e=e||"fx";while(a--)(n=G.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var te=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,ne=new RegExp("^(?:([+-])=|)("+te+")([a-z%]*)$","i"),re=["Top","Right","Bottom","Left"],ie=v.documentElement,oe=function(e){return E.contains(e.ownerDocument,e)},ae={composed:!0};ie.getRootNode&&(oe=function(e){return E.contains(e.ownerDocument,e)||e.getRootNode(ae)===e.ownerDocument});var se=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&oe(e)&&"none"===E.css(e,"display")},ue=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];for(o in i=n.apply(e,r||[]),t)e.style[o]=a[o];return i};var le={};function ce(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?("none"===n&&(l[c]=G.get(r,"display")||null,l[c]||(r.style.display="")),""===r.style.display&&se(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=le[s])||(o=a.body.appendChild(a.createElement(s)),u=E.css(o,"display"),o.parentNode.removeChild(o),"none"===u&&(u="block"),le[s]=u)))):"none"!==n&&(l[c]="none",G.set(r,"display",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}E.fn.extend({show:function(){return ce(this,!0)},hide:function(){return ce(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){se(this)?E(this).show():E(this).hide()})}});var fe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,pe=/^$|^module$|\/(?:java|ecma)script/i,he={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function ge(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&S(e,t)?E.merge([e],n):n}function ve(e,t){for(var n=0,r=e.length;n<r;n++)G.set(e[n],"globalEval",!t||G.get(t[n],"globalEval"))}he.optgroup=he.option,he.tbody=he.tfoot=he.colgroup=he.caption=he.thead,he.th=he.td;var ye,me,be=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),d=[],p=0,h=e.length;p<h;p++)if((o=e[p])||0===o)if("object"===T(o))E.merge(d,o.nodeType?[o]:o);else if(be.test(o)){a=a||f.appendChild(t.createElement("div")),s=(de.exec(o)||["",""])[1].toLowerCase(),u=he[s]||he._default,a.innerHTML=u[1]+E.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;E.merge(d,a.childNodes),(a=f.firstChild).textContent=""}else d.push(t.createTextNode(o));f.textContent="",p=0;while(o=d[p++])if(r&&-1<E.inArray(o,r))i&&i.push(o);else if(l=oe(o),a=ge(f.appendChild(o),"script"),l&&ve(a),n){c=0;while(o=a[c++])pe.test(o.type||"")&&n.push(o)}return f}ye=v.createDocumentFragment().appendChild(v.createElement("div")),(me=v.createElement("input")).setAttribute("type","radio"),me.setAttribute("checked","checked"),me.setAttribute("name","t"),ye.appendChild(me),b.checkClone=ye.cloneNode(!0).cloneNode(!0).lastChild.checked,ye.innerHTML="<textarea>x</textarea>",b.noCloneChecked=!!ye.cloneNode(!0).lastChild.defaultValue;var we=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Te=/^([^.]*)(?:\.(.+)|)/;function Ee(){return!0}function Ne(){return!1}function Ae(e,t){return e===function(){try{return v.activeElement}catch(e){}}()==("focus"===t)}function ke(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)ke(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Ne;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return E().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=E.guid++)),e.each(function(){E.event.add(this,t,i,r,n)})}function Se(e,i,o){o?(G.set(e,i,!1),E.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=G.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(E.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),G.set(this,i,r),t=o(this,i),this[i](),r!==(n=G.get(this,i))||t?G.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(G.set(this,i,{value:E.event.trigger(E.extend(r[0],E.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===G.get(e,i)&&E.event.add(e,i,Ee)}E.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,d,p,h,g,v=G.get(t);if(v){n.handler&&(n=(o=n).handler,i=o.selector),i&&E.find.matchesSelector(ie,i),n.guid||(n.guid=E.guid++),(u=v.events)||(u=v.events={}),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof E&&E.event.triggered!==e.type?E.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(I)||[""]).length;while(l--)p=g=(s=Te.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),p&&(f=E.event.special[p]||{},p=(i?f.delegateType:f.bindType)||p,f=E.event.special[p]||{},c=E.extend({type:p,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&E.expr.match.needsContext.test(i),namespace:h.join(".")},o),(d=u[p])||((d=u[p]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(p,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?d.splice(d.delegateCount++,0,c):d.push(c),E.event.global[p]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,d,p,h,g,v=G.hasData(e)&&G.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(I)||[""]).length;while(l--)if(p=g=(s=Te.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),p){f=E.event.special[p]||{},d=u[p=(r?f.delegateType:f.bindType)||p]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=d.length;while(o--)c=d[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(d.splice(o,1),c.selector&&d.delegateCount--,f.remove&&f.remove.call(e,c));a&&!d.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||E.removeEvent(e,p,v.handle),delete u[p])}else for(p in u)E.event.remove(e,p+t[l],n,r,!0);E.isEmptyObject(u)&&G.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=E.event.fix(e),u=new Array(arguments.length),l=(G.get(this,"events")||{})[s.type]||[],c=E.event.special[s.type]||{};for(u[0]=s,t=1;t<arguments.length;t++)u[t]=arguments[t];if(s.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,s)){a=E.event.handlers.call(this,s,l),t=0;while((i=a[t++])&&!s.isPropagationStopped()){s.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!s.isImmediatePropagationStopped())s.rnamespace&&!1!==o.namespace&&!s.rnamespace.test(o.namespace)||(s.handleObj=o,s.data=o.data,void 0!==(r=((E.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,u))&&!1===(s.result=r)&&(s.preventDefault(),s.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,s),s.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!("click"===e.type&&1<=e.button))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+" "]&&(a[i]=r.needsContext?-1<E(i,this).index(l):E.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(t,e){Object.defineProperty(E.Event.prototype,t,{enumerable:!0,configurable:!0,get:x(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[E.expando]?e:new E.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return fe.test(t.type)&&t.click&&S(t,"input")&&Se(t,"click",Ee),!1},trigger:function(e){var t=this||e;return fe.test(t.type)&&t.click&&S(t,"input")&&Se(t,"click"),!0},_default:function(e){var t=e.target;return fe.test(t.type)&&t.click&&S(t,"input")&&G.get(t,"click")||S(t,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},E.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},E.Event=function(e,t){if(!(this instanceof E.Event))return new E.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ee:Ne,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&E.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[E.expando]=!0},E.Event.prototype={constructor:E.Event,isDefaultPrevented:Ne,isPropagationStopped:Ne,isImmediatePropagationStopped:Ne,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ee,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ee,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ee,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},E.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&we.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&Ce.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},E.event.addProp),E.each({focus:"focusin",blur:"focusout"},function(e,t){E.event.special[e]={setup:function(){return Se(this,e,Ae),!1},trigger:function(){return Se(this,e),!0},delegateType:t}}),E.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,i){E.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||E.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),E.fn.extend({on:function(e,t,n,r){return ke(this,e,t,n,r)},one:function(e,t,n,r){return ke(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,E(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=Ne),this.each(function(){E.event.remove(this,e,n,t)})}});var De=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,Le=/<script|<style|<link/i,je=/checked\s*(?:[^=]|=\s*.checked.)/i,qe=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function Oe(e,t){return S(e,"table")&&S(11!==t.nodeType?t:t.firstChild,"tr")&&E(e).children("tbody")[0]||e}function Pe(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Ie(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(G.hasData(e)&&(o=G.access(e),a=G.set(t,o),l=o.events))for(i in delete a.handle,a.events={},l)for(n=0,r=l[i].length;n<r;n++)E.event.add(t,i,l[i][n]);K.hasData(e)&&(s=K.access(e),u=E.extend({},s),K.set(t,u))}}function Re(n,r,i,o){r=y.apply([],r);var e,t,a,s,u,l,c=0,f=n.length,d=f-1,p=r[0],h=x(p);if(h||1<f&&"string"==typeof p&&!b.checkClone&&je.test(p))return n.each(function(e){var t=n.eq(e);h&&(r[0]=p.call(this,e,t.html())),Re(t,r,i,o)});if(f&&(t=(e=xe(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=E.map(ge(e,"script"),Pe)).length;c<f;c++)u=e,c!==d&&(u=E.clone(u,!0,!0),s&&E.merge(a,ge(u,"script"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,E.map(a,He),c=0;c<s;c++)u=a[c],pe.test(u.type||"")&&!G.access(u,"globalEval")&&E.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?E._evalUrl&&!u.noModule&&E._evalUrl(u.src,{nonce:u.nonce||u.getAttribute("nonce")}):C(u.textContent.replace(qe,""),u,l))}return n}function Be(e,t,n){for(var r,i=t?E.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||E.cleanData(ge(r)),r.parentNode&&(n&&oe(r)&&ve(ge(r,"script")),r.parentNode.removeChild(r));return e}E.extend({htmlPrefilter:function(e){return e.replace(De,"<$1></$2>")},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=oe(e);if(!(b.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||E.isXMLDoc(e)))for(a=ge(c),r=0,i=(o=ge(e)).length;r<i;r++)s=o[r],u=a[r],void 0,"input"===(l=u.nodeName.toLowerCase())&&fe.test(s.type)?u.checked=s.checked:"input"!==l&&"textarea"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ge(e),a=a||ge(c),r=0,i=o.length;r<i;r++)Ie(o[r],a[r]);else Ie(e,c);return 0<(a=ge(c,"script")).length&&ve(a,!f&&ge(e,"script")),c},cleanData:function(e){for(var t,n,r,i=E.event.special,o=0;void 0!==(n=e[o]);o++)if(Q(n)){if(t=n[G.expando]){if(t.events)for(r in t.events)i[r]?E.event.remove(n,r):E.removeEvent(n,r,t.handle);n[G.expando]=void 0}n[K.expando]&&(n[K.expando]=void 0)}}}),E.fn.extend({detach:function(e){return Be(this,e,!0)},remove:function(e){return Be(this,e)},text:function(e){return z(this,function(e){return void 0===e?E.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return Re(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Oe(this,e).appendChild(e)})},prepend:function(){return Re(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Oe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Re(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Re(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(E.cleanData(ge(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return E.clone(this,e,t)})},html:function(e){return z(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Le.test(e)&&!he[(de.exec(e)||["",""])[1].toLowerCase()]){e=E.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(E.cleanData(ge(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Re(this,arguments,function(e){var t=this.parentNode;E.inArray(this,n)<0&&(E.cleanData(ge(this)),t&&t.replaceChild(e,this))},n)}}),E.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,a){E.fn[e]=function(e){for(var t,n=[],r=E(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),E(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var Me=new RegExp("^("+te+")(?!px)[a-z%]+$","i"),We=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=g),t.getComputedStyle(e)},$e=new RegExp(re.join("|"),"i");function Fe(e,t,n){var r,i,o,a,s=e.style;return(n=n||We(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||oe(e)||(a=E.style(e,t)),!b.pixelBoxStyles()&&Me.test(a)&&$e.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function ze(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function e(){if(u){s.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",u.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",ie.appendChild(s).appendChild(u);var e=g.getComputedStyle(u);n="1%"!==e.top,a=12===t(e.marginLeft),u.style.right="60%",o=36===t(e.right),r=36===t(e.width),u.style.position="absolute",i=12===t(u.offsetWidth/3),ie.removeChild(s),u=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s=v.createElement("div"),u=v.createElement("div");u.style&&(u.style.backgroundClip="content-box",u.cloneNode(!0).style.backgroundClip="",b.clearCloneStyle="content-box"===u.style.backgroundClip,E.extend(b,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),a},scrollboxSize:function(){return e(),i}}))}();var _e=["Webkit","Moz","ms"],Ue=v.createElement("div").style,Ve={};function Xe(e){var t=E.cssProps[e]||Ve[e];return t||(e in Ue?e:Ve[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=_e.length;while(n--)if((e=_e[n]+t)in Ue)return e}(e)||e)}var Qe,Ye,Ge=/^(none|table(?!-c[ea]).+)/,Ke=/^--/,Je={position:"absolute",visibility:"hidden",display:"block"},Ze={letterSpacing:"0",fontWeight:"400"};function et(e,t,n){var r=ne.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function tt(e,t,n,r,i,o){var a="width"===t?1:0,s=0,u=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(u+=E.css(e,n+re[a],!0,i)),r?("content"===n&&(u-=E.css(e,"padding"+re[a],!0,i)),"margin"!==n&&(u-=E.css(e,"border"+re[a]+"Width",!0,i))):(u+=E.css(e,"padding"+re[a],!0,i),"padding"!==n?u+=E.css(e,"border"+re[a]+"Width",!0,i):s+=E.css(e,"border"+re[a]+"Width",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function nt(e,t,n){var r=We(e),i=(!b.boxSizingReliable()||n)&&"border-box"===E.css(e,"boxSizing",!1,r),o=i,a=Fe(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(Me.test(a)){if(!n)return a;a="auto"}return(!b.boxSizingReliable()&&i||"auto"===a||!parseFloat(a)&&"inline"===E.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===E.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+tt(e,t,n||(i?"border":"content"),o,r,a)+"px"}E.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Fe(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=X(t),u=Ke.test(t),l=e.style;if(u||(t=Xe(s)),a=E.cssHooks[t]||E.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];"string"===(o=typeof n)&&(i=ne.exec(n))&&i[1]&&(n=function(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return E.css(e,t,"")},u=s(),l=n&&n[3]||(E.cssNumber[t]?"":"px"),c=e.nodeType&&(E.cssNumber[t]||"px"!==l&&+u)&&ne.exec(E.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)E.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,E.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}(e,t,i),o="number"),null!=n&&n==n&&("number"!==o||u||(n+=i&&i[3]||(E.cssNumber[s]?"":"px")),b.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=X(t);return Ke.test(t)||(t=Xe(s)),(a=E.cssHooks[t]||E.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Fe(e,t,r)),"normal"===i&&t in Ze&&(i=Ze[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),E.each(["height","width"],function(e,u){E.cssHooks[u]={get:function(e,t,n){if(t)return!Ge.test(E.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?nt(e,u,n):ue(e,Je,function(){return nt(e,u,n)})},set:function(e,t,n){var r,i=We(e),o=!b.scrollboxSize()&&"absolute"===i.position,a=(o||n)&&"border-box"===E.css(e,"boxSizing",!1,i),s=n?tt(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e["offset"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-tt(e,u,"border",!1,i)-.5)),s&&(r=ne.exec(t))&&"px"!==(r[3]||"px")&&(e.style[u]=t,t=E.css(e,u)),et(0,t,s)}}}),E.cssHooks.marginLeft=ze(b.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Fe(e,"marginLeft"))||e.getBoundingClientRect().left-ue(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),E.each({margin:"",padding:"",border:"Width"},function(i,o){E.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r="string"==typeof e?e.split(" "):[e];t<4;t++)n[i+re[t]+o]=r[t]||r[t-2]||r[0];return n}},"margin"!==i&&(E.cssHooks[i+o].set=et)}),E.fn.extend({css:function(e,t){return z(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=We(e),i=t.length;a<i;a++)o[t[a]]=E.css(e,t[a],!1,r);return o}return void 0!==n?E.style(e,t,n):E.css(e,t)},e,t,1<arguments.length)}}),E.fn.delay=function(r,e){return r=E.fx&&E.fx.speeds[r]||r,e=e||"fx",this.queue(e,function(e,t){var n=g.setTimeout(e,r);t.stop=function(){g.clearTimeout(n)}})},Qe=v.createElement("input"),Ye=v.createElement("select").appendChild(v.createElement("option")),Qe.type="checkbox",b.checkOn=""!==Qe.value,b.optSelected=Ye.selected,(Qe=v.createElement("input")).value="t",Qe.type="radio",b.radioValue="t"===Qe.value;var rt,it=E.expr.attrHandle;E.fn.extend({attr:function(e,t){return z(this,E.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){E.removeAttr(this,e)})}}),E.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?E.prop(e,t,n):(1===o&&E.isXMLDoc(e)||(i=E.attrHooks[t.toLowerCase()]||(E.expr.match.bool.test(t)?rt:void 0)),void 0!==n?null===n?void E.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=E.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!b.radioValue&&"radio"===t&&S(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(I);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),rt={set:function(e,t,n){return!1===t?E.removeAttr(e,n):e.setAttribute(n,n),n}},E.each(E.expr.match.bool.source.match(/\w+/g),function(e,t){var a=it[t]||E.find.attr;it[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=it[o],it[o]=r,r=null!=a(e,t,n)?o:null,it[o]=i),r}});var ot=/^(?:input|select|textarea|button)$/i,at=/^(?:a|area)$/i;function st(e){return(e.match(I)||[]).join(" ")}function ut(e){return e.getAttribute&&e.getAttribute("class")||""}function lt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(I)||[]}E.fn.extend({prop:function(e,t){return z(this,E.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[E.propFix[e]||e]})}}),E.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&E.isXMLDoc(e)||(t=E.propFix[t]||t,i=E.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=E.find.attr(e,"tabindex");return t?parseInt(t,10):ot.test(e.nodeName)||at.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),b.optSelected||(E.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),E.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){E.propFix[this.toLowerCase()]=this}),E.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(x(t))return this.each(function(e){E(this).addClass(t.call(this,e,ut(this)))});if((e=lt(t)).length)while(n=this[u++])if(i=ut(n),r=1===n.nodeType&&" "+st(i)+" "){a=0;while(o=e[a++])r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=st(r))&&n.setAttribute("class",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(x(t))return this.each(function(e){E(this).removeClass(t.call(this,e,ut(this)))});if(!arguments.length)return this.attr("class","");if((e=lt(t)).length)while(n=this[u++])if(i=ut(n),r=1===n.nodeType&&" "+st(i)+" "){a=0;while(o=e[a++])while(-1<r.indexOf(" "+o+" "))r=r.replace(" "+o+" "," ");i!==(s=st(r))&&n.setAttribute("class",s)}return this},toggleClass:function(i,t){var o=typeof i,a="string"===o||Array.isArray(i);return"boolean"==typeof t&&a?t?this.addClass(i):this.removeClass(i):x(i)?this.each(function(e){E(this).toggleClass(i.call(this,e,ut(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=E(this),r=lt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&"boolean"!==o||((e=ut(this))&&G.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===i?"":G.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;t=" "+e+" ";while(n=this[r++])if(1===n.nodeType&&-1<(" "+st(ut(n))+" ").indexOf(t))return!0;return!1}});var ct=/\r/g;E.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=x(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,E(this).val()):n)?t="":"number"==typeof t?t+="":Array.isArray(t)&&(t=E.map(t,function(e){return null==e?"":e+""})),(r=E.valHooks[this.type]||E.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&void 0!==r.set(this,t,"value")||(this.value=t))})):t?(r=E.valHooks[t.type]||E.valHooks[t.nodeName.toLowerCase()])&&"get"in r&&void 0!==(e=r.get(t,"value"))?e:"string"==typeof(e=t.value)?e.replace(ct,""):null==e?"":e:void 0}}),E.extend({valHooks:{option:{get:function(e){var t=E.find.attr(e,"value");return null!=t?t:st(E.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!S(n.parentNode,"optgroup"))){if(t=E(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=E.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<E.inArray(E.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),E.each(["radio","checkbox"],function(){E.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<E.inArray(E(e).val(),t)}},b.checkOn||(E.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),b.focusin="onfocusin"in g;var ft=/^(?:focusinfocus|focusoutblur)$/,dt=function(e){e.stopPropagation()};E.extend(E.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,d=[n||v],p=m.call(e,"type")?e.type:e,h=m.call(e,"namespace")?e.namespace.split("."):[];if(o=f=a=n=n||v,3!==n.nodeType&&8!==n.nodeType&&!ft.test(p+E.event.triggered)&&(-1<p.indexOf(".")&&(p=(h=p.split(".")).shift(),h.sort()),u=p.indexOf(":")<0&&"on"+p,(e=e[E.expando]?e:new E.Event(p,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:E.makeArray(t,[e]),c=E.event.special[p]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!w(n)){for(s=c.delegateType||p,ft.test(s+p)||(o=o.parentNode);o;o=o.parentNode)d.push(o),a=o;a===(n.ownerDocument||v)&&d.push(a.defaultView||a.parentWindow||g)}i=0;while((o=d[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||p,(l=(G.get(o,"events")||{})[e.type]&&G.get(o,"handle"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&Q(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=p,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(d.pop(),t)||!Q(n)||u&&x(n[p])&&!w(n)&&((a=n[u])&&(n[u]=null),E.event.triggered=p,e.isPropagationStopped()&&f.addEventListener(p,dt),n[p](),e.isPropagationStopped()&&f.removeEventListener(p,dt),E.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=E.extend(new E.Event,n,{type:e,isSimulated:!0});E.event.trigger(r,null,t)}}),E.fn.extend({trigger:function(e,t){return this.each(function(){E.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return E.event.trigger(e,t,n,!0)}}),b.focusin||E.each({focus:"focusin",blur:"focusout"},function(n,r){var i=function(e){E.event.simulate(r,e.target,E.event.fix(e))};E.event.special[r]={setup:function(){var e=this.ownerDocument||this,t=G.access(e,r);t||e.addEventListener(n,i,!0),G.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this,t=G.access(e,r)-1;t?G.access(e,r,t):(e.removeEventListener(n,i,!0),G.remove(e,r))}}});var pt,ht=/\[\]$/,gt=/\r?\n/g,vt=/^(?:submit|button|image|reset|file)$/i,yt=/^(?:input|select|textarea|keygen)/i;function mt(n,e,r,i){var t;if(Array.isArray(e))E.each(e,function(e,t){r||ht.test(n)?i(n,t):mt(n+"["+("object"==typeof t&&null!=t?e:"")+"]",t,r,i)});else if(r||"object"!==T(e))i(n,e);else for(t in e)mt(n+"["+t+"]",e[t],r,i)}E.param=function(e,t){var n,r=[],i=function(e,t){var n=x(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!E.isPlainObject(e))E.each(e,function(){i(this.name,this.value)});else for(n in e)mt(n,e[n],t,i);return r.join("&")},E.fn.extend({serialize:function(){return E.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=E.prop(this,"elements");return e?E.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!E(this).is(":disabled")&&yt.test(this.nodeName)&&!vt.test(e)&&(this.checked||!fe.test(e))}).map(function(e,t){var n=E(this).val();return null==n?null:Array.isArray(n)?E.map(n,function(e){return{name:t.name,value:e.replace(gt,"\r\n")}}):{name:t.name,value:n.replace(gt,"\r\n")}}).get()}}),E.fn.extend({wrapAll:function(e){var t;return this[0]&&(x(e)&&(e=e.call(this[0])),t=E(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(n){return x(n)?this.each(function(e){E(this).wrapInner(n.call(this,e))}):this.each(function(){var e=E(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=x(t);return this.each(function(e){E(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not("body").each(function(){E(this).replaceWith(this.childNodes)}),this}}),E.expr.pseudos.hidden=function(e){return!E.expr.pseudos.visible(e)},E.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},b.createHTMLDocument=((pt=v.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===pt.childNodes.length),E.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(b.createHTMLDocument?((r=(t=v.implementation.createHTMLDocument("")).createElement("base")).href=v.location.href,t.head.appendChild(r)):t=v),o=!n&&[],(i=D.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&E(o).remove(),E.merge([],i.childNodes)));var r,i,o},E.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=E.css(e,"position"),c=E(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=E.css(e,"top"),u=E.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),x(t)&&(t=t.call(e,n,E.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},E.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){E.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===E.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===E.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=E(e).offset()).top+=E.css(e,"borderTopWidth",!0),i.left+=E.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-E.css(r,"marginTop",!0),left:t.left-i.left-E.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===E.css(e,"position"))e=e.offsetParent;return e||ie})}}),E.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;E.fn[t]=function(e){return z(this,function(e,t,n){var r;if(w(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),E.each(["top","left"],function(e,n){E.cssHooks[n]=ze(b.pixelPosition,function(e,t){if(t)return t=Fe(e,n),Me.test(t)?E(e).position()[n]+"px":t})}),E.each({Height:"height",Width:"width"},function(a,s){E.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){E.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return z(this,function(e,t,n){var r;return w(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?E.css(e,t,i):E.style(e,t,n,i)},s,n?e:void 0,n)}})}),E.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){E.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}}),E.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),E.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}}),E.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),x(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||E.guid++,i},E.holdReady=function(e){e?E.readyWait++:E.ready(!0)},E.isArray=Array.isArray,E.parseJSON=JSON.parse,E.nodeName=S,E.isFunction=x,E.isWindow=w,E.camelCase=X,E.type=T,E.now=Date.now,E.isNumeric=function(e){var t=E.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},"function"==typeof define&&define.amd&&define("jquery",[],function(){return E});var bt=g.jQuery,xt=g.$;return E.noConflict=function(e){return g.$===E&&(g.$=xt),e&&g.jQuery===E&&(g.jQuery=bt),E},e||(g.jQuery=g.$=E),E});
/*!
* Viewer.js v1.3.5
* https://fengyuanchen.github.io/viewerjs
*
* Copyright 2015-present Chen Fengyuan
* Released under the MIT license
*
* Date: 2019-07-04T11:00:16.790Z
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, global.Viewer = factory());
}(this, function () { 'use strict';
function _typeof(obj) {
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
_typeof = function (obj) {
return typeof obj;
};
} else {
_typeof = function (obj) {
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
};
}
return _typeof(obj);
}
function _classCallCheck(instance, Constructor) {
if (!(instance instanceof Constructor)) {
throw new TypeError("Cannot call a class as a function");
}
}
function _defineProperties(target, props) {
for (var i = 0; i < props.length; i++) {
var descriptor = props[i];
descriptor.enumerable = descriptor.enumerable || false;
descriptor.configurable = true;
if ("value" in descriptor) descriptor.writable = true;
Object.defineProperty(target, descriptor.key, descriptor);
}
}
function _createClass(Constructor, protoProps, staticProps) {
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
if (staticProps) _defineProperties(Constructor, staticProps);
return Constructor;
}
var DEFAULTS = {
/**
* Enable a modal backdrop, specify `static` for a backdrop
* which doesn't close the modal on click.
* @type {boolean}
*/
backdrop: true,
/**
* Show the button on the top-right of the viewer.
* @type {boolean}
*/
button: true,
/**
* Show the navbar.
* @type {boolean | number}
*/
navbar: true,
/**
* Specify the visibility and the content of the title.
* @type {boolean | number | Function | Array}
*/
title: true,
/**
* Show the toolbar.
* @type {boolean | number | Object}
*/
toolbar: true,
/**
* Custom class name(s) to add to the viewer's root element.
* @type {string}
*/
className: '',
/**
* Define where to put the viewer in modal mode.
* @type {string | Element}
*/
container: 'body',
/**
* Filter the images for viewing. Return true if the image is viewable.
* @type {Function}
*/
filter: null,
/**
* Enable to request fullscreen when play.
* @type {boolean}
*/
fullscreen: true,
/**
* Define the initial index of image for viewing.
* @type {number}
*/
initialViewIndex: 0,
/**
* Enable inline mode.
* @type {boolean}
*/
inline: false,
/**
* The amount of time to delay between automatically cycling an image when playing.
* @type {number}
*/
interval: 5000,
/**
* Enable keyboard support.
* @type {boolean}
*/
keyboard: true,
/**
* Indicate if show a loading spinner when load image or not.
* @type {boolean}
*/
loading: true,
/**
* Indicate if enable loop viewing or not.
* @type {boolean}
*/
loop: true,
/**
* Min width of the viewer in inline mode.
* @type {number}
*/
minWidth: 200,
/**
* Min height of the viewer in inline mode.
* @type {number}
*/
minHeight: 100,
/**
* Enable to move the image.
* @type {boolean}
*/
movable: true,
/**
* Enable to zoom the image.
* @type {boolean}
*/
zoomable: true,
/**
* Enable to rotate the image.
* @type {boolean}
*/
rotatable: true,
/**
* Enable to scale the image.
* @type {boolean}
*/
scalable: true,
/**
* Indicate if toggle the image size between its natural size
* and initial size when double click on the image or not.
* @type {boolean}
*/
toggleOnDblclick: true,
/**
* Show the tooltip with image ratio (percentage) when zoom in or zoom out.
* @type {boolean}
*/
tooltip: true,
/**
* Enable CSS3 Transition for some special elements.
* @type {boolean}
*/
transition: true,
/**
* Define the CSS `z-index` value of viewer in modal mode.
* @type {number}
*/
zIndex: 999999999,
/**
* Define the CSS `z-index` value of viewer in inline mode.
* @type {number}
*/
zIndexInline: 0,
/**
* Define the ratio when zoom the image by wheeling mouse.
* @type {number}
*/
zoomRatio: 0.1,
/**
* Define the min ratio of the image when zoom out.
* @type {number}
*/
minZoomRatio: 0.01,
/**
* Define the max ratio of the image when zoom in.
* @type {number}
*/
maxZoomRatio: 100,
/**
* Define where to get the original image URL for viewing.
* @type {string | Function}
*/
url: 'src',
/**
* Event shortcuts.
* @type {Function}
*/
ready: null,
show: null,
shown: null,
hide: null,
hidden: null,
view: null,
viewed: null,
zoom: null,
zoomed: null
};
var TEMPLATE = '<div class="viewer-container" touch-action="none">' + '<div class="viewer-canvas"></div>' + '<div class="viewer-footer">' + '<div class="viewer-title"></div>' + '<div class="viewer-toolbar"></div>' + '<div class="viewer-navbar">' + '<ul class="viewer-list"></ul>' + '</div>' + '</div>' + '<div class="viewer-tooltip"></div>' + '<div role="button" class="viewer-button" data-viewer-action="mix"></div>' + '<div class="viewer-player"></div>' + '</div>';
var IS_BROWSER = typeof window !== 'undefined';
var WINDOW = IS_BROWSER ? window : {};
var IS_TOUCH_DEVICE = IS_BROWSER ? 'ontouchstart' in WINDOW.document.documentElement : false;
var HAS_POINTER_EVENT = IS_BROWSER ? 'PointerEvent' in WINDOW : false;
var NAMESPACE = 'viewer'; // Actions
var ACTION_MOVE = 'move';
var ACTION_SWITCH = 'switch';
var ACTION_ZOOM = 'zoom'; // Classes
var CLASS_ACTIVE = "".concat(NAMESPACE, "-active");
var CLASS_CLOSE = "".concat(NAMESPACE, "-close");
var CLASS_FADE = "".concat(NAMESPACE, "-fade");
var CLASS_FIXED = "".concat(NAMESPACE, "-fixed");
var CLASS_FULLSCREEN = "".concat(NAMESPACE, "-fullscreen");
var CLASS_FULLSCREEN_EXIT = "".concat(NAMESPACE, "-fullscreen-exit");
var CLASS_HIDE = "".concat(NAMESPACE, "-hide");
var CLASS_HIDE_MD_DOWN = "".concat(NAMESPACE, "-hide-md-down");
var CLASS_HIDE_SM_DOWN = "".concat(NAMESPACE, "-hide-sm-down");
var CLASS_HIDE_XS_DOWN = "".concat(NAMESPACE, "-hide-xs-down");
var CLASS_IN = "".concat(NAMESPACE, "-in");
var CLASS_INVISIBLE = "".concat(NAMESPACE, "-invisible");
var CLASS_LOADING = "".concat(NAMESPACE, "-loading");
var CLASS_MOVE = "".concat(NAMESPACE, "-move");
var CLASS_OPEN = "".concat(NAMESPACE, "-open");
var CLASS_SHOW = "".concat(NAMESPACE, "-show");
var CLASS_TRANSITION = "".concat(NAMESPACE, "-transition"); // Events
var EVENT_CLICK = 'click';
var EVENT_DBLCLICK = 'dblclick';
var EVENT_DRAG_START = 'dragstart';
var EVENT_HIDDEN = 'hidden';
var EVENT_HIDE = 'hide';
var EVENT_KEY_DOWN = 'keydown';
var EVENT_LOAD = 'load';
var EVENT_TOUCH_START = IS_TOUCH_DEVICE ? 'touchstart' : 'mousedown';
var EVENT_TOUCH_MOVE = IS_TOUCH_DEVICE ? 'touchmove' : 'mousemove';
var EVENT_TOUCH_END = IS_TOUCH_DEVICE ? 'touchend touchcancel' : 'mouseup';
var EVENT_POINTER_DOWN = HAS_POINTER_EVENT ? 'pointerdown' : EVENT_TOUCH_START;
var EVENT_POINTER_MOVE = HAS_POINTER_EVENT ? 'pointermove' : EVENT_TOUCH_MOVE;
var EVENT_POINTER_UP = HAS_POINTER_EVENT ? 'pointerup pointercancel' : EVENT_TOUCH_END;
var EVENT_READY = 'ready';
var EVENT_RESIZE = 'resize';
var EVENT_SHOW = 'show';
var EVENT_SHOWN = 'shown';
var EVENT_TRANSITION_END = 'transitionend';
var EVENT_VIEW = 'view';
var EVENT_VIEWED = 'viewed';
var EVENT_WHEEL = 'wheel';
var EVENT_ZOOM = 'zoom';
var EVENT_ZOOMED = 'zoomed'; // Data keys
var DATA_ACTION = "".concat(NAMESPACE, "Action"); // RegExps
var REGEXP_SPACES = /\s\s*/; // Misc
var BUTTONS = ['zoom-in', 'zoom-out', 'one-to-one', 'reset', 'prev', 'play', 'next', 'rotate-left', 'rotate-right', 'flip-horizontal', 'flip-vertical'];
/**
* Check if the given value is a string.
* @param {*} value - The value to check.
* @returns {boolean} Returns `true` if the given value is a string, else `false`.
*/
function isString(value) {
return typeof value === 'string';
}
/**
* Check if the given value is not a number.
*/
var isNaN = Number.isNaN || WINDOW.isNaN;
/**
* Check if the given value is a number.
* @param {*} value - The value to check.
* @returns {boolean} Returns `true` if the given value is a number, else `false`.
*/
function isNumber(value) {
return typeof value === 'number' && !isNaN(value);
}
/**
* Check if the given value is undefined.
* @param {*} value - The value to check.
* @returns {boolean} Returns `true` if the given value is undefined, else `false`.
*/
function isUndefined(value) {
return typeof value === 'undefined';
}
/**
* Check if the given value is an object.
* @param {*} value - The value to check.
* @returns {boolean} Returns `true` if the given value is an object, else `false`.
*/
function isObject(value) {
return _typeof(value) === 'object' && value !== null;
}
var hasOwnProperty = Object.prototype.hasOwnProperty;
/**
* Check if the given value is a plain object.
* @param {*} value - The value to check.
* @returns {boolean} Returns `true` if the given value is a plain object, else `false`.
*/
function isPlainObject(value) {
if (!isObject(value)) {
return false;
}
try {
var _constructor = value.constructor;
var prototype = _constructor.prototype;
return _constructor && prototype && hasOwnProperty.call(prototype, 'isPrototypeOf');
} catch (error) {
return false;
}
}
/**
* Check if the given value is a function.
* @param {*} value - The value to check.
* @returns {boolean} Returns `true` if the given value is a function, else `false`.
*/
function isFunction(value) {
return typeof value === 'function';
}
/**
* Iterate the given data.
* @param {*} data - The data to iterate.
* @param {Function} callback - The process function for each element.
* @returns {*} The original data.
*/
function forEach(data, callback) {
if (data && isFunction(callback)) {
if (Array.isArray(data) || isNumber(data.length)
/* array-like */
) {
var length = data.length;
var i;
for (i = 0; i < length; i += 1) {
if (callback.call(data, data[i], i, data) === false) {
break;
}
}
} else if (isObject(data)) {
Object.keys(data).forEach(function (key) {
callback.call(data, data[key], key, data);
});
}
}
return data;
}
/**
* Extend the given object.
* @param {*} obj - The object to be extended.
* @param {*} args - The rest objects which will be merged to the first object.
* @returns {Object} The extended object.
*/
var assign = Object.assign || function assign(obj) {
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
args[_key - 1] = arguments[_key];
}
if (isObject(obj) && args.length > 0) {
args.forEach(function (arg) {
if (isObject(arg)) {
Object.keys(arg).forEach(function (key) {
obj[key] = arg[key];
});
}
});
}
return obj;
};
var REGEXP_SUFFIX = /^(?:width|height|left|top|marginLeft|marginTop)$/;
/**
* Apply styles to the given element.
* @param {Element} element - The target element.
* @param {Object} styles - The styles for applying.
*/
function setStyle(element, styles) {
var style = element.style;
forEach(styles, function (value, property) {
if (REGEXP_SUFFIX.test(property) && isNumber(value)) {
value += 'px';
}
style[property] = value;
});
}
/**
* Escape a string for using in HTML.
* @param {String} value - The string to escape.
* @returns {String} Returns the escaped string.
*/
function escapeHTMLEntities(value) {
return isString(value) ? value.replace(/&(?!amp;|quot;|#39;|lt;|gt;)/g, '&amp;').replace(/"/g, '&quot;').replace(/'/g, '&#39;').replace(/</g, '&lt;').replace(/>/g, '&gt;') : value;
}
/**
* Check if the given element has a special class.
* @param {Element} element - The element to check.
* @param {string} value - The class to search.
* @returns {boolean} Returns `true` if the special class was found.
*/
function hasClass(element, value) {
return element.classList ? element.classList.contains(value) : element.className.indexOf(value) > -1;
}
/**
* Add classes to the given element.
* @param {Element} element - The target element.
* @param {string} value - The classes to be added.
*/
function addClass(element, value) {
if (!value) {
return;
}
if (isNumber(element.length)) {
forEach(element, function (elem) {
addClass(elem, value);
});
return;
}
if (element.classList) {
element.classList.add(value);
return;
}
var className = element.className.trim();
if (!className) {
element.className = value;
} else if (className.indexOf(value) < 0) {
element.className = "".concat(className, " ").concat(value);
}
}
/**
* Remove classes from the given element.
* @param {Element} element - The target element.
* @param {string} value - The classes to be removed.
*/
function removeClass(element, value) {
if (!value) {
return;
}
if (isNumber(element.length)) {
forEach(element, function (elem) {
removeClass(elem, value);
});
return;
}
if (element.classList) {
element.classList.remove(value);
return;
}
if (element.className.indexOf(value) >= 0) {
element.className = element.className.replace(value, '');
}
}
/**
* Add or remove classes from the given element.
* @param {Element} element - The target element.
* @param {string} value - The classes to be toggled.
* @param {boolean} added - Add only.
*/
function toggleClass(element, value, added) {
if (!value) {
return;
}
if (isNumber(element.length)) {
forEach(element, function (elem) {
toggleClass(elem, value, added);
});
return;
} // IE10-11 doesn't support the second parameter of `classList.toggle`
if (added) {
addClass(element, value);
} else {
removeClass(element, value);
}
}
var REGEXP_HYPHENATE = /([a-z\d])([A-Z])/g;
/**
* Transform the given string from camelCase to kebab-case
* @param {string} value - The value to transform.
* @returns {string} The transformed value.
*/
function hyphenate(value) {
return value.replace(REGEXP_HYPHENATE, '$1-$2').toLowerCase();
}
/**
* Get data from the given element.
* @param {Element} element - The target element.
* @param {string} name - The data key to get.
* @returns {string} The data value.
*/
function getData(element, name) {
if (isObject(element[name])) {
return element[name];
}
if (element.dataset) {
return element.dataset[name];
}
return element.getAttribute("data-".concat(hyphenate(name)));
}
/**
* Set data to the given element.
* @param {Element} element - The target element.
* @param {string} name - The data key to set.
* @param {string} data - The data value.
*/
function setData(element, name, data) {
if (isObject(data)) {
element[name] = data;
} else if (element.dataset) {
element.dataset[name] = data;
} else {
element.setAttribute("data-".concat(hyphenate(name)), data);
}
}
var onceSupported = function () {
var supported = false;
if (IS_BROWSER) {
var once = false;
var listener = function listener() {};
var options = Object.defineProperty({}, 'once', {
get: function get() {
supported = true;
return once;
},
/**
* This setter can fix a `TypeError` in strict mode
* {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Errors/Getter_only}
* @param {boolean} value - The value to set
*/
set: function set(value) {
once = value;
}
});
WINDOW.addEventListener('test', listener, options);
WINDOW.removeEventListener('test', listener, options);
}
return supported;
}();
/**
* Remove event listener from the target element.
* @param {Element} element - The event target.
* @param {string} type - The event type(s).
* @param {Function} listener - The event listener.
* @param {Object} options - The event options.
*/
function removeListener(element, type, listener) {
var options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
var handler = listener;
type.trim().split(REGEXP_SPACES).forEach(function (event) {
if (!onceSupported) {
var listeners = element.listeners;
if (listeners && listeners[event] && listeners[event][listener]) {
handler = listeners[event][listener];
delete listeners[event][listener];
if (Object.keys(listeners[event]).length === 0) {
delete listeners[event];
}
if (Object.keys(listeners).length === 0) {
delete element.listeners;
}
}
}
element.removeEventListener(event, handler, options);
});
}
/**
* Add event listener to the target element.
* @param {Element} element - The event target.
* @param {string} type - The event type(s).
* @param {Function} listener - The event listener.
* @param {Object} options - The event options.
*/
function addListener(element, type, listener) {
var options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
var _handler = listener;
type.trim().split(REGEXP_SPACES).forEach(function (event) {
if (options.once && !onceSupported) {
var _element$listeners = element.listeners,
listeners = _element$listeners === void 0 ? {} : _element$listeners;
_handler = function handler() {
delete listeners[event][listener];
element.removeEventListener(event, _handler, options);
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
args[_key2] = arguments[_key2];
}
listener.apply(element, args);
};
if (!listeners[event]) {
listeners[event] = {};
}
if (listeners[event][listener]) {
element.removeEventListener(event, listeners[event][listener], options);
}
listeners[event][listener] = _handler;
element.listeners = listeners;
}
element.addEventListener(event, _handler, options);
});
}
/**
* Dispatch event on the target element.
* @param {Element} element - The event target.
* @param {string} type - The event type(s).
* @param {Object} data - The additional event data.
* @returns {boolean} Indicate if the event is default prevented or not.
*/
function dispatchEvent(element, type, data) {
var event; // Event and CustomEvent on IE9-11 are global objects, not constructors
if (isFunction(Event) && isFunction(CustomEvent)) {
event = new CustomEvent(type, {
detail: data,
bubbles: true,
cancelable: true
});
} else {
event = document.createEvent('CustomEvent');
event.initCustomEvent(type, true, true, data);
}
return element.dispatchEvent(event);
}
/**
* Get the offset base on the document.
* @param {Element} element - The target element.
* @returns {Object} The offset data.
*/
function getOffset(element) {
var box = element.getBoundingClientRect();
return {
left: box.left + (window.pageXOffset - document.documentElement.clientLeft),
top: box.top + (window.pageYOffset - document.documentElement.clientTop)
};
}
/**
* Get transforms base on the given object.
* @param {Object} obj - The target object.
* @returns {string} A string contains transform values.
*/
function getTransforms(_ref) {
var rotate = _ref.rotate,
scaleX = _ref.scaleX,
scaleY = _ref.scaleY,
translateX = _ref.translateX,
translateY = _ref.translateY;
var values = [];
if (isNumber(translateX) && translateX !== 0) {
values.push("translateX(".concat(translateX, "px)"));
}
if (isNumber(translateY) && translateY !== 0) {
values.push("translateY(".concat(translateY, "px)"));
} // Rotate should come first before scale to match orientation transform
if (isNumber(rotate) && rotate !== 0) {
values.push("rotate(".concat(rotate, "deg)"));
}
if (isNumber(scaleX) && scaleX !== 1) {
values.push("scaleX(".concat(scaleX, ")"));
}
if (isNumber(scaleY) && scaleY !== 1) {
values.push("scaleY(".concat(scaleY, ")"));
}
var transform = values.length ? values.join(' ') : 'none';
return {
WebkitTransform: transform,
msTransform: transform,
transform: transform
};
}
/**
* Get an image name from an image url.
* @param {string} url - The target url.
* @example
* // picture.jpg
* getImageNameFromURL('http://domain.com/path/to/picture.jpg?size=1280×960')
* @returns {string} A string contains the image name.
*/
function getImageNameFromURL(url) {
return isString(url) ? decodeURIComponent(url.replace(/^.*\//, '').replace(/[?&#].*$/, '')) : '';
}
var IS_SAFARI = WINDOW.navigator && /(Macintosh|iPhone|iPod|iPad).*AppleWebKit/i.test(WINDOW.navigator.userAgent);
/**
* Get an image's natural sizes.
* @param {string} image - The target image.
* @param {Function} callback - The callback function.
* @returns {HTMLImageElement} The new image.
*/
function getImageNaturalSizes(image, callback) {
var newImage = document.createElement('img'); // Modern browsers (except Safari)
if (image.naturalWidth && !IS_SAFARI) {
callback(image.naturalWidth, image.naturalHeight);
return newImage;
}
var body = document.body || document.documentElement;
newImage.onload = function () {
callback(newImage.width, newImage.height);
if (!IS_SAFARI) {
body.removeChild(newImage);
}
};
newImage.src = image.src; // iOS Safari will convert the image automatically
// with its orientation once append it into DOM
if (!IS_SAFARI) {
newImage.style.cssText = 'left:0;' + 'max-height:none!important;' + 'max-width:none!important;' + 'min-height:0!important;' + 'min-width:0!important;' + 'opacity:0;' + 'position:absolute;' + 'top:0;' + 'z-index:-1;';
body.appendChild(newImage);
}
return newImage;
}
/**
* Get the related class name of a responsive type number.
* @param {string} type - The responsive type.
* @returns {string} The related class name.
*/
function getResponsiveClass(type) {
switch (type) {
case 2:
return CLASS_HIDE_XS_DOWN;
case 3:
return CLASS_HIDE_SM_DOWN;
case 4:
return CLASS_HIDE_MD_DOWN;
default:
return '';
}
}
/**
* Get the max ratio of a group of pointers.
* @param {string} pointers - The target pointers.
* @returns {number} The result ratio.
*/
function getMaxZoomRatio(pointers) {
var pointers2 = assign({}, pointers);
var ratios = [];
forEach(pointers, function (pointer, pointerId) {
delete pointers2[pointerId];
forEach(pointers2, function (pointer2) {
var x1 = Math.abs(pointer.startX - pointer2.startX);
var y1 = Math.abs(pointer.startY - pointer2.startY);
var x2 = Math.abs(pointer.endX - pointer2.endX);
var y2 = Math.abs(pointer.endY - pointer2.endY);
var z1 = Math.sqrt(x1 * x1 + y1 * y1);
var z2 = Math.sqrt(x2 * x2 + y2 * y2);
var ratio = (z2 - z1) / z1;
ratios.push(ratio);
});
});
ratios.sort(function (a, b) {
return Math.abs(a) < Math.abs(b);
});
return ratios[0];
}
/**
* Get a pointer from an event object.
* @param {Object} event - The target event object.
* @param {boolean} endOnly - Indicates if only returns the end point coordinate or not.
* @returns {Object} The result pointer contains start and/or end point coordinates.
*/
function getPointer(_ref2, endOnly) {
var pageX = _ref2.pageX,
pageY = _ref2.pageY;
var end = {
endX: pageX,
endY: pageY
};
return endOnly ? end : assign({
timeStamp: Date.now(),
startX: pageX,
startY: pageY
}, end);
}
/**
* Get the center point coordinate of a group of pointers.
* @param {Object} pointers - The target pointers.
* @returns {Object} The center point coordinate.
*/
function getPointersCenter(pointers) {
var pageX = 0;
var pageY = 0;
var count = 0;
forEach(pointers, function (_ref3) {
var startX = _ref3.startX,
startY = _ref3.startY;
pageX += startX;
pageY += startY;
count += 1;
});
pageX /= count;
pageY /= count;
return {
pageX: pageX,
pageY: pageY
};
}
var render = {
render: function render() {
this.initContainer();
this.initViewer();
this.initList();
this.renderViewer();
},
initContainer: function initContainer() {
this.containerData = {
width: window.innerWidth,
height: window.innerHeight
};
},
initViewer: function initViewer() {
var options = this.options,
parent = this.parent;
var viewerData;
if (options.inline) {
viewerData = {
width: Math.max(parent.offsetWidth, options.minWidth),
height: Math.max(parent.offsetHeight, options.minHeight)
};
this.parentData = viewerData;
}
if (this.fulled || !viewerData) {
viewerData = this.containerData;
}
this.viewerData = assign({}, viewerData);
},
renderViewer: function renderViewer() {
if (this.options.inline && !this.fulled) {
setStyle(this.viewer, this.viewerData);
}
},
initList: function initList() {
var _this = this;
var element = this.element,
options = this.options,
list = this.list;
var items = [];
forEach(this.images, function (image, index) {
var src = image.src;
var alt = escapeHTMLEntities(image.alt || getImageNameFromURL(src));
var url = options.url;
if (isString(url)) {
url = image.getAttribute(url);
} else if (isFunction(url)) {
url = url.call(_this, image);
}
if (src || url) {
var item = document.createElement('li');
var img = document.createElement('img');
img.src = src || url;
img.alt = alt;
img.setAttribute('data-index', index);
img.setAttribute('data-original-url', url || src);
img.setAttribute('data-viewer-action', 'view');
img.setAttribute('role', 'button');
item.appendChild(img);
list.appendChild(item);
items.push(item);
}
});
this.items = items;
forEach(items, function (item) {
var image = item.firstElementChild;
setData(image, 'filled', true);
if (options.loading) {
addClass(item, CLASS_LOADING);
}
addListener(image, EVENT_LOAD, function (event) {
if (options.loading) {
removeClass(item, CLASS_LOADING);
}
_this.loadImage(event);
}, {
once: true
});
});
if (options.transition) {
addListener(element, EVENT_VIEWED, function () {
addClass(list, CLASS_TRANSITION);
}, {
once: true
});
}
},
renderList: function renderList(index) {
var i = index || this.index;
var width = this.items[i].offsetWidth || 30;
var outerWidth = width + 1; // 1 pixel of `margin-left` width
// Place the active item in the center of the screen
setStyle(this.list, assign({
width: outerWidth * this.length
}, getTransforms({
translateX: (this.viewerData.width - width) / 2 - outerWidth * i
})));
},
resetList: function resetList() {
var list = this.list;
list.innerHTML = '';
removeClass(list, CLASS_TRANSITION);
setStyle(list, getTransforms({
translateX: 0
}));
},
initImage: function initImage(done) {
var _this2 = this;
var options = this.options,
image = this.image,
viewerData = this.viewerData;
var footerHeight = this.footer.offsetHeight;
var viewerWidth = viewerData.width;
var viewerHeight = Math.max(viewerData.height - footerHeight, footerHeight);
var oldImageData = this.imageData || {};
var sizingImage;
this.imageInitializing = {
abort: function abort() {
sizingImage.onload = null;
}
};
sizingImage = getImageNaturalSizes(image, function (naturalWidth, naturalHeight) {
var aspectRatio = naturalWidth / naturalHeight;
var width = viewerWidth;
var height = viewerHeight;
_this2.imageInitializing = false;
if (viewerHeight * aspectRatio > viewerWidth) {
height = viewerWidth / aspectRatio;
} else {
width = viewerHeight * aspectRatio;
}
width = Math.min(width * 0.9, naturalWidth);
height = Math.min(height * 0.9, naturalHeight);
var imageData = {
naturalWidth: naturalWidth,
naturalHeight: naturalHeight,
aspectRatio: aspectRatio,
ratio: width / naturalWidth,
width: width,
height: height,
left: (viewerWidth - width) / 2,
top: (viewerHeight - height) / 2
};
var initialImageData = assign({}, imageData);
if (options.rotatable) {
imageData.rotate = oldImageData.rotate || 0;
initialImageData.rotate = 0;
}
if (options.scalable) {
imageData.scaleX = oldImageData.scaleX || 1;
imageData.scaleY = oldImageData.scaleY || 1;
initialImageData.scaleX = 1;
initialImageData.scaleY = 1;
}
_this2.imageData = imageData;
_this2.initialImageData = initialImageData;
if (done) {
done();
}
});
},
renderImage: function renderImage(done) {
var _this3 = this;
var image = this.image,
imageData = this.imageData;
setStyle(image, assign({
width: imageData.width,
height: imageData.height,
// XXX: Not to use translateX/Y to avoid image shaking when zooming
marginLeft: imageData.left,
marginTop: imageData.top
}, getTransforms(imageData)));
if (done) {
if ((this.viewing || this.zooming) && this.options.transition) {
var onTransitionEnd = function onTransitionEnd() {
_this3.imageRendering = false;
done();
};
this.imageRendering = {
abort: function abort() {
removeListener(image, EVENT_TRANSITION_END, onTransitionEnd);
}
};
addListener(image, EVENT_TRANSITION_END, onTransitionEnd, {
once: true
});
} else {
done();
}
}
},
resetImage: function resetImage() {
// this.image only defined after viewed
if (this.viewing || this.viewed) {
var image = this.image;
if (this.viewing) {
this.viewing.abort();
}
image.parentNode.removeChild(image);
this.image = null;
}
}
};
var events = {
bind: function bind() {
var options = this.options,
viewer = this.viewer,
canvas = this.canvas;
var document = this.element.ownerDocument;
addListener(viewer, EVENT_CLICK, this.onClick = this.click.bind(this));
addListener(viewer, EVENT_WHEEL, this.onWheel = this.wheel.bind(this), {
passive: false,
capture: true
});
addListener(viewer, EVENT_DRAG_START, this.onDragStart = this.dragstart.bind(this));
addListener(canvas, EVENT_POINTER_DOWN, this.onPointerDown = this.pointerdown.bind(this));
addListener(document, EVENT_POINTER_MOVE, this.onPointerMove = this.pointermove.bind(this));
addListener(document, EVENT_POINTER_UP, this.onPointerUp = this.pointerup.bind(this));
addListener(document, EVENT_KEY_DOWN, this.onKeyDown = this.keydown.bind(this));
addListener(window, EVENT_RESIZE, this.onResize = this.resize.bind(this));
if (options.toggleOnDblclick) {
addListener(canvas, EVENT_DBLCLICK, this.onDblclick = this.dblclick.bind(this));
}
},
unbind: function unbind() {
var options = this.options,
viewer = this.viewer,
canvas = this.canvas;
var document = this.element.ownerDocument;
removeListener(viewer, EVENT_CLICK, this.onClick);
removeListener(viewer, EVENT_WHEEL, this.onWheel, {
passive: false,
capture: true
});
removeListener(viewer, EVENT_DRAG_START, this.onDragStart);
removeListener(canvas, EVENT_POINTER_DOWN, this.onPointerDown);
removeListener(document, EVENT_POINTER_MOVE, this.onPointerMove);
removeListener(document, EVENT_POINTER_UP, this.onPointerUp);
removeListener(document, EVENT_KEY_DOWN, this.onKeyDown);
removeListener(window, EVENT_RESIZE, this.onResize);
if (options.toggleOnDblclick) {
removeListener(canvas, EVENT_DBLCLICK, this.onDblclick);
}
}
};
var handlers = {
click: function click(event) {
var target = event.target;
var options = this.options,
imageData = this.imageData;
var action = getData(target, DATA_ACTION); // Cancel the emulated click when the native click event was triggered.
if (IS_TOUCH_DEVICE && event.isTrusted && target === this.canvas) {
clearTimeout(this.clickCanvasTimeout);
}
switch (action) {
case 'mix':
if (this.played) {
this.stop();
} else if (options.inline) {
if (this.fulled) {
this.exit();
} else {
this.full();
}
} else {
this.hide();
}
break;
case 'hide':
this.hide();
break;
case 'view':
this.view(getData(target, 'index'));
break;
case 'zoom-in':
this.zoom(0.1, true);
break;
case 'zoom-out':
this.zoom(-0.1, true);
break;
case 'one-to-one':
this.toggle();
break;
case 'reset':
this.reset();
break;
case 'prev':
this.prev(options.loop);
break;
case 'play':
this.play(options.fullscreen);
break;
case 'next':
this.next(options.loop);
break;
case 'rotate-left':
this.rotate(-90);
break;
case 'rotate-right':
this.rotate(90);
break;
case 'flip-horizontal':
this.scaleX(-imageData.scaleX || -1);
break;
case 'flip-vertical':
this.scaleY(-imageData.scaleY || -1);
break;
default:
if (this.played) {
this.stop();
}
}
},
dblclick: function dblclick(event) {
event.preventDefault();
if (this.viewed && event.target === this.image) {
// Cancel the emulated double click when the native dblclick event was triggered.
if (IS_TOUCH_DEVICE && event.isTrusted) {
clearTimeout(this.doubleClickImageTimeout);
}
this.toggle();
}
},
load: function load() {
var _this = this;
if (this.timeout) {
clearTimeout(this.timeout);
this.timeout = false;
}
var element = this.element,
options = this.options,
image = this.image,
index = this.index,
viewerData = this.viewerData;
removeClass(image, CLASS_INVISIBLE);
if (options.loading) {
removeClass(this.canvas, CLASS_LOADING);
}
image.style.cssText = 'height:0;' + "margin-left:".concat(viewerData.width / 2, "px;") + "margin-top:".concat(viewerData.height / 2, "px;") + 'max-width:none!important;' + 'position:absolute;' + 'width:0;';
this.initImage(function () {
toggleClass(image, CLASS_MOVE, options.movable);
toggleClass(image, CLASS_TRANSITION, options.transition);
_this.renderImage(function () {
_this.viewed = true;
_this.viewing = false;
if (isFunction(options.viewed)) {
addListener(element, EVENT_VIEWED, options.viewed, {
once: true
});
}
dispatchEvent(element, EVENT_VIEWED, {
originalImage: _this.images[index],
index: index,
image: image
});
});
});
},
loadImage: function loadImage(event) {
var image = event.target;
var parent = image.parentNode;
var parentWidth = parent.offsetWidth || 30;
var parentHeight = parent.offsetHeight || 50;
var filled = !!getData(image, 'filled');
getImageNaturalSizes(image, function (naturalWidth, naturalHeight) {
var aspectRatio = naturalWidth / naturalHeight;
var width = parentWidth;
var height = parentHeight;
if (parentHeight * aspectRatio > parentWidth) {
if (filled) {
width = parentHeight * aspectRatio;
} else {
height = parentWidth / aspectRatio;
}
} else if (filled) {
height = parentWidth / aspectRatio;
} else {
width = parentHeight * aspectRatio;
}
setStyle(image, assign({
width: width,
height: height
}, getTransforms({
translateX: (parentWidth - width) / 2,
translateY: (parentHeight - height) / 2
})));
});
},
keydown: function keydown(event) {
var options = this.options;
if (!this.fulled || !options.keyboard) {
return;
}
switch (event.keyCode || event.which || event.charCode) {
// Escape
case 27:
if (this.played) {
this.stop();
} else if (options.inline) {
if (this.fulled) {
this.exit();
}
} else {
this.hide();
}
break;
// Space
case 32:
if (this.played) {
this.stop();
}
break;
// ArrowLeft
case 37:
this.prev(options.loop);
break;
// ArrowUp
case 38:
// Prevent scroll on Firefox
event.preventDefault(); // Zoom in
this.zoom(options.zoomRatio, true);
break;
// ArrowRight
case 39:
this.next(options.loop);
break;
// ArrowDown
case 40:
// Prevent scroll on Firefox
event.preventDefault(); // Zoom out
this.zoom(-options.zoomRatio, true);
break;
// Ctrl + 0
case 48: // Fall through
// Ctrl + 1
// eslint-disable-next-line no-fallthrough
case 49:
if (event.ctrlKey) {
event.preventDefault();
this.toggle();
}
break;
default:
}
},
dragstart: function dragstart(event) {
if (event.target.tagName.toLowerCase() === 'img') {
event.preventDefault();
}
},
pointerdown: function pointerdown(event) {
var options = this.options,
pointers = this.pointers;
var buttons = event.buttons,
button = event.button;
if (!this.viewed || this.showing || this.viewing || this.hiding // No primary button (Usually the left button)
// Note that touch events have no `buttons` or `button` property
|| isNumber(buttons) && buttons !== 1 || isNumber(button) && button !== 0 // Open context menu
|| event.ctrlKey) {
return;
} // Prevent default behaviours as page zooming in touch devices.
event.preventDefault();
if (event.changedTouches) {
forEach(event.changedTouches, function (touch) {
pointers[touch.identifier] = getPointer(touch);
});
} else {
pointers[event.pointerId || 0] = getPointer(event);
}
var action = options.movable ? ACTION_MOVE : false;
if (Object.keys(pointers).length > 1) {
action = ACTION_ZOOM;
} else if ((event.pointerType === 'touch' || event.type === 'touchstart') && this.isSwitchable()) {
action = ACTION_SWITCH;
}
if (options.transition && (action === ACTION_MOVE || action === ACTION_ZOOM)) {
removeClass(this.image, CLASS_TRANSITION);
}
this.action = action;
},
pointermove: function pointermove(event) {
var pointers = this.pointers,
action = this.action;
if (!this.viewed || !action) {
return;
}
event.preventDefault();
if (event.changedTouches) {
forEach(event.changedTouches, function (touch) {
assign(pointers[touch.identifier] || {}, getPointer(touch, true));
});
} else {
assign(pointers[event.pointerId || 0] || {}, getPointer(event, true));
}
this.change(event);
},
pointerup: function pointerup(event) {
var _this2 = this;
var options = this.options,
action = this.action,
pointers = this.pointers;
var pointer;
if (event.changedTouches) {
forEach(event.changedTouches, function (touch) {
pointer = pointers[touch.identifier];
delete pointers[touch.identifier];
});
} else {
pointer = pointers[event.pointerId || 0];
delete pointers[event.pointerId || 0];
}
if (!action) {
return;
}
event.preventDefault();
if (options.transition && (action === ACTION_MOVE || action === ACTION_ZOOM)) {
addClass(this.image, CLASS_TRANSITION);
}
this.action = false; // Emulate click and double click in touch devices to support backdrop and image zooming (#210).
if (IS_TOUCH_DEVICE && action !== ACTION_ZOOM && pointer && Date.now() - pointer.timeStamp < 500) {
clearTimeout(this.clickCanvasTimeout);
clearTimeout(this.doubleClickImageTimeout);
if (options.toggleOnDblclick && this.viewed && event.target === this.image) {
if (this.imageClicked) {
this.imageClicked = false; // This timeout will be cleared later when a native dblclick event is triggering
this.doubleClickImageTimeout = setTimeout(function () {
dispatchEvent(_this2.image, EVENT_DBLCLICK);
}, 50);
} else {
this.imageClicked = true; // The default timing of a double click in Windows is 500 ms
this.doubleClickImageTimeout = setTimeout(function () {
_this2.imageClicked = false;
}, 500);
}
} else {
this.imageClicked = false;
if (options.backdrop && options.backdrop !== 'static' && event.target === this.canvas) {
// This timeout will be cleared later when a native click event is triggering
this.clickCanvasTimeout = setTimeout(function () {
dispatchEvent(_this2.canvas, EVENT_CLICK);
}, 50);
}
}
}
},
resize: function resize() {
var _this3 = this;
if (!this.isShown || this.hiding) {
return;
}
this.initContainer();
this.initViewer();
this.renderViewer();
this.renderList();
if (this.viewed) {
this.initImage(function () {
_this3.renderImage();
});
}
if (this.played) {
if (this.options.fullscreen && this.fulled && !(document.fullscreenElement || document.webkitFullscreenElement || document.mozFullScreenElement || document.msFullscreenElement)) {
this.stop();
return;
}
forEach(this.player.getElementsByTagName('img'), function (image) {
addListener(image, EVENT_LOAD, _this3.loadImage.bind(_this3), {
once: true
});
dispatchEvent(image, EVENT_LOAD);
});
}
},
wheel: function wheel(event) {
var _this4 = this;
if (!this.viewed) {
return;
}
event.preventDefault(); // Limit wheel speed to prevent zoom too fast
if (this.wheeling) {
return;
}
this.wheeling = true;
setTimeout(function () {
_this4.wheeling = false;
}, 50);
var ratio = Number(this.options.zoomRatio) || 0.1;
var delta = 1;
if (event.deltaY) {
delta = event.deltaY > 0 ? 1 : -1;
} else if (event.wheelDelta) {
delta = -event.wheelDelta / 120;
} else if (event.detail) {
delta = event.detail > 0 ? 1 : -1;
}
this.zoom(-delta * ratio, true, event);
}
};
var methods = {
/** Show the viewer (only available in modal mode)
* @param {boolean} [immediate=false] - Indicates if show the viewer immediately or not.
* @returns {Viewer} this
*/
show: function show() {
var immediate = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
var element = this.element,
options = this.options;
if (options.inline || this.showing || this.isShown || this.showing) {
return this;
}
if (!this.ready) {
this.build();
if (this.ready) {
this.show(immediate);
}
return this;
}
if (isFunction(options.show)) {
addListener(element, EVENT_SHOW, options.show, {
once: true
});
}
if (dispatchEvent(element, EVENT_SHOW) === false || !this.ready) {
return this;
}
if (this.hiding) {
this.transitioning.abort();
}
this.showing = true;
this.open();
var viewer = this.viewer;
removeClass(viewer, CLASS_HIDE);
if (options.transition && !immediate) {
var shown = this.shown.bind(this);
this.transitioning = {
abort: function abort() {
removeListener(viewer, EVENT_TRANSITION_END, shown);
removeClass(viewer, CLASS_IN);
}
};
addClass(viewer, CLASS_TRANSITION); // Force reflow to enable CSS3 transition
// eslint-disable-next-line
viewer.offsetWidth;
addListener(viewer, EVENT_TRANSITION_END, shown, {
once: true
});
addClass(viewer, CLASS_IN);
} else {
addClass(viewer, CLASS_IN);
this.shown();
}
return this;
},
/**
* Hide the viewer (only available in modal mode)
* @param {boolean} [immediate=false] - Indicates if hide the viewer immediately or not.
* @returns {Viewer} this
*/
hide: function hide() {
var immediate = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
var element = this.element,
options = this.options;
if (options.inline || this.hiding || !(this.isShown || this.showing)) {
return this;
}
if (isFunction(options.hide)) {
addListener(element, EVENT_HIDE, options.hide, {
once: true
});
}
if (dispatchEvent(element, EVENT_HIDE) === false) {
return this;
}
if (this.showing) {
this.transitioning.abort();
}
this.hiding = true;
if (this.played) {
this.stop();
} else if (this.viewing) {
this.viewing.abort();
}
var viewer = this.viewer;
if (options.transition && !immediate) {
var hidden = this.hidden.bind(this);
var hide = function hide() {
// XXX: It seems the `event.stopPropagation()` method does not work here
setTimeout(function () {
addListener(viewer, EVENT_TRANSITION_END, hidden, {
once: true
});
removeClass(viewer, CLASS_IN);
}, 0);
};
this.transitioning = {
abort: function abort() {
if (this.viewed) {
removeListener(this.image, EVENT_TRANSITION_END, hide);
} else {
removeListener(viewer, EVENT_TRANSITION_END, hidden);
}
}
}; // Note that the `CLASS_TRANSITION` class will be removed on pointer down (#255)
if (this.viewed && hasClass(this.image, CLASS_TRANSITION)) {
addListener(this.image, EVENT_TRANSITION_END, hide, {
once: true
});
this.zoomTo(0, false, false, true);
} else {
hide();
}
} else {
removeClass(viewer, CLASS_IN);
this.hidden();
}
return this;
},
/**
* View one of the images with image's index
* @param {number} index - The index of the image to view.
* @returns {Viewer} this
*/
view: function view() {
var _this = this;
var index = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.options.initialViewIndex;
index = Number(index) || 0;
if (!this.isShown) {
this.index = index;
return this.show();
}
if (this.hiding || this.played || index < 0 || index >= this.length || this.viewed && index === this.index) {
return this;
}
if (this.viewing) {
this.viewing.abort();
}
var element = this.element,
options = this.options,
title = this.title,
canvas = this.canvas;
var item = this.items[index];
var img = item.querySelector('img');
var url = getData(img, 'originalUrl');
var alt = escapeHTMLEntities(img.getAttribute('alt'));
var image = document.createElement('img');
image.src = url;
image.alt = alt;
if (isFunction(options.view)) {
addListener(element, EVENT_VIEW, options.view, {
once: true
});
}
if (dispatchEvent(element, EVENT_VIEW, {
originalImage: this.images[index],
index: index,
image: image
}) === false || !this.isShown || this.hiding || this.played) {
return this;
}
this.image = image;
removeClass(this.items[this.index], CLASS_ACTIVE);
addClass(item, CLASS_ACTIVE);
this.viewed = false;
this.index = index;
this.imageData = {};
addClass(image, CLASS_INVISIBLE);
if (options.loading) {
addClass(canvas, CLASS_LOADING);
}
canvas.innerHTML = '';
canvas.appendChild(image); // Center current item
this.renderList(); // Clear title
title.innerHTML = ''; // Generate title after viewed
var onViewed = function onViewed() {
var imageData = _this.imageData;
var render = Array.isArray(options.title) ? options.title[1] : options.title;
title.innerHTML = escapeHTMLEntities(isFunction(render) ? render.call(_this, image, imageData) : "".concat(alt, " (").concat(imageData.naturalWidth, " \xD7 ").concat(imageData.naturalHeight, ")"));
};
var onLoad;
addListener(element, EVENT_VIEWED, onViewed, {
once: true
});
this.viewing = {
abort: function abort() {
removeListener(element, EVENT_VIEWED, onViewed);
if (image.complete) {
if (this.imageRendering) {
this.imageRendering.abort();
} else if (this.imageInitializing) {
this.imageInitializing.abort();
}
} else {
// Cancel download to save bandwidth.
image.src = '';
removeListener(image, EVENT_LOAD, onLoad);
if (this.timeout) {
clearTimeout(this.timeout);
}
}
}
};
if (image.complete) {
this.load();
} else {
addListener(image, EVENT_LOAD, onLoad = this.load.bind(this), {
once: true
});
if (this.timeout) {
clearTimeout(this.timeout);
} // Make the image visible if it fails to load within 1s
this.timeout = setTimeout(function () {
removeClass(image, CLASS_INVISIBLE);
_this.timeout = false;
}, 1000);
}
return this;
},
/**
* View the previous image
* @param {boolean} [loop=false] - Indicate if view the last one
* when it is the first one at present.
* @returns {Viewer} this
*/
prev: function prev() {
var loop = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
var index = this.index - 1;
if (index < 0) {
index = loop ? this.length - 1 : 0;
}
this.view(index);
return this;
},
/**
* View the next image
* @param {boolean} [loop=false] - Indicate if view the first one
* when it is the last one at present.
* @returns {Viewer} this
*/
next: function next() {
var loop = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
var maxIndex = this.length - 1;
var index = this.index + 1;
if (index > maxIndex) {
index = loop ? 0 : maxIndex;
}
this.view(index);
return this;
},
/**
* Move the image with relative offsets.
* @param {number} offsetX - The relative offset distance on the x-axis.
* @param {number} offsetY - The relative offset distance on the y-axis.
* @returns {Viewer} this
*/
move: function move(offsetX, offsetY) {
var imageData = this.imageData;
this.moveTo(isUndefined(offsetX) ? offsetX : imageData.left + Number(offsetX), isUndefined(offsetY) ? offsetY : imageData.top + Number(offsetY));
return this;
},
/**
* Move the image to an absolute point.
* @param {number} x - The x-axis coordinate.
* @param {number} [y=x] - The y-axis coordinate.
* @returns {Viewer} this
*/
moveTo: function moveTo(x) {
var y = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : x;
var imageData = this.imageData;
x = Number(x);
y = Number(y);
if (this.viewed && !this.played && this.options.movable) {
var changed = false;
if (isNumber(x)) {
imageData.left = x;
changed = true;
}
if (isNumber(y)) {
imageData.top = y;
changed = true;
}
if (changed) {
this.renderImage();
}
}
return this;
},
/**
* Zoom the image with a relative ratio.
* @param {number} ratio - The target ratio.
* @param {boolean} [hasTooltip=false] - Indicates if it has a tooltip or not.
* @param {Event} [_originalEvent=null] - The original event if any.
* @returns {Viewer} this
*/
zoom: function zoom(ratio) {
var hasTooltip = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
var _originalEvent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
var imageData = this.imageData;
ratio = Number(ratio);
if (ratio < 0) {
ratio = 1 / (1 - ratio);
} else {
ratio = 1 + ratio;
}
this.zoomTo(imageData.width * ratio / imageData.naturalWidth, hasTooltip, _originalEvent);
return this;
},
/**
* Zoom the image to an absolute ratio.
* @param {number} ratio - The target ratio.
* @param {boolean} [hasTooltip=false] - Indicates if it has a tooltip or not.
* @param {Event} [_originalEvent=null] - The original event if any.
* @param {Event} [_zoomable=false] - Indicates if the current zoom is available or not.
* @returns {Viewer} this
*/
zoomTo: function zoomTo(ratio) {
var _this2 = this;
var hasTooltip = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
var _originalEvent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
var _zoomable = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
var element = this.element,
options = this.options,
pointers = this.pointers,
imageData = this.imageData;
var width = imageData.width,
height = imageData.height,
left = imageData.left,
top = imageData.top,
naturalWidth = imageData.naturalWidth,
naturalHeight = imageData.naturalHeight;
ratio = Math.max(0, ratio);
if (isNumber(ratio) && this.viewed && !this.played && (_zoomable || options.zoomable)) {
if (!_zoomable) {
var minZoomRatio = Math.max(0.01, options.minZoomRatio);
var maxZoomRatio = Math.min(100, options.maxZoomRatio);
ratio = Math.min(Math.max(ratio, minZoomRatio), maxZoomRatio);
}
if (_originalEvent && ratio > 0.95 && ratio < 1.05) {
ratio = 1;
}
var newWidth = naturalWidth * ratio;
var newHeight = naturalHeight * ratio;
var offsetWidth = newWidth - width;
var offsetHeight = newHeight - height;
var oldRatio = width / naturalWidth;
if (isFunction(options.zoom)) {
addListener(element, EVENT_ZOOM, options.zoom, {
once: true
});
}
if (dispatchEvent(element, EVENT_ZOOM, {
ratio: ratio,
oldRatio: oldRatio,
originalEvent: _originalEvent
}) === false) {
return this;
}
this.zooming = true;
if (_originalEvent) {
var offset = getOffset(this.viewer);
var center = pointers && Object.keys(pointers).length ? getPointersCenter(pointers) : {
pageX: _originalEvent.pageX,
pageY: _originalEvent.pageY
}; // Zoom from the triggering point of the event
imageData.left -= offsetWidth * ((center.pageX - offset.left - left) / width);
imageData.top -= offsetHeight * ((center.pageY - offset.top - top) / height);
} else {
// Zoom from the center of the image
imageData.left -= offsetWidth / 2;
imageData.top -= offsetHeight / 2;
}
imageData.width = newWidth;
imageData.height = newHeight;
imageData.ratio = ratio;
this.renderImage(function () {
_this2.zooming = false;
if (isFunction(options.zoomed)) {
addListener(element, EVENT_ZOOMED, options.zoomed, {
once: true
});
}
dispatchEvent(element, EVENT_ZOOMED, {
ratio: ratio,
oldRatio: oldRatio,
originalEvent: _originalEvent
});
});
if (hasTooltip) {
this.tooltip();
}
}
return this;
},
/**
* Rotate the image with a relative degree.
* @param {number} degree - The rotate degree.
* @returns {Viewer} this
*/
rotate: function rotate(degree) {
this.rotateTo((this.imageData.rotate || 0) + Number(degree));
return this;
},
/**
* Rotate the image to an absolute degree.
* @param {number} degree - The rotate degree.
* @returns {Viewer} this
*/
rotateTo: function rotateTo(degree) {
var imageData = this.imageData;
degree = Number(degree);
if (isNumber(degree) && this.viewed && !this.played && this.options.rotatable) {
imageData.rotate = degree;
this.renderImage();
}
return this;
},
/**
* Scale the image on the x-axis.
* @param {number} scaleX - The scale ratio on the x-axis.
* @returns {Viewer} this
*/
scaleX: function scaleX(_scaleX) {
this.scale(_scaleX, this.imageData.scaleY);
return this;
},
/**
* Scale the image on the y-axis.
* @param {number} scaleY - The scale ratio on the y-axis.
* @returns {Viewer} this
*/
scaleY: function scaleY(_scaleY) {
this.scale(this.imageData.scaleX, _scaleY);
return this;
},
/**
* Scale the image.
* @param {number} scaleX - The scale ratio on the x-axis.
* @param {number} [scaleY=scaleX] - The scale ratio on the y-axis.
* @returns {Viewer} this
*/
scale: function scale(scaleX) {
var scaleY = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : scaleX;
var imageData = this.imageData;
scaleX = Number(scaleX);
scaleY = Number(scaleY);
if (this.viewed && !this.played && this.options.scalable) {
var changed = false;
if (isNumber(scaleX)) {
imageData.scaleX = scaleX;
changed = true;
}
if (isNumber(scaleY)) {
imageData.scaleY = scaleY;
changed = true;
}
if (changed) {
this.renderImage();
}
}
return this;
},
/**
* Play the images
* @param {boolean} [fullscreen=false] - Indicate if request fullscreen or not.
* @returns {Viewer} this
*/
play: function play() {
var _this3 = this;
var fullscreen = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
if (!this.isShown || this.played) {
return this;
}
var options = this.options,
player = this.player;
var onLoad = this.loadImage.bind(this);
var list = [];
var total = 0;
var index = 0;
this.played = true;
this.onLoadWhenPlay = onLoad;
if (fullscreen) {
this.requestFullscreen();
}
addClass(player, CLASS_SHOW);
forEach(this.items, function (item, i) {
var img = item.querySelector('img');
var image = document.createElement('img');
image.src = getData(img, 'originalUrl');
image.alt = escapeHTMLEntities(img.getAttribute('alt'));
total += 1;
addClass(image, CLASS_FADE);
toggleClass(image, CLASS_TRANSITION, options.transition);
if (hasClass(item, CLASS_ACTIVE)) {
addClass(image, CLASS_IN);
index = i;
}
list.push(image);
addListener(image, EVENT_LOAD, onLoad, {
once: true
});
player.appendChild(image);
});
if (isNumber(options.interval) && options.interval > 0) {
var play = function play() {
_this3.playing = setTimeout(function () {
removeClass(list[index], CLASS_IN);
index += 1;
index = index < total ? index : 0;
addClass(list[index], CLASS_IN);
play();
}, options.interval);
};
if (total > 1) {
play();
}
}
return this;
},
// Stop play
stop: function stop() {
var _this4 = this;
if (!this.played) {
return this;
}
var player = this.player;
this.played = false;
clearTimeout(this.playing);
forEach(player.getElementsByTagName('img'), function (image) {
removeListener(image, EVENT_LOAD, _this4.onLoadWhenPlay);
});
removeClass(player, CLASS_SHOW);
player.innerHTML = '';
this.exitFullscreen();
return this;
},
// Enter modal mode (only available in inline mode)
full: function full() {
var _this5 = this;
var options = this.options,
viewer = this.viewer,
image = this.image,
list = this.list;
if (!this.isShown || this.played || this.fulled || !options.inline) {
return this;
}
this.fulled = true;
this.open();
addClass(this.button, CLASS_FULLSCREEN_EXIT);
if (options.transition) {
removeClass(list, CLASS_TRANSITION);
if (this.viewed) {
removeClass(image, CLASS_TRANSITION);
}
}
addClass(viewer, CLASS_FIXED);
viewer.setAttribute('style', '');
setStyle(viewer, {
zIndex: options.zIndex
});
this.initContainer();
this.viewerData = assign({}, this.containerData);
this.renderList();
if (this.viewed) {
this.initImage(function () {
_this5.renderImage(function () {
if (options.transition) {
setTimeout(function () {
addClass(image, CLASS_TRANSITION);
addClass(list, CLASS_TRANSITION);
}, 0);
}
});
});
}
return this;
},
// Exit modal mode (only available in inline mode)
exit: function exit() {
var _this6 = this;
var options = this.options,
viewer = this.viewer,
image = this.image,
list = this.list;
if (!this.isShown || this.played || !this.fulled || !options.inline) {
return this;
}
this.fulled = false;
this.close();
removeClass(this.button, CLASS_FULLSCREEN_EXIT);
if (options.transition) {
removeClass(list, CLASS_TRANSITION);
if (this.viewed) {
removeClass(image, CLASS_TRANSITION);
}
}
removeClass(viewer, CLASS_FIXED);
setStyle(viewer, {
zIndex: options.zIndexInline
});
this.viewerData = assign({}, this.parentData);
this.renderViewer();
this.renderList();
if (this.viewed) {
this.initImage(function () {
_this6.renderImage(function () {
if (options.transition) {
setTimeout(function () {
addClass(image, CLASS_TRANSITION);
addClass(list, CLASS_TRANSITION);
}, 0);
}
});
});
}
return this;
},
// Show the current ratio of the image with percentage
tooltip: function tooltip() {
var _this7 = this;
var options = this.options,
tooltipBox = this.tooltipBox,
imageData = this.imageData;
if (!this.viewed || this.played || !options.tooltip) {
return this;
}
tooltipBox.textContent = "".concat(Math.round(imageData.ratio * 100), "%");
if (!this.tooltipping) {
if (options.transition) {
if (this.fading) {
dispatchEvent(tooltipBox, EVENT_TRANSITION_END);
}
addClass(tooltipBox, CLASS_SHOW);
addClass(tooltipBox, CLASS_FADE);
addClass(tooltipBox, CLASS_TRANSITION); // Force reflow to enable CSS3 transition
// eslint-disable-next-line
tooltipBox.offsetWidth;
addClass(tooltipBox, CLASS_IN);
} else {
addClass(tooltipBox, CLASS_SHOW);
}
} else {
clearTimeout(this.tooltipping);
}
this.tooltipping = setTimeout(function () {
if (options.transition) {
addListener(tooltipBox, EVENT_TRANSITION_END, function () {
removeClass(tooltipBox, CLASS_SHOW);
removeClass(tooltipBox, CLASS_FADE);
removeClass(tooltipBox, CLASS_TRANSITION);
_this7.fading = false;
}, {
once: true
});
removeClass(tooltipBox, CLASS_IN);
_this7.fading = true;
} else {
removeClass(tooltipBox, CLASS_SHOW);
}
_this7.tooltipping = false;
}, 1000);
return this;
},
// Toggle the image size between its natural size and initial size
toggle: function toggle() {
if (this.imageData.ratio === 1) {
this.zoomTo(this.initialImageData.ratio, true);
} else {
this.zoomTo(1, true);
}
return this;
},
// Reset the image to its initial state
reset: function reset() {
if (this.viewed && !this.played) {
this.imageData = assign({}, this.initialImageData);
this.renderImage();
}
return this;
},
// Update viewer when images changed
update: function update() {
var element = this.element,
options = this.options,
isImg = this.isImg; // Destroy viewer if the target image was deleted
if (isImg && !element.parentNode) {
return this.destroy();
}
var images = [];
forEach(isImg ? [element] : element.querySelectorAll('img'), function (image) {
if (options.filter) {
if (options.filter(image)) {
images.push(image);
}
} else {
images.push(image);
}
});
if (!images.length) {
return this;
}
this.images = images;
this.length = images.length;
if (this.ready) {
var indexes = [];
forEach(this.items, function (item, i) {
var img = item.querySelector('img');
var image = images[i];
if (image) {
if (image.src !== img.src) {
indexes.push(i);
}
} else {
indexes.push(i);
}
});
setStyle(this.list, {
width: 'auto'
});
this.initList();
if (this.isShown) {
if (this.length) {
if (this.viewed) {
var index = indexes.indexOf(this.index);
if (index >= 0) {
this.viewed = false;
this.view(Math.max(this.index - (index + 1), 0));
} else {
addClass(this.items[this.index], CLASS_ACTIVE);
}
}
} else {
this.image = null;
this.viewed = false;
this.index = 0;
this.imageData = {};
this.canvas.innerHTML = '';
this.title.innerHTML = '';
}
}
} else {
this.build();
}
return this;
},
// Destroy the viewer
destroy: function destroy() {
var element = this.element,
options = this.options;
if (!element[NAMESPACE]) {
return this;
}
this.destroyed = true;
if (this.ready) {
if (this.played) {
this.stop();
}
if (options.inline) {
if (this.fulled) {
this.exit();
}
this.unbind();
} else if (this.isShown) {
if (this.viewing) {
if (this.imageRendering) {
this.imageRendering.abort();
} else if (this.imageInitializing) {
this.imageInitializing.abort();
}
}
if (this.hiding) {
this.transitioning.abort();
}
this.hidden();
} else if (this.showing) {
this.transitioning.abort();
this.hidden();
}
this.ready = false;
this.viewer.parentNode.removeChild(this.viewer);
} else if (options.inline) {
if (this.delaying) {
this.delaying.abort();
} else if (this.initializing) {
this.initializing.abort();
}
}
if (!options.inline) {
removeListener(element, EVENT_CLICK, this.onStart);
}
element[NAMESPACE] = undefined;
return this;
}
};
var others = {
open: function open() {
var body = this.body;
addClass(body, CLASS_OPEN);
body.style.paddingRight = "".concat(this.scrollbarWidth + (parseFloat(this.initialBodyPaddingRight) || 0), "px");
},
close: function close() {
var body = this.body;
removeClass(body, CLASS_OPEN);
body.style.paddingRight = this.initialBodyPaddingRight;
},
shown: function shown() {
var element = this.element,
options = this.options;
this.fulled = true;
this.isShown = true;
this.render();
this.bind();
this.showing = false;
if (isFunction(options.shown)) {
addListener(element, EVENT_SHOWN, options.shown, {
once: true
});
}
if (dispatchEvent(element, EVENT_SHOWN) === false) {
return;
}
if (this.ready && this.isShown && !this.hiding) {
this.view(this.index);
}
},
hidden: function hidden() {
var element = this.element,
options = this.options;
this.fulled = false;
this.viewed = false;
this.isShown = false;
this.close();
this.unbind();
addClass(this.viewer, CLASS_HIDE);
this.resetList();
this.resetImage();
this.hiding = false;
if (!this.destroyed) {
if (isFunction(options.hidden)) {
addListener(element, EVENT_HIDDEN, options.hidden, {
once: true
});
}
dispatchEvent(element, EVENT_HIDDEN);
}
},
requestFullscreen: function requestFullscreen() {
var document = this.element.ownerDocument;
if (this.fulled && !(document.fullscreenElement || document.webkitFullscreenElement || document.mozFullScreenElement || document.msFullscreenElement)) {
var documentElement = document.documentElement; // Element.requestFullscreen()
if (documentElement.requestFullscreen) {
documentElement.requestFullscreen();
} else if (documentElement.webkitRequestFullscreen) {
documentElement.webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT);
} else if (documentElement.mozRequestFullScreen) {
documentElement.mozRequestFullScreen();
} else if (documentElement.msRequestFullscreen) {
documentElement.msRequestFullscreen();
}
}
},
exitFullscreen: function exitFullscreen() {
var document = this.element.ownerDocument;
if (this.fulled && (document.fullscreenElement || document.webkitFullscreenElement || document.mozFullScreenElement || document.msFullscreenElement)) {
// Document.exitFullscreen()
if (document.exitFullscreen) {
document.exitFullscreen();
} else if (document.webkitExitFullscreen) {
document.webkitExitFullscreen();
} else if (document.mozCancelFullScreen) {
document.mozCancelFullScreen();
} else if (document.msExitFullscreen) {
document.msExitFullscreen();
}
}
},
change: function change(event) {
var options = this.options,
pointers = this.pointers;
var pointer = pointers[Object.keys(pointers)[0]];
var offsetX = pointer.endX - pointer.startX;
var offsetY = pointer.endY - pointer.startY;
switch (this.action) {
// Move the current image
case ACTION_MOVE:
this.move(offsetX, offsetY);
break;
// Zoom the current image
case ACTION_ZOOM:
this.zoom(getMaxZoomRatio(pointers), false, event);
break;
case ACTION_SWITCH:
{
this.action = 'switched';
var absoluteOffsetX = Math.abs(offsetX);
if (absoluteOffsetX > 1 && absoluteOffsetX > Math.abs(offsetY)) {
// Empty `pointers` as `touchend` event will not be fired after swiped in iOS browsers.
this.pointers = {};
if (offsetX > 1) {
this.prev(options.loop);
} else if (offsetX < -1) {
this.next(options.loop);
}
}
break;
}
default:
} // Override
forEach(pointers, function (p) {
p.startX = p.endX;
p.startY = p.endY;
});
},
isSwitchable: function isSwitchable() {
var imageData = this.imageData,
viewerData = this.viewerData;
return this.length > 1 && imageData.left >= 0 && imageData.top >= 0 && imageData.width <= viewerData.width && imageData.height <= viewerData.height;
}
};
var AnotherViewer = WINDOW.Viewer;
var Viewer =
/*#__PURE__*/
function () {
/**
* Create a new Viewer.
* @param {Element} element - The target element for viewing.
* @param {Object} [options={}] - The configuration options.
*/
function Viewer(element) {
var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
_classCallCheck(this, Viewer);
if (!element || element.nodeType !== 1) {
throw new Error('The first argument is required and must be an element.');
}
this.element = element;
this.options = assign({}, DEFAULTS, isPlainObject(options) && options);
this.action = false;
this.fading = false;
this.fulled = false;
this.hiding = false;
this.imageClicked = false;
this.imageData = {};
this.index = this.options.initialViewIndex;
this.isImg = false;
this.isShown = false;
this.length = 0;
this.played = false;
this.playing = false;
this.pointers = {};
this.ready = false;
this.showing = false;
this.timeout = false;
this.tooltipping = false;
this.viewed = false;
this.viewing = false;
this.wheeling = false;
this.zooming = false;
this.init();
}
_createClass(Viewer, [{
key: "init",
value: function init() {
var _this = this;
var element = this.element,
options = this.options;
if (element[NAMESPACE]) {
return;
}
element[NAMESPACE] = this;
var isImg = element.tagName.toLowerCase() === 'img';
var images = [];
forEach(isImg ? [element] : element.querySelectorAll('img'), function (image) {
if (isFunction(options.filter)) {
if (options.filter.call(_this, image)) {
images.push(image);
}
} else {
images.push(image);
}
});
this.isImg = isImg;
this.length = images.length;
this.images = images;
var ownerDocument = element.ownerDocument;
var body = ownerDocument.body || ownerDocument.documentElement;
this.body = body;
this.scrollbarWidth = window.innerWidth - ownerDocument.documentElement.clientWidth;
this.initialBodyPaddingRight = window.getComputedStyle(body).paddingRight; // Override `transition` option if it is not supported
if (isUndefined(document.createElement(NAMESPACE).style.transition)) {
options.transition = false;
}
if (options.inline) {
var count = 0;
var progress = function progress() {
count += 1;
if (count === _this.length) {
var timeout;
_this.initializing = false;
_this.delaying = {
abort: function abort() {
clearTimeout(timeout);
}
}; // build asynchronously to keep `this.viewer` is accessible in `ready` event handler.
timeout = setTimeout(function () {
_this.delaying = false;
_this.build();
}, 0);
}
};
this.initializing = {
abort: function abort() {
forEach(images, function (image) {
if (!image.complete) {
removeListener(image, EVENT_LOAD, progress);
}
});
}
};
forEach(images, function (image) {
if (image.complete) {
progress();
} else {
addListener(image, EVENT_LOAD, progress, {
once: true
});
}
});
} else {
addListener(element, EVENT_CLICK, this.onStart = function (_ref) {
var target = _ref.target;
if (target.tagName.toLowerCase() === 'img' && (!isFunction(options.filter) || options.filter.call(_this, target))) {
_this.view(_this.images.indexOf(target));
}
});
}
}
}, {
key: "build",
value: function build() {
if (this.ready) {
return;
}
var element = this.element,
options = this.options;
var parent = element.parentNode;
var template = document.createElement('div');
template.innerHTML = TEMPLATE;
var viewer = template.querySelector(".".concat(NAMESPACE, "-container"));
var title = viewer.querySelector(".".concat(NAMESPACE, "-title"));
var toolbar = viewer.querySelector(".".concat(NAMESPACE, "-toolbar"));
var navbar = viewer.querySelector(".".concat(NAMESPACE, "-navbar"));
var button = viewer.querySelector(".".concat(NAMESPACE, "-button"));
var canvas = viewer.querySelector(".".concat(NAMESPACE, "-canvas"));
this.parent = parent;
this.viewer = viewer;
this.title = title;
this.toolbar = toolbar;
this.navbar = navbar;
this.button = button;
this.canvas = canvas;
this.footer = viewer.querySelector(".".concat(NAMESPACE, "-footer"));
this.tooltipBox = viewer.querySelector(".".concat(NAMESPACE, "-tooltip"));
this.player = viewer.querySelector(".".concat(NAMESPACE, "-player"));
this.list = viewer.querySelector(".".concat(NAMESPACE, "-list"));
addClass(title, !options.title ? CLASS_HIDE : getResponsiveClass(Array.isArray(options.title) ? options.title[0] : options.title));
addClass(navbar, !options.navbar ? CLASS_HIDE : getResponsiveClass(options.navbar));
toggleClass(button, CLASS_HIDE, !options.button);
if (options.backdrop) {
addClass(viewer, "".concat(NAMESPACE, "-backdrop"));
if (!options.inline && options.backdrop !== 'static') {
setData(canvas, DATA_ACTION, 'hide');
}
}
if (isString(options.className) && options.className) {
// In case there are multiple class names
options.className.split(REGEXP_SPACES).forEach(function (className) {
addClass(viewer, className);
});
}
if (options.toolbar) {
var list = document.createElement('ul');
var custom = isPlainObject(options.toolbar);
var zoomButtons = BUTTONS.slice(0, 3);
var rotateButtons = BUTTONS.slice(7, 9);
var scaleButtons = BUTTONS.slice(9);
if (!custom) {
addClass(toolbar, getResponsiveClass(options.toolbar));
}
forEach(custom ? options.toolbar : BUTTONS, function (value, index) {
var deep = custom && isPlainObject(value);
var name = custom ? hyphenate(index) : value;
var show = deep && !isUndefined(value.show) ? value.show : value;
if (!show || !options.zoomable && zoomButtons.indexOf(name) !== -1 || !options.rotatable && rotateButtons.indexOf(name) !== -1 || !options.scalable && scaleButtons.indexOf(name) !== -1) {
return;
}
var size = deep && !isUndefined(value.size) ? value.size : value;
var click = deep && !isUndefined(value.click) ? value.click : value;
var item = document.createElement('li');
item.setAttribute('role', 'button');
addClass(item, "".concat(NAMESPACE, "-").concat(name));
if (!isFunction(click)) {
setData(item, DATA_ACTION, name);
}
if (isNumber(show)) {
addClass(item, getResponsiveClass(show));
}
if (['small', 'large'].indexOf(size) !== -1) {
addClass(item, "".concat(NAMESPACE, "-").concat(size));
} else if (name === 'play') {
addClass(item, "".concat(NAMESPACE, "-large"));
}
if (isFunction(click)) {
addListener(item, EVENT_CLICK, click);
}
list.appendChild(item);
});
toolbar.appendChild(list);
} else {
addClass(toolbar, CLASS_HIDE);
}
if (!options.rotatable) {
var rotates = toolbar.querySelectorAll('li[class*="rotate"]');
addClass(rotates, CLASS_INVISIBLE);
forEach(rotates, function (rotate) {
toolbar.appendChild(rotate);
});
}
if (options.inline) {
addClass(button, CLASS_FULLSCREEN);
setStyle(viewer, {
zIndex: options.zIndexInline
});
if (window.getComputedStyle(parent).position === 'static') {
setStyle(parent, {
position: 'relative'
});
}
parent.insertBefore(viewer, element.nextSibling);
} else {
addClass(button, CLASS_CLOSE);
addClass(viewer, CLASS_FIXED);
addClass(viewer, CLASS_FADE);
addClass(viewer, CLASS_HIDE);
setStyle(viewer, {
zIndex: options.zIndex
});
var container = options.container;
if (isString(container)) {
container = element.ownerDocument.querySelector(container);
}
if (!container) {
container = this.body;
}
container.appendChild(viewer);
}
if (options.inline) {
this.render();
this.bind();
this.isShown = true;
}
this.ready = true;
if (isFunction(options.ready)) {
addListener(element, EVENT_READY, options.ready, {
once: true
});
}
if (dispatchEvent(element, EVENT_READY) === false) {
this.ready = false;
return;
}
if (this.ready && options.inline) {
this.view(this.index);
}
}
/**
* Get the no conflict viewer class.
* @returns {Viewer} The viewer class.
*/
}], [{
key: "noConflict",
value: function noConflict() {
window.Viewer = AnotherViewer;
return Viewer;
}
/**
* Change the default options.
* @param {Object} options - The new default options.
*/
}, {
key: "setDefaults",
value: function setDefaults(options) {
assign(DEFAULTS, isPlainObject(options) && options);
}
}]);
return Viewer;
}();
assign(Viewer.prototype, render, events, handlers, methods, others);
return Viewer;
}));
;
(function ($) {
// 绑定image
$(document).on('click', '.preview-image', function () {
var url = $(this).attr('src');
var index = 0;
var urlList = [];
$('.preview-image').each(function (i) {
var s = $(this).attr('src');
if (s == url) {
index = i;
}
urlList.push(s);
});
window.top.$.showImages(urlList, index);
});
$.extend({
showImages: function (imgList, index) {
// 构建临时div
var div = document.createElement("div");
for (var i = 0; i < imgList.length; i++) {
var url = imgList[i];
var image = new Image();
image.src = url;
div.appendChild(image);
}
// 创建 viewer 对象
var viewer = new Viewer(div, {
hidden: function () {
viewer.destroy();
}
});
viewer.view(index);
}
});
})(jQuery);
\ No newline at end of file
*{
margin:0;
padding:0;
}
body {
font-family: -apple-system,BlinkMacSystemFont,PingFang SC,Hiragino Sans GB,Microsoft YaHei,\\5FAE\8F6F\96C5\9ED1,helvetica neue,helvetica,ubuntu,roboto,noto,segoe ui,Arial,sans-serif;
background: #eef1f5;
}
ul,ol,li{
list-style: none;
}
a{
text-decoration: none!important;
}
img{
border: none;
}
.clearfix:after{
content: '';
height: 0;
display: block;
clear: both;
visibility: hidden;
overflow: hidden;
}
/* 閻犱礁澧介悿鍡楊煥濮橆剙袟闁哄绱曞▓鎴﹀冀瀹勬壆纭� */
::-webkit-scrollbar {
width:5px;
}
/* 婵犲﹥鑹炬慨鈺佄i敓锟� */
::-webkit-scrollbar-track {
-webkit-box-shadow:inset006pxrgba(0,0,0,0.3);
border-radius:2px;
}
/* 婵犲﹥鑹炬慨鈺呭级閳╁啰鎷ㄩ柛褝鎷� */
::-webkit-scrollbar-thumb {
border-radius:10px;
background:rgba(0,0,0,0.1);
-webkit-box-shadow:inset006pxrgba(0,0,0,0.5);
}
::-webkit-scrollbar-thumb:window-inactive {
background:rgba(200,200,200,1);
}
.gtoa-header{
position: fixed;
top:0;
left: 0;
width: 100%;
height:90px;
background-color: #fff;
z-index: 99;
box-shadow: 0 0 30px rgba(0,0,0,0.1);
}
.gtoa-logo{
float: left;
/*padding: 25px 20px 0 20px;*/
padding: 16px 46px;
text-align: center;
width:auto;
border-right: 1px solid #eef1f5;
height: 65px;
}
.gtoa-logo a{
/*float: left;*/
/*margin-right: 20px;*/
}
.gtoa-logo img{
/*display: block;*/
/*height: 36px;*/
display: inline;
height: 32px;
}
.gtoa-logo h1{
/*float: left;*/
/*font-size: 21px;*/
color: #333;
font-size: 18px;
line-height: 16px;
padding-top: 4px;
letter-spacing: 3px;
/*line-height: 36px;*/
}
.gtoa-setting-box{
float: left;
width:46%;
padding: 16px 0 0 20px;
height: 70px;
}
.gtoa-setting-box .fa{
display: block;
font-size:28px;
color:#89939c;
margin: 2px auto 2px;
}
.gtoa-online-time{
float: left;
}
.gtoa-online-time p{
font-size: 14px;
color: #89939c;
line-height: 24px;
}
.gtoa-online-time p span{
color: #333;
}
.gtoa-exit-btn{
float: right;
margin-right: 40px;
}
.gtoa-setting-btn{
float: right;
margin-right: 40px;
}
.gtoa-old-version-btn{
width: 60px;
text-align:center;
float: right;
position: relative;
/*margin-right: 40px;*/
}
.gtoa-exit-btn span,.gtoa-setting-btn span,.gtoa-old-version-btn span{
color: #bfc5d1;
font-size: 14px;
line-height: 20px;
}
.gtoa-login-status{
float: right;
width: 40%;
padding: 20px 0 0 20px;
height: 70px;
border-left: 1px solid #eef1f5;
}
.gtoa-login-pic{
position: relative;
float: left;
width:50px;
height: 50px;
border-radius: 50%;
overflow: hidden;
margin-right: 10px;
}
.gtoa-login-pic .fa{
position:relative;
background: #eef1f5;
padding: 10px 15px;
color: #89939c;
font-size: 31px;
}
.gtoa-login-pic .usert{
background: none;
position: absolute;
top: 4px;
right: -8px;
color: #b9b9b9;
}
.gtoa-login-pic img{
width: 100%;
}
.gtoa-login-name{
height: 20px;
line-height: 20px;
font-size: 16px;
color: #333;
}
.gtoa-login-position{
position: relative;
padding-top: 4px;
color: #89939c;
}
.gtoa-login-position p{
float: left;
width: 80%;
line-height: 20px;
height: 20px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
}
.gtoa-positon-select{
float: left;
cursor: pointer;
transition: transform .3s ease;
}
.gtoa-positon-select.turnUp{
transform: rotate(180deg);
}
.gtoa-login-position ul{
position: absolute;
top:40px;
right: -70px;
left: -15px;
border:1px solid #eef1f5;
margin-top: 0;
padding: 8px 8px 10px 10px;
width: 383px !important;
max-height: 120px;
overflow-y: auto;
background-color: #fff;
display: none;
box-shadow: 0 0 30px rgba(0,0,0,.1);
}
.gtoa-login-position ul li{
font-size: 16px;
line-height: 30px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
}
.gtoa-login-position ul li a{
color: #89939c;
user-select:none;
}
.gtoa-login-position ul li.on a,.gtoa-login-position ul li:hover a{
color: #3366cc;
}
@media screen and (max-width: 1600px) {
.gtoa-setting-box{
width: 40%;
}
}
@media screen and (max-width: 1366px) {
.gtoa-header{
height: 70px;
}
.gtoa-logo{
/*padding: 15px 15px 0 15px;*/
padding: 10px 16px;
height: 55px;
}
.gtoa-logo h1{
/*font-size: 18px;*/
font-size: 14px;
padding-top: 0;
}
.gtoa-logo img {
height: 28px;
}
.gtoa-logo a{
margin-right: 10px;
}
.gtoa-setting-box{
padding-top: 12px;
width: 46%;
box-sizing: border-box;
}
.gtoa-online-time p{
font-size: 12px;
}
.gtoa-exit-btn{
margin-right: 25px;
}
.gtoa-old-version-btn img,.gtoa-exit-btn img,.gtoa-setting-btn img{
height: 20px;
}
.gtoa-exit-btn span, .gtoa-setting-btn span, .gtoa-old-version-btn span{
font-size: 12px;
}
.gtoa-login-status{
padding-top: 15px;
width: auto;
height: 55px;
}
.gtoa-login-pic{
width: 40px;
height: 40px;
}
.gtoa-login-name{
font-size: 14px;
}
.gtoa-login-position{
padding-top: 4px;
font-size: 14px;
}
.gtoa-login-position ul{
top:35px;
}
.gtoa-login-position ul li{
font-size: 14px;
}
}
@media screen and (max-width: 1288px) {
.gtoa-setting-box{
width:50%;
}
.gtoa-logo h1{
/*font-size: 16px;*/
font-size: 14px;
}
.gtoa-logo img{
height: 25px;
margin-top: 6px;
}
.gtoa-login-status{
padding-left: 15px;
}
.gtoa-setting-box{
padding-left: 15px;
}
.gtoa-exit-btn{
margin-right: 15px;
}
.gtoa-login-position ul{
width: 90px;
}
}
@media screen and (max-width: 996px) {
/*.gtoa-logo h1{*/
/* display: none;*/
/*}*/
.gtoa-setting-box{
width: calc(100% - 350px);
}
}
@media screen and (max-width:768px){
.gtoa-logo{
width: 110px;
}
.gtoa-login-pic{
width: 35px;
height: 35px;
margin-top: 3px;
}
.gtoa-login-name{
padding-top: 12px;
font-size: 12px;
}
.gtoa-login-position{
padding-top: 12px;
font-size: 12px;
}
.gtoa-login-position ul li{
font-size: 12px;
}
}
@media screen and (max-width:730px){
.gtoa-online-time{
display: none;
}
.gtoa-old-version-btn, .gtoa-exit-btn{
margin-right: 25px;
}
}
/* 鐎归潻缂氶弲鍫曟嚕濠婂啫绀� */
.gtoa-left-menu{
position: fixed;
top:90px;
left: 0;
height: 100%;
height: calc(100vh - 90px);
background-color: #3366cc;
width: 200px;
box-sizing: border-box;
padding-bottom: 30px;
z-index: 98;
}
.gtoa-menu-list{
max-height: 100%;
overflow-y: auto;
}
.gtoa-menu-list li{
padding: 20px 0 20px 20px;
border-left: 5px solid #3366cc;
height: 20px;
}
.gtoa-menu-list li i{
color:#fff;
font-size:16px;
margin-right:10px;
}
.gtoa-menu-list li.on i,.gtoa-menu-list li:hover i{
color:#3366cc;
}
.gtoa-menu-list li a{
position: relative;
display: inline-block;
user-select:none;
}
.gtoa-menu-list li img{
float: left;
margin-right: 15px;
}
.gtoa-menu-list li span{
line-height: 22px;
font-size: 16px;
color: #fff;
}
.gtoa-menu-list li em{
position: absolute;
left: 100px;
top:-15px;
font-style: normal;
color: #fff;
background-color: #d7001d;
display: block;
min-width: 20px;
height: 20px;
text-align: center;
font-size: 14px;
line-height: 20px;
border-radius: 10px 10px 10px 0;
padding:0 5px 0 3px;
box-sizing: border-box;
}
.gtoa-menu-list li.on{
border-left: 5px solid #7daff4;
background-color: #fff;
}
.gtoa-menu-list li:hover{
border-left: 5px solid #7daff4;
background-color: #fff;
}
.gtoa-menu-list li.on span,.gtoa-menu-list li:hover span{
color: #3366cc;
}
.gtoa-menu-list li .on-icon{
display: none;
}
.gtoa-menu-list li.on img{
display: none;
}
.gtoa-menu-list li.on .on-icon{
display: block;
}
.gtoa-menu-list li:hover img{
display: none;
}
.gtoa-menu-list li:hover .on-icon{
display: block;
}
.gtoa-submenu{
position: fixed;
top:90px;
left: 200px;
background-color: #fff;
width: 240px;
height: 100%;
padding-bottom: 90px;
box-sizing: border-box;
padding-left:21px;
overflow-y: auto;
border-top: 1px solid #eef1f5;
display: none;
z-index: 98;
box-shadow: 10px 0 30px rgba(0,0,0,.2);
}
.gtoa-submenu dl{
margin-top: 35px;
}
.gtoa-submenu dt{
line-height: 1;
margin-bottom: 20px;
}
.gtoa-submenu dt a{
font-size: 18px;
color: #333;
font-weight: bold;
}
.gtoa-submenu dd{
line-height: 1.2;
margin-bottom: 10px;
}
.gtoa-submenu dd i{
float: left;
width: 4px;
height: 4px;
border:1px solid #bfc5d1;
border-radius: 50%;
margin: 8px 15px 0 0;
}
.gtoa-submenu dd a{
position: static;
color: #666;
font-size: 16px;
line-height: 1.2;
}
.gtoa-submenu dd:hover a{
color: #3366cc;
}
.gtoa-submenu dd:hover i{
background-color: #3366cc;
border-color: #3366cc;
}
.gtoa-menu-list li:hover .gtoa-submenu{
/* display: block; */
}
.gtoa-left-menu .gtoa-slide-btn{
position: absolute;
bottom: 0;
right: 0;
display: block;
width: auto;
height: auto;
z-index: 99;
}
.gtoa-left-menu .gtoa-slide-btn img{
display: block;
width: 40px;
}
.gtoa-left-menu.menu-slide-left{
width: 50px;
}
.gtoa-left-menu.menu-slide-left li{
padding-left: 15px;
border-width: 2px;
}
.gtoa-left-menu.menu-slide-left li span{
display: none;
}
.menu-slide-left .gtoa-menu-list li em{
left: 10px;
top:-15px;
z-index: 100;
border-radius: 50%;
padding: 2px;
width: 16px;
height: 16px;
line-height: 14px;
font-size: 12px;
min-width: auto;
box-sizing: content-box;
transform: scale(0.7);
overflow: hidden;
}
.gtoa-left-menu.menu-slide-left .gtoa-submenu{
left: 50px;
}
.gtoa-left-menu .gtoa-slide-btn .gtoa-right-btn{
display: none;
}
.gtoa-left-menu .gtoa-slide-btn.slide-left .gtoa-left-btn{
display: none;
}
.gtoa-left-menu .gtoa-slide-btn.slide-left .gtoa-right-btn{
display: block;
}
.gtoa-left-menu.menu-slide-left .gtoa-slide-btn{
left: 0;
right: auto;
}
@media screen and (max-width: 1600px){
.gtoa-menu-list li{
padding: 15px 0 15px 35px;
}
.gtoa-menu-list li em{
height: 14px;
font-size: 12px;
line-height: 14px;
top:-12px;
}
}
@media screen and (min-width: 1366px) {
.gtoa-login-name {
padding-top: 10px;
}
.gtoa-login-position ul {
left: -159px;
}
}
@media screen and (max-width: 1366px) {
.gtoa-left-menu{
top:70px;
width: 160px;
height: 100%;
height: calc(100vh - 70px);
}
.gtoa-submenu{
top:70px;
}
.gtoa-menu-list li{
padding: 15px 0 15px 20px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.gtoa-menu-list li em{
left: 90px;
transform: scale(0.8);
transform-origin: left bottom;
}
.gtoa-menu-list li span{
font-size: 14px;
}
.gtoa-menu-list li img{
margin-right: 8px;
}
.gtoa-submenu{
left: 160px;
width: 160px;
padding-left: 25px;
}
.gtoa-submenu dl{
margin-top: 25px;
}
.gtoa-submenu dt{
margin-bottom: 15px;
}
.gtoa-submenu dt a{
font-size: 16px;
}
.gtoa-submenu dd a{
font-size: 14px;
}
.gtoa-submenu dd i{
margin: 7px 8px 0 0;
}
.gtoa-left-menu .gtoa-slide-btn img{
width: 30px;
}
}
@media screen and (max-width: 768px) {
.gtoa-left-menu{
width: 140px;
}
.gtoa-menu-list li{
padding: 10px 0 10px 10px;
}
.gtoa-menu-list li em{
top:-12px;
}
.gtoa-submenu{
left: 140px;
}
}
/* 闁告劕鎳庨鎰板礌閿燂拷 */
.gtoa-container{
height: calc(100vh - 90px);
margin-left: 200px;
background-color: #eef1f5;
margin-top: 90px;
overflow-y: hidden;
}
/** sinosoft add new style 20190626 **/
.gtoa-container-tab{
height:50px;
width:100%;
background-color:#fff;
line-height:50px;
padding-left: 30px;
box-sizing: border-box;
font-size: 16px;
border-bottom:2px solid #3366cc;
}
.gtoa-container-tab.hide-tab{
display:none;
}
.gtoa-container-left.gtoa-container{
margin-left: 50px;
}
.gtoa-container-tab .tabs-items a{
color:#2f4050;
padding:0 9px 0 9px;
display: block;
width: auto;
height:100%;
float:left;
}
.gtoa-container-tab .tabs-items a:hover{
background-color: #f2f2f2;
}
.gtoa-container-tab .tabs-items a.active,.gtoa-container-tab .tabs-items a.active:hover{
color:#fff;
background-color: #3366cc;
}
@media screen and (max-width: 1366px) {
.gtoa-container{
margin-left: 160px;
margin-top: 70px;
height: calc(100vh - 70px);
}
.gtoa-container-tab{
height: 50px;
line-height:50px;
font-size: 14px;
}
}
@media screen and (max-width: 768px) {
.gtoa-container{
margin-left: 140px;
}
}
/* iframe */
.gtoa-iframe{
width: 100%;
height: calc(100vh - 90px);
}
.gtoa-container-tab+.gtoa-iframe{
height: calc(100vh - 150px);
}
.gtoa-container-tab.hide-tab+.gtoa-iframe{
height: calc(100vh - 90px);
}
@media screen and (max-width: 1366px) {
.gtoa-iframe{
height: calc(100vh - 70px);
}
.gtoa-container-tab+.gtoa-iframe{
height: calc(100vh - 120px);
}
.gtoa-container-tab.hide-tab+.gtoa-iframe{
height: calc(100vh - 70px);
}
}
/* 闁告柣鍔庨弫锟� */
@-webkit-keyframes salixmove{
from {
transform:translate3d(100px,-100px,0) scale(0) skew(5deg,0deg);
}
to {
transform:translate3d(0,0,0) scale(1) skew(5deg,0deg);
}
}
@keyframes salixmove{
from {
transform:translate3d(100px,-100px,0) scale(0) skew(5deg,0deg);
}
to {
transform:translate3d(0,0,0) scale(1) skew(5deg,0deg);
}
}
@-webkit-keyframes salixhide{
from {
transform:scale(1);
}
to {
transform:scale(0.1);
}
}
@keyframes salixhide{
from {
transform:scale(1);
}
to {
transform:scale(0.1);
}
}
@-webkit-keyframes salix-floating{
0% {
-webkit-transform: translateX(0) rotate(0deg) skew(0deg,0deg);
transform: translateX(0) rotate(0deg) skew(0deg,0deg);
}
100% {
-webkit-transform: translateX(8px) rotate(10deg) skew(5deg,10deg);
transform: translateX(8px) rotate(10deg) skew(5deg,10deg);
}
}
@keyframes salix-floating{
0% {
-webkit-transform: translateX(0) rotate(0deg) skew(0deg,0deg);
transform: translateX(0) rotate(0deg) skew(0deg,0deg);
}
100% {
-webkit-transform: translateX(8px) rotate(10deg) skew(5deg,10deg);
transform: translateX(8px) rotate(10deg) skew(5deg,10deg);
}
}
@keyframes salixshow-1{
0% {
transform:translate3d(50px,-25px,0) skew(44deg,29deg);
}
10% {
transform:translate3d(0,0,0) skew(44deg,29deg);
}
25% {
transform: translateZ(0) skew(0deg,0deg);
}
50% {
transform: translateZ(0) skew(0deg,0deg);
}
75% {
transform: translateZ(0) skew(0deg,0deg);
}
100% {
transform: translateZ(0) skew(0deg,0deg);
}
}
@keyframes salixshow-2{
0% {
transform:translate3d(0,0,0) skew(44deg,40deg);
}
15% {
transform:translate3d(0,0,0) skew(44deg,40deg);
}
40% {
transform: translateZ(0) skew(0deg,0deg);
}
100% {
transform: translateZ(0) skew(0deg,0deg);
}
}
@keyframes salixshow-3{
0% {
transform:translate3d(0,0,0) skew(24deg,63deg);
}
30% {
transform:translate3d(0,0,0) skew(24deg,63deg);
}
55% {
transform: translateZ(0) skew(0deg,0deg);
}
100% {
transform: translateZ(0) skew(0deg,0deg);
}
}
@keyframes salixshow-4{
0% {
transform:translate3d(0,0,0) skew(19deg,72deg);
}
45% {
transform:translate3d(0,0,0) skew(19deg,72deg);
}
60% {
transform: translateZ(0) skew(0deg,0deg);
}
100% {
transform: translateZ(0) skew(0deg,0deg);
}
}
/* 20019-09-11 鏂板 tab 鍒囨崲浜や簰 */
.gtoa-header{
box-sizing: border-box;
}
.gtoa-login-status{
padding-top: 12px;
width: 150px;
border-left: 1px solid #ddd;
}
.gtoa-logo{
padding-right: 54px;;
border-right: none;
}
.gtoa-top-tab{
float: left;
padding-top:15px;
}
.gtoa-top-tab li{
float: left;
/*width: 160px;*/
width: 136px;
height: 68px;
line-height: 68px;
text-align: center;
border-radius: 10px 10px 0 0;
}
.gtoa-top-tab li a{
display: block;
width: 100%;
height: 100%;
color: #333333;
font-size: 16px;
font-weight: bold;
}
.gtoa-top-tab li.on{
position: relative;
}
.gtoa-top-tab li.on em{
position: absolute;
bottom: 0;
width: 8px;
height: 8px;
display: block;
}
.gtoa-top-tab li.on em:before{
content: '';
display: block;
position: absolute;
left: 0;
bottom: 0;
width: 100%;
height: 100%;
background-color: #fff;
}
.gtoa-top-tab li .header-bottom-line{
position: fixed;
left: 0;
top:83px;
width:100%;
height:7px;
display: none;
}
.gtoa-top-tab li.on em.left-radius{
left: -8px;
}
.gtoa-top-tab li.on em.left-radius:before{
border-radius:0 0 10px 0;
}
.gtoa-top-tab li.on em.right-radius{
right: -8px;
}
.gtoa-top-tab li.on em.right-radius:before{
border-radius:0 0 0 10px;
}
.gtoa-top-tab li.on a{
color: #fff;
}
.gtoa-top-tab li.on .header-bottom-line{
display: block;
}
/*.top-tab-1.on{
background-color: #5ca2f8;
}
.top-tab-1.on em,.top-tab-1.on .header-bottom-line{
background-color: #5ca2f8;
}*/
.top-tab-oa.on{
background-color: #3366cc;
}
.top-tab-oa.on em,.top-tab-oa.on .header-bottom-line{
background-color: #3366cc;
}
.top-tab-tz.on, .top-tab-medicine.on{
background-color: #484faa;
}
.top-tab-tz.on em,.top-tab-tz.on .header-bottom-line, .top-tab-medicine.on em,.top-tab-medicine.on .header-bottom-line{
background-color: #484faa;
}
.top-tab-law.on, .top-tab-supervise.on,.top-tab-bf.on,.top-tab-actsupervise.on{
background-color: #164ca4;
}
.top-tab-law.on em,.top-tab-law.on .header-bottom-line, .top-tab-supervise.on em,.top-tab-supervise.on .header-bottom-line,.top-tab-bf.on em,.top-tab-bf.on .header-bottom-line, .top-tab-actsupervise.on em,.top-tab-actsupervise.on .header-bottom-line{
background-color: #164ca4;
}
.top-tab-4.on,.top-tab-4.on .header-bottom-line{
background-color: #2eaf9d;
}
.top-tab-4.on em{
background-color: #2eaf9d;
}
/*
.gtoa-left-menu.top-tab-style-1{
background-color: #5ca2f8;
}
.top-tab-style-1 li{
border-left-color: #5ca2f8;
}
.top-tab-style-1 li.on,.top-tab-style-1 li:hover{
border-left-color:#9dc6fa;
}
.top-tab-style-1 li.on span,.top-tab-style-1 li:hover span,.top-tab-style-1 li.on i, .top-tab-style-1 li:hover i{
color: #5ca2f8;
}
.gtoa-left-menu.top-tab-style-2{
background-color: #484faa;
}
.top-tab-style-2 li{
border-left-color: #484faa;
}
.top-tab-style-2 li.on,.top-tab-style-2 li:hover{
border-left-color:#a0a4ed;
}
.top-tab-style-2 li.on span,.top-tab-style-2 li:hover span,.top-tab-style-2 li.on i, .top-tab-style-2 li:hover i{
color: #484faa;
}
.gtoa-left-menu.top-tab-style-3{
background-color: #164ca4
}
.top-tab-style-3 li{
border-left-color: #164ca4;
}
.top-tab-style-3 li.on,.top-tab-style-3 li:hover{
border-left-color:#9dc6fa;
}
.top-tab-style-3 li.on span,.top-tab-style-3 li:hover span,.top-tab-style-3 li.on i, .top-tab-style-3 li:hover i{
color: #164ca4;
}
.gtoa-left-menu.top-tab-style-4{
background-color: #2eaf9d;
}
.top-tab-style-4 li{
border-left-color: #2eaf9d;
}
.top-tab-style-4 li.on,.top-tab-style-4 li:hover{
border-left-color:#a9fcf2;
}
.top-tab-style-4 li.on span,.top-tab-style-4 li:hover span,.top-tab-style-4 li.on i, .top-tab-style-4 li:hover i{
color: #2eaf9d;
}
.top-tab-style-1 .gtoa-submenu dd:hover i{
background-color: #5ca2f8;
border-color: #5ca2f8;
}
.top-tab-style-2 .gtoa-submenu dd:hover i{
background-color: #484faa;
border-color: #484faa;
}
.top-tab-style-3 .gtoa-submenu dd:hover i{
background-color: #164ca4;
border-color: #164ca4;
}
.top-tab-style-4 .gtoa-submenu dd:hover i{
background-color: #2eaf9d;
border-color: #2eaf9d;
}*/
.salix-animate{
position: fixed;
right: 0;
top:0;
width: 150px;
height:260px;
z-index: 100;
transform-origin: right top;
animation: salixmove 0.5s ease 1;
/* pointer-events: none; */
}
.salix-animate.to-hide{
transform-origin: right top;
animation: salixhide 1s ease 1;
animation-fill-mode: both;
}
.salix{
position: absolute;
right: 0;
top:0;
transform-origin: right top;
}
.salix-1{
transform-origin: 168px top;
animation: salixshow-1 13s linear 1,salix-floating 10s ease 13s infinite alternate;
}
.salix-2{
transform-origin: 170px top;
animation: salixshow-2 13s linear 1,salix-floating 10.5s ease 13s infinite alternate;;
}
.salix-3{
transform-origin: 180px top;
animation: salixshow-3 13s linear 1,salix-floating 10s ease 13s infinite alternate;
}
.salix-4{
transform-origin: right top;
animation: salixshow-4 13s linear 1,salix-floating 10.5s ease 13s infinite alternate;
}
/* 鍔ㄧ敾 */
@-webkit-keyframes salixmove{
from {
transform:translate3d(100px,-100px,0) scale(0) skew(5deg,0deg);
}
to {
transform:translate3d(0,0,0) scale(1) skew(5deg,0deg);
}
}
@keyframes salixmove{
from {
transform:translate3d(100px,-100px,0) scale(0) skew(5deg,0deg);
}
to {
transform:translate3d(0,0,0) scale(1) skew(5deg,0deg);
}
}
@-webkit-keyframes salixhide{
from {
transform:scale(1);
}
to {
transform:scale(0.1);
}
}
@keyframes salixhide{
from {
transform:scale(1);
}
to {
transform:scale(0.1);
}
}
@-webkit-keyframes salix-floating{
0% {
-webkit-transform: translateX(0) rotate(0deg) skew(0deg,0deg);
transform: translateX(0) rotate(0deg) skew(0deg,0deg);
}
100% {
-webkit-transform: translateX(8px) rotate(10deg) skew(5deg,10deg);
transform: translateX(8px) rotate(10deg) skew(5deg,10deg);
}
}
@keyframes salix-floating{
0% {
-webkit-transform: translate3d(0,0,0) rotate(0deg) skew(0deg,0deg);
transform: translate3d(0,0,0) rotate(0deg) skew(0deg,0deg);
}
50% {
-webkit-transform: translate3d(5px,0,0) rotate(-5deg) skew(-3deg,-6deg);
transform:translate3d(5px,0,0) rotate(-5deg) skew(-3deg,-6deg);
}
100% {
-webkit-transform: translate3d(5px,0,0) rotate(5deg) skew(3deg,6deg);
transform: translate3d(5px,0,0) rotate(5deg) skew(3deg,6deg);
}
}
@keyframes salixshow-1{
0% {
transform:translate3d(20px,0,0) rotate(-80deg) ;
}
99% {
transform: translate3d(0,0,0) rotate(0deg);
}
100% {
transform: translate3d(0,0,0) rotate(0deg);
}
}
@keyframes salixshow-2{
0% {
transform:translate3d(20px,0,0) rotate(-90deg) ;
}
94% {
transform: translate3d(0,0,0) rotate(0deg);
}
100% {
transform: translate3d(0,0,0) rotate(0deg);
}
}
@keyframes salixshow-3{
0% {
transform:translate3d(10px,0,0) rotate(-40deg) ;
}
98% {
transform: translate3d(0,0,0) rotate(0deg);
}
100% {
transform: translate3d(0,0,0) rotate(0deg);
}
}
@keyframes salixshow-4{
0% {
transform:rotate(-30deg) translateZ(0);
}
98% {
transform: rotate(0deg) translateZ(0);
}
100% {
transform:rotate(0deg) translateZ(0);
}
}
@keyframes salixshow-new-1{
0% {
transform: scale(0.1) translate3d(10px,-5px,0) skew(50deg,45deg);
}
30% {
transform: scale(0.5) translate3d(0,0,0) skew(30deg,31deg);
}
80% {
transform: translateZ(0) skew(0deg,0deg);
}
90% {
transform: scale(1) translateZ(0) skew(0deg,0deg);
}
100% {
transform:scale(1) translateZ(0) skew(0deg,0deg);
}
}
@keyframes salixshow-new-2{
0% {
transform: scale(0.1) translate3d(120px,-80px,0) skew(10deg,45deg);
}
40% {
transform:scale(0.3) skew(10deg,45deg);
}
60% {
transform:scale(0.6) translate3d(0,0,0) skew(5deg,29deg) ;
}
80% {
transform: translate3d(0,0,0) skew(0deg,0deg) ;
}
90% {
transform:scale(1) translate3d(0,0,0) skew(0deg,0deg) ;
}
100% {
transform: scale(1) translateZ(0) skew(0deg,0deg);
}
}
@media screen and (max-width: 1366px){
.gtoa-logo{
padding-right: 80px;
}
.gtoa-top-tab{
padding-top: 10px;
}
.gtoa-top-tab li{
width: 120px;
height: 55px;
line-height: 55px;
}
.gtoa-top-tab li a{
font-size: 14px;
}
.gtoa-top-tab li .header-bottom-line{
top:65px;
height: 5px;
}
}
/* 20019-09-11 鏂板 tab 鍒囨崲浜や簰 --end */
.gtoa-setting-box{
border-left: 1px solid #ddd;
float:right;
width: auto;
margin-right:50px;
}
.gtoa-exit-btn{
margin-right: 0;
}
@media screen and (max-width: 1366px){
.gtoa-setting-box{
width: auto;
padding-top: 9px;
}
}
.gtoa-left-menu.menu-slide-left li dd span{
display: block;
}
.gtoa-submenu dd a{
width:100%;
}
@media screen and (max-width: 1280px){
.gtoa-top-tab li{
width: 120px;
}
}
/* 2019-09-16 --end */
/* 2019-09-23 --start */
.top-tab-tz.on{
background-color:#164ca4;
}
.top-tab-tz.on em, .top-tab-tz.on .header-bottom-line{
background-color:#164ca4;
}
.top-tab-law.on{
background-color:#484faa;
}
.top-tab-law.on em, .top-tab-law.on .header-bottom-line{
background-color:#484faa;
}
.gtoa-menu-list li i{
float:left;
margin-top:4px;
margin-right:6px;
}
.gtoa-menu-list li{
padding-left:10px;
}
.gtoa-menu-list li .gtoa-submenu i{
margin-top:8px;
}
@media screen and (max-width: 1366px){
.gtoa-submenu{
padding-left:10px;
}
.gtoa-menu-list li{
padding-left:15px;
}
.gtoa-menu-list li .gtoa-submenu i{
margin-top:7px;
}
}
/* 2019-09-23 --end */
/* 2019-09-26 --start*/
.gtoa-setting-box {
margin-right: 13px;
}
@media screen and (max-width: 1366px){
.gtoa-logo {
/*padding-right: 40px;*/
padding-right: 20px;
}
}
/* 2019-09-26 --end*/
/* 2019-10-11 白色主题 default-white.css 合并 --start */
.default-white .gtoa-top-tab li{
height: 75px;
}
.default-white .top-tab-oa.on{
background-color: #fff;
}
.default-white .top-tab-tz.on{
background-color: #fff;
}
.default-white .top-tab-law.on{
background-color: #fff;
}
.default-white .gtoa-top-tab li a{
font-size: 18px;
color: #999;
font-weight: normal;
}
.default-white .gtoa-top-tab li.on a{
color: #333;
font-weight: bold;
}
.default-white .gtoa-top-tab li.on em{
display: none;
}
.default-white .gtoa-top-tab li .header-bottom-line{
position: absolute;
top:auto;
bottom: 0;
left: 0;
width: 100%;
height: 5px;
background-color: #3366cc;
border-radius: 3px 3px 0 0;
}
.default-white .top-tab-tz.on .header-bottom-line{
background-color: #3366cc;
}
.default-white .gtoa-left-menu{
background-color: #eaeffa;
}
.default-white .gtoa-menu-list li i{
color: #a0a0a0;
}
.default-white .gtoa-menu-list li span{
color: #333;
}
.default-white .gtoa-menu-list li{
border-left: 5px solid #fff;
}
.default-white .gtoa-menu-list li.on,.default-white .gtoa-menu-list li:hover{
background-color: #fff;
border-left: 5px solid #3366cc;
}
.default-white .gtoa-menu-list li.on i,.default-white .gtoa-menu-list li:hover i{
color:#3366cc;
}
.default-white .gtoa-submenu dd:hover i{
background-color: #3366cc;
border-color: #3366cc;
}
.default-white .gtoa-menu-list li.on span,.default-white .gtoa-menu-list li:hover span{
color: #3366cc;
}
@media screen and (max-width: 1366px){
.default-white .gtoa-top-tab li{
height: 60px;
}
.default-white .gtoa-top-tab li a{
font-size: 16px;
}
.default-white .gtoa-top-tab li .header-bottom-line{
height: 4px;
}
}
.salix-close {
display: none;
position: fixed;
right: 0;
top: 0;
z-index: 1000;
padding: 8px 10px 4px;
}
.salix-close i {
font-size: 36px;
color: #ee583a;
cursor: pointer;
}
/* 2019-10-11 白色主题 default-white.css 合并 --end */
@media screen and (max-width: 1534px) {
.changelog {
display: none;
}
}
@media screen and (max-width: 1366px) {
.changelog {
display: block;
}
}
@media screen and (max-width: 1171px) {
.changelog {
display: block;
}
}
.gtoa-old-version-btn ul {
position: absolute;
top: 58px;
right: -70px;
left: -15px;
border: 1px solid #eef1f5;
margin-top: 0;
padding: 8px 5px 10px 10px;
width: 72px;
overflow-y: auto;
background-color: #fff;
display: none;
box-shadow: 0 0 30px rgba(0,0,0,.1);
}
.gtoa-old-version-btn ul li {
padding: 10px 0;
border-bottom: 1px solid #ddd;
}
.gtoa-old-version-btn ul li:last-child {
border-bottom: none;
}
.gtoa-old-version-btn ul li a {
display: block;
}
@media screen and (min-width: 1280px) {
.gtoa-old-version-btn ul {
left: -19px;
width: 103px;
}
}
@media screen and (min-width: 1366px) {
.gtoa-old-version-btn ul {
top: 65px;
left: -20px;
width: 76px;
}
}
/* 2019-10-25 白色主题下 2560*1440 分辨率下 首页调整 --start */
/* 通过 媒体查询 min-height:1080px ,max-height:1440px;max-width:2560px,min-width:1921px; */
@media screen and (max-height:1440px) and (min-height:990px) and (max-width:2560px) and (min-width:1921px){
.gtoa-header{
height: 120px;
}
.gtoa-logo{
padding-top: 20px;
padding-right: 80px;
}
.gtoa-logo img{
height: 40px;
}
.gtoa-logo h1{
font-size: 24px;
line-height: 35px;
}
.gtoa-top-tab{
padding-top: 35px;
}
.gtoa-top-tab li{
height: 79px;
line-height: 79px;
width: 220px;
}
.gtoa-top-tab li a{
font-size: 24px;
}
.gtoa-top-tab li .header-bottom-line{
top:113px;
}
.gtoa-menu-list li{
padding-top: 25px;
padding-bottom: 25px;
padding-left: 15px;
}
.gtoa-setting-box{
padding-top: 30px;
height: 83px;
}
.gtoa-setting-box .fa{
font-size: 35px;
margin-bottom: 5px;
}
.gtoa-exit-btn span, .gtoa-setting-btn span, .gtoa-old-version-btn span{
font-size: 18px;
}
.gtoa-login-status{
height: 101px;
width: 180px;
}
.gtoa-login-position ul {
left: -20px;
width: 183px !important;
}
.gtoa-login-pic{
width: 56px;
height: 56px;
}
.gtoa-login-pic .fa{
font-size: 35px;
}
.gtoa-login-pic .usert{
right: -14px;
}
.gtoa-login-name{
padding-top: 18px;
font-size: 20px;
}
.gtoa-login-position{
padding-top: 18px;
}
.gtoa-login-position p{
font-size: 20px;
width: 150px;
}
.gtoa-login-position ul li{
font-size: 20px;
}
.gtoa-left-menu{
top: 120px;
height: calc(100vh - 120px);
width: 300px;
width: 240px;
}
.gtoa-menu-list li{
height: 30px;
}
.gtoa-menu-list li i{
font-size: 24px;
margin-top: 3px;
margin-right: 8px;
}
.gtoa-menu-list li span{
line-height: 30px;
font-size: 24px;
}
.gtoa-left-menu .gtoa-slide-btn{
bottom: 10px;
}
.gtoa-submenu{
top:120px;
left: 240px;
width: 280px;
}
.gtoa-submenu dd{
margin-bottom: 20px;
}
.gtoa-menu-list li .gtoa-submenu i{
margin-top: 10px;
width: 8px;
height: 8px;
}
.gtoa-container{
height: calc(100vh -120px);
margin-top: 120px;
margin-left: 240px;
}
}
/* 2019-10-25 白色主题下 2560*1440 分辨率下 首页调整 --end */
\ No newline at end of file
*{
margin:0;
padding:0;
}
body {
font-family: -apple-system,BlinkMacSystemFont,PingFang SC,Hiragino Sans GB,Microsoft YaHei,\\5FAE\8F6F\96C5\9ED1,helvetica neue,helvetica,ubuntu,roboto,noto,segoe ui,Arial,sans-serif;
background: #eef1f5;
}
ul,ol,li{
list-style: none;
}
a{
text-decoration: none;
}
img{
border: none;
}
.clearfix:after{
content: '';
height: 0;
display: block;
clear: both;
visibility: hidden;
overflow: hidden;
}
/* 设置滚动条的样式 */
::-webkit-scrollbar {
width:5px;
}
/* 滚动槽 */
::-webkit-scrollbar-track {
-webkit-box-shadow:inset 0 0 10px rgba(0,0,0,0.1);
box-shadow:inset 0 0 10px rgba(0,0,0,0.1);
border-radius:3px;
}
/* 滚动条滑块 */
::-webkit-scrollbar-thumb {
border-radius:10px;
background:rgba(0,0,0,0.1);
-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,0.2);
box-shadow:inset 0 0 6px rgba(0,0,0,0.2);
}
::-webkit-scrollbar-thumb:window-inactive {
background:rgba(220,220,220,.5);
}
\ No newline at end of file
#manageContent {
width: 100%;
}
.col-sm-2 {
display: none;
position: relative;
min-height: 1px;
padding-right: 2px;
padding-left: 0px;
}
.header1280 {
display:none;
padding: 0;
padding-bottom: 10px;
min-height: 127px;
background: #fff;
}
@import './common/reset.css';
a:hover,a:active,a:link{text-decoration: none;}
.gt-body{overflow-x:hidden;padding:15px;background-color: #F3F6F8;}
.gt-waitdo{margin-bottom:46px;}
.gt-row{min-width:850px;}
.gt-i-box{}
.gt-i-title{height:51px;padding:2px 26px;}
.gt-i-title h3{margin:0px;line-height:51px;font-size:18px;float:left;font-weight: bold;}
.gt-i-title h3 .fa{margin-right:10px;}
.gt-i-title .gt-i-btn{margin:0px;line-height:51px;font-size:18px;float:right}
.gt-i-title .gt-i-btn a{color:#fff;font-size:14px;margin-left:10px;}
.gt-i-title .gt-i-btn a .fa{margin-right:5px;}
.gt-i-title.do{background-color:#6b76fa;color:#fff;overflow: hidden;}
.gt-i-title.read{background-color:#3973f6;color:#fff;}
.gt-i-title.meet{background-color:#22cae1;color:#fff;}
.gt-i-title.draft{color:#333;background-color:#DBE6F5;border-radius: 20px 20px 0px 0px;}
.gt-i-title.draft a{color:#8a8a8a;}
.gt-swtich{float:left;position:relative;}
.gt-swtich .t-line{padding:0px 20px;font-weight:normal;}
.gt-swtich a {opacity: 0.5;font-weight:bold;line-height:50px;font-size:18px;position: relative;display: inline-block;z-index:5;color:#fff;box-sizing:border-box;text-align:center;float:left;}
.gt-swtich a .label {border-radius:15px;background-color:#fff;color:red;margin-left:10px;}
.gt-swtich .on{opacity:1}
.gt-matter{float:left;position:relative;}
.gt-matter .t-line{padding:0px 20px;font-weight:normal;}
.gt-matter a {opacity: 0.5;font-weight:bold;line-height:50px;font-size:18px;position: relative;display: inline-block;z-index:5;color:#fff;box-sizing:border-box;text-align:center;float:left;}
.gt-matter a .label {border-radius:15px;background-color:#fff;color:red;margin-left:10px;}
.gt-matter .on{opacity:1}
.gt-waitdo-group{padding-top:50px;position:relative;}
.gt-waitdo-item{cursor:pointer;}
.gt-waitdo-body{height:370px;}
.list-group{width:100%;margin-bottom:0px;}
.gt-list-type{height:46px;width: 49px;float: left;font-size:21px;display: inline-block;background-color: #7daff4;padding: 0 5px;border-radius: 9px 0 9px 0;color: #fff;line-height:46px;margin-right:20px;text-align: center;}
.gt-list-item:last-child{border-radius:0px;border-bottom: 0px;}
.gt-list-item{border:1px dotted #ddd;border-width:1px 0px 1px 0px;padding:10px 25px;cursor: pointer;}
.gt-list-body{display: contents;}
.gt-list-body h3{margin: 5px;margin-bottom: 8px;color:#555;font-weight: bold;font-size: 16px;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;}
.gt-list-body span{margin-right:10px;}
.gt-short-con{padding:15px 20px;}
.gt-short-item a{color:#e0e0e0;}
.gt-short-item a:hover .fa{color:#ccc;}
.gt-short-item .fa{font-size:51px;padding-bottom:54px;}
.gt-short-more{float:right;font-size:10px;cursor:pointer;background: #fff;}
.gt-list-item .flow-type{color:#dc4930;margin-right:10px;}
.gt-list-item .flow-date{font-weight: normal;}
.gt-draft-container{
padding:15px 20px;
}
.gt-draft li{font-size:14px;overflow: hidden;white-space: nowrap;text-overflow: ellipsis;float:left;width:42%;margin-right:10px;line-height:36px;cursor:pointer;}
.p50 li{width:30%;}
.gt-draft li:hover{font-weight:bold;}
.gt-draft li .fa{margin-right:5px;}
.gt-draft li:first{
margin-top:10px;
}
.gt-draft-item{
border:1px solid #ccc;
height:155px;
border-radius:15px 15px 15px 15px;
}
.gt-draft-item ul{margin:40px 0px 0px 15px;}
.gt-draft-title{
width:51%;float:left;height:30px;
}
.gt-draft-mark{
background:#F49C1C;
padding:5px 47px 5px 15px;
border-radius: 0px 15px 15px 0px;
margin-top: 0.5em;
content: "";
float: left;
font-weight: bold;
font-size:16px;
color:#fff;
left: -10px;
position: relative;
max-height:42px;
white-space: nowrap;
text-overflow: ellipsis;
}
.gt-draft-mark .fa{margin-left:10px;}
.m1{background-color:#FFEED5;border:1px solid #FFEED5;}
.m2{background-color:#FFE4D5;border:1px solid #FFE4D5;}
.m3{background-color:#FFE6F0;border:1px solid #FFE6F0;}
.m4{background-color:#EEE6FF;border:1px solid #EEE6FF;}
.m5{background-color:#E6EEFF;border:1px solid #E6EEFF;}
.m1 .gt-draft-conner{background:url('../img/icon-conner-01.gif') no-repeat right bottom;}
.m1 .gt-draft-conner:hover{background:url('../img/icon-conner-01-2.png') no-repeat right bottom;}
.m2 .gt-draft-conner{background:url('../img/icon-conner-02.gif') no-repeat right bottom;}
.m2 .gt-draft-conner:hover{background:url('../img/icon-conner-02-2.png') no-repeat right bottom;}
.m3 .gt-draft-conner{background:url('../img/icon-conner-03.gif') no-repeat right bottom;}
.m3 .gt-draft-conner:hover{background:url('../img/icon-conner-03-2.png') no-repeat right bottom;}
.m4 .gt-draft-conner{background:url('../img/icon-conner-04.gif') no-repeat right bottom;}
.m4 .gt-draft-conner:hover{background:url('../img/icon-conner-04-2.png') no-repeat right bottom;}
.m5 .gt-draft-conner{background:url('../img/icon-conner-05.gif') no-repeat right bottom;}
.m5 .gt-draft-conner:hover{background:url('../img/icon-conner-05-2.png') no-repeat right bottom;}
.t1{background-color:#F49C1C;}
.t2{background-color:#DC4930;}
.t3{background-color:#EA3D72;}
.t4{background-color:#B341E3;}
.t5{background-color:#EA3D72;}
.gt-draft-mark:before {
content: "";
position: absolute;
top:2em;
left:0px;
border-right:0.6em solid #CC6600;
border-bottom:0.6em solid #fff;
}
.gt-draft-conner{
position: absolute;
right: 14px;
bottom: 0px;
padding: 23px;
}
.gtoa-iframe-container {
padding: 30px 0 0 40px;
}
.gtoa-iframe-container a:hover {
text-decoration: none;
}
.gtoa-iframe-container a:focus {
text-decoration: none;
outline: none;
}
.gtoa-iframe-container p {
margin-bottom: 0;
}
.gtoa-main {
float: left;
width: auto;
width: 74%
}
.sc-row{margin:0px;height:350px;}
.sc-type{padding:0px;height:350px;background:#ecf1f7;box-shadow: -2px 0px 2px rgba(0, 0, 0, .1) inset;}
.sc-type .on{background: #54c11a;color: #fff;text-shadow: 0 1px 1px rgba(0, 0, 0, .42);}
.sc-items{margin:0px;padding:0px;}
.sc-items li{color:#eee}
.sc-items li > * {position: absolute;}
.sc-items li,.sc-items li img {width: 120px;height:130px;border-radius: 5px;}
.sc-items li {float: left;position: relative;overflow: hidden;margin:18px 0 0 20px;}
.sc-items li .fa{color:#00bf00;}
.sc-items li .fa-edit{color:#42A5F5;}
.sc-items li i{font-size: 21px;}
.sc-items li img{margin:8px 34px;height:60px;width:51px;}
.sc-items li img{
-webkit-filter: grayscale(100%);
-moz-filter: grayscale(100%);
-ms-filter: grayscale(100%);
-o-filter: grayscale(100%);
filter:progid:DXImageTransform.Microsoft.BasicImage(grayscale=1);
_filter:none;
}
.sc-items li.added img{
-webkit-filter: grayscale(0%);
-moz-filter: grayscale(0%);
-ms-filter: grayscale(0%);
-o-filter: grayscale(0%);
filter: grayscale(0%);
filter: gray;
}
.sc-items li span{margin:25px 42px;font-size:41px}
.sc-items li.added i{background:none;color:red;}
.sc-items li:hover h4{color:#000000;font-weight:bold;}
.sc-items li h4 {text-align:center;bottom:0px;opacity:1;width: 100%;font-weight: normal;color:#333333;height:31px;line-height:16px;-webkit-transition: bottom .2s, opacity .3s;}
/* .sc-items li.added i {width: 29px;height: 29px;left: 0;top: 0;background: url(../../img/selected.png);z-index: 1;} */
.sc-items li h5{cursor:pointer;text-align: center;bottom:18px;font-size: 14px;width: 100%;color:#333;height: 31px;}
.sc-items li h5:hover{color:#888}
.sc-items li.added{color:#269fff}
.sc-type ul{padding:0px;}
.sc-type li {height:31px; line-height:31px; font-size: 14px; font-weight: 400; text-align: center; color: #516572; cursor: pointer; position: relative;-webkit-transition:background .4s, color .4s;list-style:none;}
.sc-type li.on,.sc-type li:hover { box-shadow: 0 1px rgba(255, 255, 255, .46), inset -1px 1px 3px rgba(0, 0, 0, .2); /*-webkit-transition:background .2s, color .3s*/ }
.sc-type li:hover {color: #0f9206; }
.sc-type li:not(.on):hover::after { position: absolute; right: 0px; top: 0; height: 100%; width: 3px; content: ''; background: #54c11a; box-shadow: inset -1px 0 1px rgba(0, 0, 0, .1); }
.sc-type li.on { background: #54c11a; color: #fff; text-shadow: 0 1px 1px rgba(0, 0, 0, .42); }
.ul-selected{}
.gtoa-temp-main {
width: 100%;
margin-bottom: 30px;
}
.gtoa-temp-main:last-child {
margin-bottom: 10px;
}
/* .gt-waitdo ul {position: relative;padding-top: 50px;} */
.gt-waitdo > ul > li {height: 110px;margin-bottom: 10px;margin-left: 25px;padding-left: 0;width: 150px;border-radius: 15px;}
.gt-waitdo li.on {margin-left: 0;}
.gt-waitdo li p {position: relative;font-size: 20px;display: inline-block;line-height: 1;color: #fff;width: 50px;}
.gt-waitdo li p .fa {position:absolute;font-size:31px;right:34px;top:-43px;opacity: 0.5;}
.gt-waitdo li > p {user-select: none;cursor: pointer;margin-top:81px;margin-left:45px;font-weight: bold;}
.gt-waitdo li.on p {width: auto;margin-left: 60px;margin-top: 70px;}
.gt-waitdo .on em{right:55px!important;top:-66px!important;}
.gt-waitdo li p em {min-width: 41px;position: absolute;right:47px;top:-78px;border-radius:12px 0px 12px 0;display: block;background-color: #fff;font-style: normal;font-size: 12px;color: #d7001d;line-height: 20px;text-align: center;padding: 0 3px 0 0;}
.gt-waitdo li.gtoa-to-do {background-color:#6b76fa;}
.gt-waitdo li.gtoa-meeting {background-color:#22cae1;}
.gt-waitdo li.gtoa-to-read {background-color:#3973f6;}
.gtoa-document-floating {
position: absolute;
top: 0;
left: 120px;
display: none;
width: calc(100% - 120px);
border-radius: 20px;
box-sizing: border-box;
background-color: #fff;
overflow: hidden;
box-shadow: 0 0 30px rgba(0, 0, 0, .2);
}
.gt-waitdo li.on .gtoa-document-floating {
display: block
}
.document-floating-top {
height: 65px;
padding: 0 40px;
}
.gtoa-to-do .document-floating-top {
background-color: #6b76fa;
}
.gtoa-meeting .document-floating-top {
background-color: #22cae1;
}
.gtoa-to-read .document-floating-top {
background-color: #3973f6;
}
.gt-waitdo .gtoa-document-floating .document-floating-top p {
font-size: 18px;
line-height: 1;
margin-top: 25px;
}
.document-floating-top a {
/* float: right; */
/* font-size: 14px; */
/* color: #fff; */
/* padding-left: 25px; */
/* margin-top: 25px; */
/* background: url(../img/icon-refresh.png) no-repeat left center; */
}
.document-floating-main {
padding: 20px 5px 20px 40px;
height: 370px;
box-sizing: border-box;
overflow: hidden;
}
.document-floating-main ul {
height: 300px;
padding-top: 0;
overflow-y: auto;
padding-right: 10px;
}
.document-floating-main li {
height: auto;
margin-bottom: 20px;
}
.document-floating-tip {
float: left;
font-size: 12px;
display: inline-block;
height: 18px;
background-color: #7daff4;
padding: 0 5px;
border-radius: 9px 0 9px 0;
color: #fff;
line-height: 16px;
margin-top: 5px;
}
.document-floating-main li a {
display: block;
color: #333;
line-height: 20px;
padding-left: 40px;
line-height: 1.4;
margin-bottom: 5px;
font-size: 16px;
}
.document-floating-main li a img {
vertical-align: middle;
margin-left: 5px;
/*height:12px;*/
}
.gt-waitdo .document-floating-main li p {
margin-top: 0;
color: #89939c;
font-size: 12px;
margin-left: 40px;
display: block;
}
.gtoa-document-floating-more {
display: inline-block;
margin-left: 40px;
color: #89939c;
margin-top: 15px;
padding-right: 10px;
font-size: 14px;
line-height: 1;
background: url(../img/icon-forward.png) no-repeat right center;
}
.gtoa-done {
float: left;
width: 35%;
background-color: #fff;
border-radius: 20px;
box-shadow: 0 0 30px rgba(0, 0, 0, .2);
}
.gtoa-title {
height: 50px;
padding: 10px 30px 0 30px;
box-sizing: content-box;
border-bottom:2px solid #6b76fa;
border-radius: 20px 20px 0 0;
}
.gtoa-title h2 {
font-size: 20px;
color: #333;
line-height: 50px;
display: inline-block;
padding-left: 25px;
margin: 0;
}
.gtoa-done .gtoa-title h2 {
background: url(../img/icon-title-03.png) no-repeat left center;
}
.gtoa-title a {
float: right;
margin-top: 15px;
margin-right: 10px;
font-size: 14px;
color: #89939c;
}
.gtoa-done-container {
border-radius: 20px;
overflow: hidden;
}
.gtoa-done-top {
/* background-color: #5ca2f8; */
height: 50px;
padding: 0.1px 30px 0 30px;
}
.gtoa-done-top span {
float: right;
font-size: 14px;
margin-top: 26px;
color: #fff;
line-height: 1.4;
}
.gtoa-done-context {
background-color: #fff;
padding: 10px 10px 30px 30px;
height: 325px;
box-sizing: border-box;
}
.gtoa-done-context ul {
height: 100%;
overflow-y: auto;
padding-right: 10px;
}
.gtoa-done-context ul li {
margin-bottom: 20px;
}
.gtoa-done-context ul li p {
line-height: 1;
font-size: 14px;
color: #89939c;
margin-bottom: 5px;
}
.gtoa-done-context ul li p span {
color: #d7001d;
}
.gtoa-done-context ul li a {
line-height: 1.4;
color: #333;
font-size: 16px;
}
.gtoa-draft {
/* margin-right: 35px; */
background: #fff;
border-radius: 20px;
box-shadow: 0 0 30px rgba(0, 0, 0, .2);
}
.gtoa-draft .gtoa-title h2 {
background: url(../img/icon-title-01.png) no-repeat left center;
}
.gtoa-draft-container {
position: relative;
width: 100%;
/*overflow: hidden;*/
}
.gtoa-draf-lists {
width: 100%;
box-sizing: border-box;
padding: 15px 40px 0 40px;
/* border-radius: 20px;
background:#fff;
box-shadow: 0 0 30px rgba(0,0,0,.2); */
}
.gtoa-temp-draf {
float: left;
position: relative;
min-width: 25%;
border: 2px dashed #d4e4fb;
margin-bottom: 30px;
border-radius: 15px;
padding: 20px 0 12px 0;
width: 31%;
margin-right: 3%;
box-sizing: border-box;
transition: all .5s linear;
min-height: 120px;
}
.gtoa-temp-draf:after {
content: '';
clear: both;
height: 0;
display: block;
visibility: hidden;
overflow: hidden;
}
.gtoa-temp-draf:nth-child(1) {
min-width: 60%;
}
.gtoa-temp-draf:nth-child(2) {
min-width: 37%;
margin-right: 0;
}
.gtoa-temp-draf:nth-child(3) {
/*flex-grow: 1;*/
width: 100%;
margin-right: 0;
}
.gtoa-draft-type {
position: absolute;
width:92%;
top: -8px;
left: 20px;
padding: 0 5px;
line-height: 1;
}
.gtoa-draft-type a {
font-size: 16px;
color: #5ca2f8;
background: #fff;
}
.gtoa-temp-draf ul {
float: left;
padding: 0 0 0 0;
margin-right: 0;
}
.gtoa-temp-draf ul + ul {
margin-right: 0;
}
.gtoa-temp-draf ul li {
padding-left: 23px;
/* background: url(../img/icon-arrow.png) no-repeat 10px center; */
list-style: inside;
margin-bottom: 5px;
height: 20px;
line-height: 20px;
}
.gtoa-temp-draf ul li a {
color: #333;
font-size: 14px;
white-space: nowrap;
}
/* 右侧栏 */
.gtoa-sidebar {
float: left;
width: 20%;
}
.gtoa-read {
margin-bottom: 20px;
background-color: #fff;
border-radius: 20px;
box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
}
.gtoa-read-list {
background-color: #fff;
border-radius: 0 0 20px 20px;
padding-bottom: 10px;
cursor:pointer;
}
.gtoa-read-list ul {
width:100%;
padding:10px;
margin: 0 auto;
cursor:pointer;
}
.gtoa-quick {
margin-bottom: 20px;
background-color: #fff;
border-radius: 20px;
box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
}
.gtoa-quick {
margin-bottom: 20px;
background-color: #fff;
border-radius: 20px;
box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
}
.gtoa-quick .gtoa-title {
padding-top: 0;
padding-bottom: 0;
}
.gtoa-quick .gtoa-title h2 {
background: url(../img/icon-title-02.png) no-repeat left center;
}
.gtoa-quick-list {
background-color: #fff;
border-radius: 0 0 20px 20px;
padding-bottom: 10px;
}
.gtoa-quick-list ul {
width:100%;
padding:10px;
margin: 0 auto;
}
.gtoa-quick-list li {
float: left;
width: 33.3%;
margin-right: 0%;
margin-bottom: 0%;
background: #fff;
text-align: center;
box-sizing: border-box;
border-right:1px dashed #d7dde3;
border-top:1px dashed #d7dde3;
}
.gtoa-quick-list li:first-child{
border-top:0px dashed #d7dde3;
}
.gtoa-quick-list li:nth-child(3n) {
border-right: 0;
}
.gtoa-quick-list li a {
display: block;
width: 100%;
height: 100%;
padding:0px 0 10px 0;
}
.gtoa-quick-list li:nth-child(1),
.gtoa-quick-list li:nth-child(2),
.gtoa-quick-list li:nth-child(3) {
border-top:0px dashed #d7dde3;
}
.gtoa-quick-list li img {
display: block;
margin: 0 auto;
height:56px;
width:56px;
}
.gtoa-quick-list li span {
font-size: 14px;
color: #333;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.gtoa-filing-cabinet {
margin-bottom: 20px;
background-color: #fff;
border-radius: 20px;
box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
}
.gtoa-filing-cabinet .gtoa-title h2 {
background: url(../img/icon-title-04.png) no-repeat left center;
}
.gtoa-filing-cabinet-contanier {
/* background: #fff; */
padding: 5px 30px 1px 30px;
/* border-radius: 20px;
box-shadow: 0 0 30px rgba(0,0,0,0.1); */
}
.gtoa-filing-cabinet-contanier li {
border-bottom: 2px dashed #d4e4fb;
margin-bottom: 8px;
padding-bottom: 8px;
text-align: left;
}
.gtoa-filing-cabinet-contanier li:last-child {
border-bottom: 0;
}
.gtoa-filing-cabinet-contanier li a {
font-size: 16px;
color: #333;
line-height: 1.4;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
margin-bottom: 8px;
}
.gtoa-filing-cabinet-contanier li p {
padding-left: 20px;
background: url(../img/icon-time.png) no-repeat left center;
font-size: 14px;
color: #89939c;
margin-bottom: 0px;
line-height: 1;
}
.gtoa-deal-race {
position: relative;
border-radius: 20px;
background-color: #fff;
padding: 30px 30px 30px 30px;
box-shadow: 7px 10px 20px rgba(0, 0, 0, 0.1);
}
.gtoa-deal-race h3 {
font-size: 16px;
margin-bottom: 20px;
margin-top: 0;
font-weight: bold;
}
.gtoa-deal-race p {
font-size: 14px;
color: #89939c;
line-height: 1.5;
margin-bottom: 5px;
}
.gtoa-deal-race p b {
font-size: 18px;
color: #5ca2f8;
padding-right: 5px;
}
.race-echart-box {
position: absolute;
top: 75px;
left: 125px;
width: 90px;
height: 90px;
}
.gtoa-schedule {
float: left;
width: 35%;
border-radius: 20px;
background: #fff;
box-shadow: 0 0 30px rgba(0, 0, 0, .2);
}
.gtoa-schedule .gtoa-title {
padding-bottom: 0;
}
.gtoa-schedule .gtoa-title h2 {
background: url(../img/icon-title-05.png) no-repeat left center;
}
.gtoa-schedule-container {
position: relative;
background-color: #fff;
border-radius: 20px;
}
.gtoa-deal-text {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
line-height: 90px;
font-size: 24px;
color: #333;
text-align: center;
font-weight: bold;
}
.gtoa-plan-box {
position: absolute;
left: 50%;
bottom: 40px;
width: 300px;
box-sizing: border-box;
margin-left: -150px;
display: none;
}
.gtoa-plan-container {
background-color: #fff;
padding: 20px 30px 0 30px;
border-top: 3px solid #7daff4;
border-right: 3px solid #7daff4;
border-left: 3px solid #7daff4;
border-radius: 15px 15px 0 0;
}
.gtoa-plan-top {
font-size: 18px;
border-bottom: 2px dashed #7daff4;
padding-bottom: 10px;
margin-bottom: 10px;
}
.gtoa-plan-top p {
display: inline-block;
line-height: 1;
}
.gtoa-plan-top a {
float: right;
display: inline-block;
width: 18px;
height: 18px;
background: url(../img/icon-close.png) no-repeat center;
text-indent: -99999px;
margin-right: 10px;
}
.gtoa-plan-list {
height: 190px;
overflow-y: auto;
}
.gtoa-plan-list li {
margin-bottom: 10px;
font-size: 14px;
}
.gtoa-plan-list li input {
border: 0;
padding: 0;
background: transparent;
display: block;
height: 24px;
line-height: 24px;
}
.gtoa-plan-list .plan-time {
color: #5ca2f8;
}
.gtoa-plan-list .plan-text {
color: #333;
padding-left: 15px;
}
.gtoa-plan-list .plan-text:disabled {
background: url(../img/icon-dot.png) no-repeat left center;
}
.gtoa-plan-btns {
width: 100%;
background-color: #5ca2f8;
border-radius: 0 0 15px 15px;
height: 50px;
line-height: 50px;
}
.gtoa-plan-btns a {
float: left;
color: #fff;
font-size: 18px;
display: block;
width: 50%;
text-align: center;
}
.gtoa-plan-btns a.to-save {
display: none;
}
.gtoa-plan-btns a.to-delete {
background-color: rgba(255, 255, 255, .3)
}
circle {
-webkit-transition: stroke-dasharray .6s;
transition: stroke-dasharray .6s;
}
.race-echart-box circle {
-webkit-transition: stroke-dasharray .6s;
transition: stroke-dasharray .6s;
}
/* 起草查看更多 */
.gtoa-all-draf {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
padding: 30px 30px 30px 30px;
box-sizing: border-box;
background-color: #fff;
border-radius: 0 0 20px 20px;
box-shadow: 0 0 30px rgba(0, 0, 0, .2);
display: none;
}
.gtoa-temp-all-draf {
display: none;
}
.temp-all-draf-title {
padding-bottom: 20px;
border-bottom: 2px dashed #5ca2f8;
margin-bottom: 20px;
}
.temp-all-draf-title h3 {
font-size: 16px;
color: #5ca2f8;
line-height: 16px;
display: inline-block;
margin: 0;
font-weight: bold;
}
.temp-all-draf-title .back-btn {
float: right;
font-size: 14px;
color: #89939c;
display: inline-block;
padding-left: 15px;
background: url(../img/icon-back.png) no-repeat left center;
height: 16px;
line-height: 16px;
}
.temp-all-draf-list {
height: auto;
overflow-x: hidden;
overflow-y: auto;
max-height: 200px;
}
.temp-all-draf-list ul {
width: 102.41%;
padding-bottom: 30px;
}
.temp-all-draf-list li {
float: left;
width: 23%;
padding-left: 20px;
margin-right: 2%;
background: url(../img/icon-arrow.png) no-repeat 5px center;
font-size: 14px;
line-height: 1.5;
margin-bottom: 7px;
box-sizing: border-box;
}
.temp-all-draf-list li a {
color: #333;
}
.gtoa-draf-float {
position: absolute;
bottom: 60px;
left: 200px;
width: 600px;
background-color: #fff;
border: 3px solid #9dc7fb;
border-radius: 20px;
padding: 20px 30px 20px 30px;
z-index: 100;
box-sizing: border-box;
box-shadow: 0 0 30px rgba(0, 0, 0, .2);
display: none;
}
.draf-float-top {
border-bottom: 2px dashed #d4e4fb;
padding-bottom: 15px;
margin-bottom: 20px;
}
.draf-float-top h3 {
font-size: 18px;
color: #333;
font-weight: bold;
line-height: 18px;
display: inline-block;
margin-top: 0;
margin-bottom: 0;
}
.draf-float-top .draf-float-close {
float: right;
display: block;
width: 20px;
height: 20px;
background: url(../img/icon-close.png) no-repeat center;
}
.draf-float-list {
height: 250px;
overflow-y: auto;
}
.draf-float-list li {
padding-left: 20px;
margin-bottom: 5px;
}
.draf-float-list li:before {
float: left;
content: '';
display: block;
height: 8px;
width: 8px;
border-radius: 50%;
border: 2px solid #5d8cf8;
margin-left: -20px;
margin-top: 2px;
}
.draf-float-list li:after {
content: '';
clear: both;
display: block;
height: 0;
visibility: hidden;
}
.draf-float-list h4 {
font-size: 16px;
line-height: 1;
margin-bottom: 10px;
color: #333;
}
.draf-float-list li a {
float: left;
display: inline-block;
width: 30%;
margin-right: 2%;
height: 24px;
line-height: 24px;
text-align: center;
border: 1px solid #e5e5e5;
color: #89939c;
font-size: 14px;
margin-bottom: 15px;
}
/* 20190805 draft-layer */
.draft-layer{
position: absolute;
background-color: transparent;
box-shadow: none;
}
.draft-layer .layui-layer-shade{
opacity: 0 !important;
}
.draft-layer .gt-draft li{
width:130px;
display: block !important;
margin-right: 20px;
}
.draft-layer .gt-draft-item{
height: 100%;
border-radius: 15px 15px 59px 15px;
}
.draft-layer .gt-draft-conner{
display: none;
pointer-events: none
}
.gt-list-type{
border-radius: 50%;
}
.list-group .list-group-item:first-child{
border-top:0;
}
.gt-draft li:hover{
color: #5ca2f8;
}
.gt-draft li:hover .fa{
color: #5ca2f8;
}
.draft-layer.layui-layer-page .layui-layer-content{
overflow: visible;
}
.draft-layer .layui-layer-setwin{
top:auto;
bottom: 0;
height: 45px;
width: 45px;
right: 0;
}
.draft-layer .gt-draft-mark:before{
border-bottom: 0.6em solid transparent;
}
.draft-layer .layui-layer-close2{
}
.draft-layer .gt-draft-item{
box-shadow: 0 0 30px rgba(0,0,0,0.2);
}
.draft-layer .layui-layer-setwin .layui-layer-close2{
width: 100%;
height: 100%;
top:auto;
bottom: 3px;
right:0px;
}
.draft-layer-1 .layui-layer-setwin .layui-layer-close2{
background:url(../img/icon-conner-s-01.png) no-repeat center center;
}
.draft-layer-2 .layui-layer-setwin .layui-layer-close2{
background:url(../img/icon-conner-s-02.png) no-repeat center center;
}
.draft-layer-3 .layui-layer-setwin .layui-layer-close2{
background:url(../img/icon-conner-s-03.png) no-repeat center center;
}
.draft-layer-4 .layui-layer-setwin .layui-layer-close2{
background:url(../img/icon-conner-s-04.png) no-repeat center center;
}
.draft-layer-5 .layui-layer-setwin .layui-layer-close2{
background:url(../img/icon-conner-s-05.png) no-repeat center center;
}
.gt-list-type{
width: 46px;
font-size: 20px;
}
.gt-list-body+span,.gt-list-body+span+span{
color: #89939c;
}
.gt-waitdo li p em{
right: 51px;
top: -78px;
}
.gt-waitdo li.gtoa-meeting p em{
right: 46px;
top: -78px;
}
.gt-waitdo .on em{
right: 56px!important;
top: -67px!important;
}
.gtoa-to-read.gt-waitdo li p em{
right: 50px;
top:70px;
}
.gt-waitdo .gtoa-meeting.on em{
right: 46px!important;
top: -67px!important;
}
.m2 .gt-draft-mark:before{
border-right: 0.6em solid #ab321e;
}
.m3 .gt-draft-mark:before{
border-right: 0.6em solid #7d0026;
}
.m4 .gt-draft-mark:before{
border-right: 0.6em solid #47007d;
}
.m5 .gt-draft-mark:before{
border-right: 0.6em solid #0b477e;
}
.t5{
background-color: #1c93ff;
}
.gt-draft{
overflow: hidden;
height: 105px;
}
.draft-layer .gt-draft{
overflow: hidden;
height:240pxpx;
}
.s-color-1{
background-color: #ffeed5;
color: #f49c1c;
}
.s-color-2{
background-color: #ffe4d5;
color: #dc4930;
}
.s-color-3{
background-color: #ffe6f0;
color: #ea3d72;
}
.s-color-4{
background-color: #eee6ff;
color: #b341e3;
}
.s-color-5{
background-color: #e6eeff;
color: #1c93ff;
}
.gt-draft-container .col-xs-4:nth-child(1){
width: 45.66%;
}
.gt-draft-container .col-xs-4:nth-child(3){
width: 21%;
}
.gt-draft-container .col-xs-4:nth-child(1) .gt-draft li{
width: 33.33%;
padding-right: 10px;
margin-right: 0;
}
.gt-draft-container .col-xs-4:nth-child(3) .gt-draft li{
width: calc(100% - 20px);
margin-right: 0;
min-width: 110px;
}
.gt-draft-container .col-xs-4:nth-child(3) .gt-draft-mark{
padding-right: 30px;
}
/* 2019-09-26 白色主题 default-white --start */
.default-white .default-white.gt-body{
background-color: #f5f7fa;
}
.default-white .gt-waitdo > ul > li{
margin-left: 0;
width: 140px;
}
.default-white .gtoa-document-floating{
left: 160px;
width: calc(100% - 160px);
box-shadow: none;
}
.default-white .gt-waitdo li.on{
background-color: #3366cc;
}
.default-white .gt-waitdo li p{
width: 100%;
height: 100%;
margin-left: 0;
margin-top: 0;
padding: 10px 15px;
color: #333;
}
.default-white .gt-waitdo li.on p{
width: 100%;
height: 100%;
margin-left: 0;
margin-top: 0;
padding: 10px 15px;
color: #fff;
}
.default-white .gt-waitdo li.gtoa-meeting p{
width: 100% !important;
margin-left:0 !important;
}
.default-white .gt-waitdo li.on p:before{
position: absolute;
right: -20px;
top:45px;
content: '';
border-top: 10px solid transparent;
border-left: 10px solid #3366cc;
border-right: 10px solid transparent;
border-bottom: 10px solid transparent;
}
.default-white .gt-waitdo li p .fa{
top:auto;
bottom: 10px;
right: 10px;
color: #3366cc;
width: 46px;
height: 46px;
border-radius: 50%;
background-color: #c1d0ed;
text-align: center;
line-height: 46px;
opacity: 1;
font-size: 24px;
}
.default-white .gt-waitdo li.on p .fa{
color: #fff;
background-color: #5c85d6;
}
.default-white .gt-waitdo li p em{
top:50px;
left: 15px;
right: auto !important;
background-color: transparent;
border-radius: 0;
font-size: 26px;
color: #d7001d;
}
.default-white .gt-waitdo .on em{
top:50px !important;
left: 15px !important;
right: auto !important;
}
.default-white .gt-waitdo li.on p em{
color: #fff;
}
.default-white .gt-waitdo li.gtoa-to-do{
background-color: #e5eaf5;
}
.default-white .gt-waitdo li.gtoa-to-read{
background-color: #e5eaf5;
}
.default-white .gt-waitdo li.gtoa-meeting{
background-color: #e5eaf5;
}
.default-white .gt-waitdo li.gtoa-to-do.on{
background-color: #3366cc;
}
.default-white .gt-waitdo li.gtoa-to-read.on{
background-color: #3366cc;
}
.default-white .gt-waitdo li.gtoa-meeting.on{
background-color: #3366cc;
}
.default-white .gt-i-title{
position: relative;
}
.default-white .gt-i-title:before{
content: '';
display: block;
position: absolute;
left: 25px;
bottom: 0;
width: calc(100% - 50px);
height:1px;
background-color: #eaeffa;
}
.default-white .gt-i-title.do{
color: #333;
background-color: #fff;
}
.default-white .gt-swtich a{
color: #333;
}
.default-white .gt-matter a{
color: #333;
}
.default-white .gt-waitdo-body{
padding-left: 25px;
padding-right: 25px;
}
.default-white .gt-list-item{
padding-left: 0;
padding-right: 0;
}
.default-white .gt-swtich a .label{
border:1px solid #89939c;
border-radius: 10px;
width: auto;
display: inline-block !important;
padding: 2px 9px 1px 9px;
}
.default-white .gt-matter a .label{
border:1px solid #89939c;
border-radius: 10px;
width: auto;
display: inline-block !important;
padding: 2px 9px 1px 9px;
}
.default-white .gt-i-title .gt-i-btn a{
color:#36c;
}
.default-white .gt-i-title.read{
color: #333;
background-color: #fff;
}
.default-white .gt-i-title.meet{
color: #333;
background-color: #fff;
}
.default-white .gt-i-title.draft{
background-color: #eaeffa;
overflow: hidden;
}
.default-white .draft h3 .fa{
color: #3366cc;
}
.default-white .gt-draft-container{
padding-left: 0;
padding-right: 0;
padding-top: 0;
padding-bottom: 0;
}
.default-white .gt-draft-mark{
left: 0;
top:0;
margin-top: 0;
padding-left: 10px;
border-radius: 0 0 20px 0;
padding-right: 30px;
}
.default-white .gt-i-title.draft:after{
content: '';
display: block;
height: 0;
clear: both;
visibility: hidden;
overflow: hidden;
}
.default-white .gt-draft-container:after{
content: '';
display: block;
height: 0;
clear: both;
visibility: hidden;
overflow: hidden;
}
.default-white .draft .row{
margin-left: 0;
margin-right: 0;
}
.default-white .gtoa-draft .row{
margin-left: 0;
margin-right: 0;
}
.default-white .gt-draft-container .col-xs-4{
padding-left: 0;
padding-right: 0;
}
.default-white .gt-draft-container .col-xs-6{
padding-left: 0;
padding-right: 0;
}
.default-white .gt-draft-mark:before{
display: none;
}
.default-white .t1{
background-color: #f9ebd1;
color: #e4aa56;
}
.default-white .t2{
background-color: #ffe7e1;
color: #ee583a;
}
.default-white .t3{
background-color: #ffe3f3;
color: #de2e91;
}
.default-white .t4{
background-color: #e3dff7;
color: #7157e6;
}
.default-white .t5{
background-color: #d9e8ff;
color: #277aec;
}
.default-white .gt-draft-item{
padding-top: 0.1px;
}
.default-white .m1{
background-color: #fff;
border-top: none;
border-left: none;
border-right: 1px solid #d6e0f5;
border-bottom: 1px solid #d6e0f5;
border-radius: 0 0 0 0;
}
.default-white .m2{
background-color: #fff;
border-top: none;
border-left: none;
border-right: 1px solid #d6e0f5;
border-bottom: 1px solid #d6e0f5;
border-radius: 0 0 0 0;
}
.default-white .m3{
background-color: #fff;
border-top: none;
border-left: none;
border-right: none;
border-bottom: 1px solid #d6e0f5;
border-radius: 0 0 0 0;
}
.default-white .m4{
background-color: #fff;
border-top: none;
border-left: none;
border-right: 1px solid #d6e0f5;
border-bottom: none;
border-radius: 0 0 0 0;
}
.default-white .m5{
background-color: #fff;
border-top: none;
border-left: none;
border-right: none;
border-bottom:none;
border-radius: 0 0 0 0;
}
.default-white .gt-draft-container .row:nth-child(2){
margin-top: 0 !important;
}
.default-white .gtoa-draft{
box-shadow: none;
overflow: hidden;
}
.default-white .gtoa-quick-list ul{
padding: 0 10px 10px 10px;
}
.default-white .gtoa-quick-list ul .gt-list-item:first-child{
border-top: none;
}
.default-white .gt-list-item .flow-date{
color: #89939c;
font-size: 14px;
}
.default-white .gtoa-read{
box-shadow: none;
}
.default-white .gtoa-read ul{
height: 590px;
overflow-y: auto;
}
.default-white .gt-draft li .fa{
color: #a6a6a6
}
.default-white .gt-draft li{
color: #5c5c5c
}
.default-white .gt-draft li:hover,
.default-white .gt-draft li:hover .fa{
color: #3366cc
}
.default-white .gt-swtich a .label{
color: #d7001d;
}
.default-white .gt-matter a .label{
color: #d7001d;
}
.default-white .gt-draft-conner{
background-image: none;
top:0;
left: 0;
right: auto;
bottom: auto;
background-color: #000;
z-index: 5;
opacity: 0;
padding: 16px 50px;
}
.default-white .draft-layer .layui-layer-setwin{
top: -9px;
bottom: auto;
right: -8px;
padding: 0;
z-index: 5;
opacity: 1;
height: 30px;
width: 30px;
}
.default-white .draft-layer .layui-layer-setwin a{
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeBAMAAADJHrORAAAALVBMVEUAAAAzZswzZswzZswzZswzZswzZswzZswzZswzZswzZswzZszt8frc5fb9/v/IZ30lAAAAC3RSTlMAz40Z4LyAaFgrmCeVvbsAAAClSURBVBjTYwAB5qaQ3a4aBgxQwJm4GwTEJkD5hbshQBzCNdoNA8pgzavh/F0gI5h2I4ACkF+NxN8ONFx6914wG0RtnMDABmScBvPPAnECgyGQPAPi7gGJCjN0g5kwwR0M2iDqDFRs9yaGaIhaiPTurQzeYPoMRHr3FgaIXXveQF2AzkdXj24eun3o7kF3L7p/0P2LFh7o4YUenmjhjR4fmPGFHp8AXE4AkDDqaYgAAAAASUVORK5CYII=);
}
.default-white .draft-layer .m1{
border-radius: 0 0 50px 0;
border-bottom: none;
border-right: none;
}
.default-white .draft-layer .m2{
border-radius: 0 0 50px 0;
border-bottom: none;
border-right: none;
}
.default-white .draft-layer .m3{
border-radius: 0 0 50px 0;
border-bottom: none;
border-right: none;
}
.default-white .draft-layer .m4{
border-radius: 0 0 50px 0;
border-bottom: none;
border-right: none;
}
.default-white .draft-layer .m5{
border-radius: 0 0 50px 0;
border-bottom: none;
border-right: none;
}
@media screen and (max-width: 1206px){
.default-white .gt-draft-mark{
/*font-size: 14px;*/
}
}
/* 2019-09-26 白色主题 default-white --end */
/* 2019-10-25 白色主题下 2560*1440 分辨率下 首页调整 --start */
/* 通过 媒体查询 min-height:991px ,max-height:1440px;max-width:2560px,min-width:1921px; */
@media screen and (max-height:1440px) and (min-height:991px) and (max-width:2560px) and (min-width:1721px) {
.gt-body{
padding-top: 30px;
}
.gt-row>.col-xs-9{
padding: 0 40px;
}
.default-white .gt-waitdo > ul > li{
margin-bottom: 40px;
width: 180px;
height: 140px;
}
.default-white .gt-waitdo li p,.default-white .gt-waitdo li.on p{
padding: 20px 25px;
}
.default-white .gtoa-document-floating {
left: 200px;
width: calc(100% - 200px);
}
.gt-waitdo{
margin-bottom: 60px;
}
.gt-i-title{
height: 80px;
}
.gt-swtich a{
line-height: 80px;
font-size: 24px;
}
.gt-i-title h3{
font-size: 24px;
line-height: 80px;
}
.default-white .gt-waitdo li p em{
top:60px;
left: 23px;
}
.default-white .gt-waitdo .on em{
top: 60px !important;
left: 23px !important;
right: auto !important;
}
.default-white .gt-waitdo li p .fa{
bottom: 20px;
right: 20px;
}
.gt-list-item{
padding: 20px 25px;
}
.gt-waitdo-body{
height: 500px;
}
.gt-list-body h3{
font-size: 20px;
}
.gt-waitdo li p{
font-size: 24px;
}
.gt-list-body+span.gt-list-body+span+span{
font-size: 16px;
}
.gt-i-title .gt-i-btn{
line-height: 80px;
font-size: 18px;
}
.gt-i-title .gt-i-btn a{
font-size: 18px;
}
.gt-draft-item{
height: calc(50vh - 395px);
min-height: 155px;
}
.gt-draft{
height: calc(100% - 60px);
}
.gt-draft-item ul{
margin-top: 50px;
}
.gt-draft li{
/*line-height: calc(16.7vh - 145px);*/
line-height: 54px;
font-size: 20px;
}
.gt-draft-mark{
padding-top: 8px;
padding-bottom: 8px;
font-size: 20px;
}
.default-white .gt-waitdo li p .fa{
height: 54px;
width: 54px;
line-height: 54px;
}
.gtoa-quick-list .gt-list-item{
padding: 15px 25px;
}
.gtoa-quick-list>ul{
height: calc(100vh - 360px)!important;
}
.gtoa-deal-race h3{
font-size: 24px;
}
.gtoa-deal-race p{
font-size: 18px;
}
.gtoa-deal-race p b{
font-size: 24px;
}
.gt-draft-title{
height: auto;
}
.gt-list-item .flow-type{
font-size: 16px;
}
.default-white .gt-list-item .flow-date{
font-size: 16px;
}
.gt-row>.col-xs-3{
padding-right: 40px;
padding-left: 0;
}
.gt-matter a{
line-height: 80px;
font-size: 24px;
}
}
/* 2020-3-19 增加首页相应样式 start*/
@media screen and (max-width: 1366px){
.gt-swtich a{
font-size: 16px;
}
.gt-matter a{
font-size: 16px;
}
}
\ No newline at end of file
String.prototype.startWith=function(str){
var reg=new RegExp("^"+str);
return reg.test(this);
}
var contextProcessor = function(ctx, url, onlyContext){
let externArray = [
/^\/{0,1}justitia\/.*/g,
/^\/{0,1}bf\/.*/g
];
let otherArray = [
/^\/{0,1}homepage\/.*/g
];
// let externArray = [
// /^\/{0,1}bf\/.*/g
// ];
externArray.forEach(function(reg){
let result = reg.test(url);
if(result){
ctx = '';
}
});
otherArray.forEach(function(reg){
let result = reg.test(ctx);
if(result){
ctx = '/oa/';
}
});
if(onlyContext)
return ctx;
else
return ctx + url;
}
String.prototype.endWith=function(str){
var reg=new RegExp(str+"$");
return reg.test(this);
}
var cov={
type:function(type,cat,flowSort,flowSort2){
if('do'==cat || 'other'==cat){
var _word = "办";
if(type != null && type != undefined && type != ""){
if(type.startWith("FW")){
_word = "发";
}else if(type.startWith("QB")){
_word = "签";
}else if(type.startWith("HYJY")){
_word = "会";
}else if(type.startWith("SW")){
_word = "收";
}else if(type.startWith("archives_Approval")){
//二级区分
if(flowSort!=""&&flowSort=="archives_Approval_stamp_GROUP"){
_word = "印";
}
if(flowSort!=""&&flowSort=="license_borrow_GROUP"){
_word = "证";
}
}else{
_word = "办";
}
return _word;
}
return _word;
}else if("read"==cat){
return "阅";
}else if("meet"==cat){
return "会";
}
},
jj:function(jj){
if('urgent'==jj){
return "<span class='label label-danger'>紧急</span>";
}else if('major'==jj){
return "<span class='label label-danger'>紧急</span>";
}else{
//return "<span class='label'>一般</span>";
}
},
dateFtt:function(fmt,date){ //author: meizz
var o = {
"M+" : date.getMonth()+1, //月份
"d+" : date.getDate(), //日
"h+" : date.getHours()%12 == 0 ? 12 : date.getHours()%12, //小时
"H+" : date.getHours(), //小时
"m+" : date.getMinutes(), //分
"s+" : date.getSeconds(), //秒
"q+" : Math.floor((date.getMonth()+3)/3), //季度
"S" : date.getMilliseconds() //毫秒
};
var week = {"0": "日", "1": "一", "2": "二", "3": "三", "4": "四", "5": "五", "6": "六"};
if(/(y+)/.test(fmt)){
fmt=fmt.replace(RegExp.$1, (date.getFullYear()+"").substr(4 - RegExp.$1.length));
}
if(/(E+)/.test(fmt)){
fmt = fmt.replace(RegExp.$1, ((RegExp.$1.length > 1) ? (RegExp.$1.length > 2 ? "星期" : "周") : "") + week[date.getDay() + ""]);
}
for(var k in o){
if(new RegExp("("+ k +")").test(fmt)){
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length==1) ? (o[k]) : (("00"+ o[k]).substr((""+ o[k]).length)));
}
}
return fmt;
}
}
$(document).on('click', '.gt-draft li', function() {
index.open($(this).attr("data-url")+"&portal=true");
console.log('响应点击事件');
});
var countDo=0,countOther=0;
var index={
open:function(url){
window.open($("#oa_location").val() + url +"&userid="+$("#oa_userid").val()+"&portal=true");
},
//isPortal:是否为portal
init:function(isPortal){
$(".gtoa-quick-btn").click(function(){
if($(this).attr("data-type")=="draft"){
$.win.open(ctx+"workbench/shortcut/personset",'我要起草设置',['90%','90%']);
}else if($(this).attr("data-type")=="refresh"){
index.draft();
}else{
$.win.open(ctx+"workbench/shortcut/personset?_t="+$(this).attr("data-type"),'快捷方式配置',['90%','90%']);
}
});
$(".gt-waitdo-item").on("mousemove",function(){
if ($(this).hasClass('on')) return false;
$(this).addClass('on').find('.gtoa-document-floating').show();
$(this).siblings('li').removeClass('on').find('.gtoa-document-floating').hide();
});
if(isPortal){
index.shortCut();
}else{
index.flowreadInit();
index.flowread();
}
index.draft();
index.swtich();
index.getFileCount();
$.win.loading("加载数据中,请稍后...");
$(['meet']).each(function(i,n){
index.load(n);
});
index.load('do-other',true);
index.todo();
index.toberead();
$.win.closeLoading();
$(".gt-draft-conner").each(function(i){
$(this).on('click',function(){
index.more($(this).parents('.gt-draft-item').parent().html(),i+1);
$('.draft-layer').prev('.layui-layer-shade').hide();;
})
})
},
more:function(t,i){
layer.open({
skin: 'draft-layer draft-layer-'+i,
type: 1 //Page层类型
,area: [$('.gt-draft-container').innerWidth()-60+'px', $('.gt-draft-container').innerHeight()-35+'px']
,title:false
,shade: 0.6
,offset: [
$('.m1').offset().top+5
,$('.m1').offset().left+10
]
,maxmin:false //允许全屏最小化
,anim:3 //0-6的动画形式,-1不开启
,content: t
});
},
shortCut:function(){
// var len = 0;
// $.get(ctx+"workbench/shortcut/person?_t=shortcut&_time="+(Math.random()*60),function(res){
// len = res.length;
// if(len > 0){
// $(".gtoa-quick-list ul").html("");
// $(res).each(function(i,n){
// var li = $("<li data-url='"+n.url+"' data-type='"+n.type+"' title='"+n.name+"'><a href='javascript:void(0);'><img src='../workbench/cutimgs/"+n.ico+"'><span>"+n.name+"</span></a></li>");
// li.bind("click",function(){
// var url=$(this).attr("data-url")
// var type = $(this).attr("data-type");
// if(url.indexOf("http") == -1){
// url = "http://"+url
// }
// window.open(url);
// }).appendTo($(".gtoa-quick-list ul"));
// });
// }
// for(var i=0;i<(21-len);i++){
// var li = $("<li class='gt-short-item'><a href='javascript:void(0);'><i class='fa '></i><br/><span>&nbsp;</span></a></li>");
// li.bind("click",function(){}).appendTo(".gtoa-quick-list ul");
// }
// });
var len = 0;
$.get(ctx+"workbench/shortcut/person?_t=shortcut&_time="+(Math.random()*60),function(res){
len = res.length;
if(len > 0){
$(".gtoa-quick-list ul").html("");
$(res).each(function(i,n){
var li = $("<li data-url='"+n.url+"' data-type='"+n.type+"' title='"+n.name+"'><a href='javascript:void(0);'><img src='../workbench/cutimgs/"+n.ico+"'><span>"+n.name+"</span></a></li>");
li.bind("click",function(){
var url=$(this).attr("data-url")
var type = $(this).attr("data-type");
if(url.indexOf("http") == -1){
url = "http:"+url
}
window.open(url);
}).appendTo($(".gtoa-quick-list ul"));
});
}
for(var i=0;i<(18-len);i++){
var li = $("<li class='gt-short-item'><a href='javascript:void(0);'><i class='fa '></i><br/><span>&nbsp;</span></a></li>");
li.bind("click",function(){}).appendTo(".gtoa-quick-list ul");
}
});
},
/**
*
* @param {} type 加载的类型
* @param {} flag 是否只显示数量
* @param {} fromOld 从就旧数据库重新加载
*/
load:function(type,flag,fromOld){
if(fromOld == undefined){fromOld=true}
if(flag == undefined){flag = false;};
var mtype = "workFlowWrite";
if(type=='read'){
mtype = "docSend";
}else if(type=='meet'){
mtype = "message";
}else if(type=='do-other'){
mtype="thirdPartyWorkFlowWrite";
type = "other";
}else if(type=='flow_read'){
mtype="workFlowRead";
}
var data={messageType:mtype,isInit:fromOld,number:5}
var config ={
url: ctx + "portal/msg/indexMessage?_time="+(Math.random()*60),
type: "post",
dataType: "json",
data:data,
async:true,
success: function (res) {
if (res.code == '0') {
$(".number-"+type).text(res.data.number);
if(parseInt(res.data.number)>0){
$(".number-"+type).show();
}else{
$(".number-"+type).hide();
}
if(!flag){
var ul = $(".list-"+type+" ul").html("");
if(res.data.data.length > 0){
$.each(res.data.data, function (index, item) {
var _ul = item.url;
try{
if(_ul.indexOf("http")==-1){
_ul = ctx + _ul;
}
}catch(err){
console.log(err);
}
//特殊页面进行编码
if(_ul.indexOf("notice_user.jsp")>-1){
_ul=encodeURI(encodeURI(_ul));
}
var a = $("<a class='list-group-item gt-list-item' data-url='" + _ul + "'></a>")
.append("<span class='gt-list-type'>"+cov.type(item.categoryTypes,type)+"</span>")
.append("<div class='gt-list-body'><h3>"+item.title+"&nbsp;</h3></div>")
.append(cov.jj(item.level))
.append("<span>来源:&nbsp;"+item.fromUserName+"</span>")//张三(部门名称)
.append("<span class='pull-right'>"+$.util.dateFtt(item.receiveTime,'MM月dd日 EE')+"</span>");
a.click(function(){
if('other'!==type){
window.open($(this).attr("data-url"));
}else{
var re = new RegExp("&","g");
//var otherurl = _ul.replace(re,"-|-");
//var jumpurl = ctx+"workbench/gotoOtherdb?url="+otherurl;
//window.open(jumpurl);
if(item.fromUserName=="开元系统"){
alert("请到开元系统进行相关处理")
}else{
window.open($(this).attr("data-url"))
}
}
});
ul.append(a)
});
}else{
if(type=="meet"){
$(".title-meet").html("您<b class='number-meet'>无</b>会议需要处理");
}else if(type=="read"){
$(".title-read").html("您<b class='number-meet'>无</b>待阅需要处理");
}
}
};
if('do' == type || 'other'==type){
'do' == type?countDo = res.data.number : countOther=res.data.number;
if((countDo + countOther)>0){
$(".number-do").show();
}else{
$(".number-do").hide();
}
$(".number-left").text((countDo + countOther)+"");
}
$.win.closeLoading();
}
}
};
$.ajax(config);
},
todo: function(){
var ul = $(".list-do ul").html("");
var config ={
url: ctx + "todo/list/1/5?_time="+(Math.random()*60),
type: "post",
dataType: "json",
async:true,
success: function (res) {
if(res!=""){
var obj = eval(res.list);
countDo = res.count;
$.each(obj, function (index, item){
var _ul = "";
if (item.url != null && item.url != "null") {
if (item.dataSource == "local") {
if (item.url.indexOf("http") > -1) {
_ul = item.url;
} else {
var begin = item.url.substr(0,4);
_ul = contextProcessor(ctx, item.url);
}
} else if (item.dataSource == "old") {
_ul = oa_location + item.url + "&dbid=" + item.id + "&userid=" + $("#oa_userid").val() + "&deptid=" + item.deptId + "&portal=true";
if(_ul.indexOf("notice_user.jsp")>-1){
_ul=encodeURI(encodeURI(_ul));
}
}
}
var date = new Date(0 - item.receiveTime);
var a = $("<a class='list-group-item gt-list-item' data-url='" + _ul + "' "+(item.limitTime!=null?"title='反馈结束时间:"+item.limitTime+"'":"")+"></a>")
.append("<span class='gt-list-type'>" + cov.type(item.sendclass, "do",item.flowSort) + "</span>")
.append("<div class='gt-list-body'><h3 " + ((item.urgency=="特急"||item.urgency=="加急"||item.urgency=="是"||item.urgency=="major"||item.urgency=="urgent")?"style='color:red;'":"") + ">"
+(item.showLimitPNG=='true'?"<img style='height: 15px;width: 15px;' src=\"/oa/workbench/img/limitTime.gif\">":"")
+ (item.leaderInsNum>0?"<img style='height: 15px;width: 15px;' src=\"/oa/workbench/img/leaderIns.png\">":"") + "&nbsp;"+item.title+"</h3></div>")
.append(cov.jj(''))
.append("<span>来源:&nbsp;" + (item.fromUserName != null ? item.fromUserName : "") + "</span>")//张三(部门名称)
.append("<span class='pull-right'>" + cov.dateFtt('MM月dd日 EE', date) + "</span>");
a.click(function () {
window.open($(this).attr("data-url"))
});
ul.append(a);
});
if((countDo + countOther)>0){
$(".number-do").show();
$(".number-do").text(countDo+"");
}else{
$(".number-do").hide();
}
var count = (countDo + countOther);
$(".number-left").text(count+"");
}
}
};
$.ajax(config);
},
toberead: function(){
var ul = $(".list-read ul").html("");
var config ={
url: ctx + "toberead/list/1/5?_time="+(Math.random()*60),
type: "post",
dataType: "json",
async:true,
success: function (res) {
if(res!=""){
var obj = eval(res.list);
var count = res.count;
$.each(obj, function (index, item){
var _ul = "";
if (item.url != null && item.url != "null") {
if (item.dataSource == "local") {
if (item.url.indexOf("http") > -1) {
_ul = item.url;
} else {
var begin = item.url.substr(0,4);
_ul = contextProcessor(ctx, item.url);
}
} else if (item.dataSource == "old") {
if(item.relationTable == "TZ_PROJECT"){
var pageUrlParamInfo = "signal=signRemark;oadb=oadb;id="+item.relationId+";type=view;mode=daiyue;sendid="+item.id;
_ul = oa_location + "/sso/project_login_jump.jsp?ip=" + oa_location + "&userName=" + $("#loginName").val() + "&pwd=" + $("#password").val() + "&pageUrlParam=" + item.url + "&pageUrlParamInfo=" + pageUrlParamInfo;
}else if(item.relationTable == "NEWOA_PROJECT"){
_ul = oa_location + "/newoa/newoa_dy_jump.jsp?dyurl=" + item.url + "&sendId=" + item.id + "&id=" + item.relationId + "&userid=" + $("#oa_userid").val() + "&param=dy";
}else{
_ul = oa_location + item.url + "&sendid=" + item.id + "&userid=" + $("#oa_userid").val() + "&portal=true";
}
}
}
var date = new Date(0 - item.receiveTime);
var a = $("<a class='list-group-item gt-list-item' data-url='" + _ul + "'></a>")
.append("<span class='gt-list-type'>" + cov.type("", "read") + "</span>")
.append("<div class='gt-list-body'><h3>" + (item.leaderInsNum>0?"<img style='height: 15px;width: 15px;' src=\"/oa/workbench/img/leaderIns.png\">":"") + "&nbsp;"+item.title+"</h3></div>")
.append(cov.jj(''))
.append("<span>来源:&nbsp;" + (item.fromUserName != null ? item.fromUserName : "") + "</span>")//张三(部门名称)
.append("<span class='pull-right'>" + cov.dateFtt('MM月dd日 EE', date) + "</span>");
a.click(function () {
window.open($(this).attr("data-url"))
});
ul.append(a)
});
$(".number-read").show();
if(count>0){
$(".number-read").text(count+"");
}else{
$(".number-read").text("0");
}
}
}
};
$.ajax(config);
},
flowread:function(){
var tabs = $('.gt-matter a');
tabs.on('click',function(){
if($(this).hasClass('on') || $(this).hasClass('t-line')) return false;
$(this).addClass('on').siblings('a').removeClass('on');
var type = $(this).attr("data-type");
var url = "";
if(type=="done-matter"){
url = ctx + "done/list/1/8?_time="+(Math.random()*60);
}else{
url = ctx + "read/list/1/8?_time="+(Math.random()*60);
}
var ul = $(".gtoa-quick-list ul").html("");
$.get(url,{},function(res){
if(res!=""){
var obj = eval(res);
$.each(obj, function (index, item){
var _ul = "";
if(type=="done-matter"){
if(item.handdoneurl){
var tempctx = contextProcessor(ctx, item.handdoneurl, true);
_ul = tempctx + item.handdoneurl+"?recordid="+item.recordid+"&docid="+item.docid+"&filetypeid="+item.filetypeid+"&readitemid="+item.id;
}else if(item.readUrl){
_ul = oa_location + item.readUrl + item.recordid + "&workflowid=" + item.workflowid +"&userid="+$("#oa_userid").val()+"&portal=true";
}
}else{
if(item.source=="local"){
var tempctx = contextProcessor(ctx, item.view_url, true);
_ul = tempctx + item.view_url;
}else if(item.source=="old"){
if(item.view_url.substr(item.view_url.length-1,item.view_url.length)=="="){
_ul = oa_location + item.view_url + item.relation_id +"&userid="+$("#oa_userid").val()+"&portal=true";
}else{
_ul = oa_location + item.view_url + "&userid="+$("#oa_userid").val()+"&portal=true";
}
}
}
var a = $("<a class='list-group-item gt-list-item' data-url='" + _ul + "'></a>").append("<sapn class='flow-type'>【"+item.filetypename+"】</sapn><label class='flow-date'>"+$.util.dateFtt(item.readtime,'MM月dd日 EE')+"</label><div class='gt-list-body'><h3>"+item.title+"&nbsp;</h3></div>").append(cov.jj(""));
if(type=="read-matter"){
a = $("<a class='list-group-item gt-list-item' data-url='" + _ul + "'></a>").append("<sapn class='flow-type'>【"+item.keyword+"】</sapn><label class='flow-date'>"+$.util.dateFtt(item.notion_date,'MM月dd日 EE')+"</label><div class='gt-list-body'><h3>"+item.send_title+"&nbsp;</h3></div>").append(cov.jj(""));
}
a.click(function(){
window.open($(this).attr("data-url"))
});
ul.append(a)
});
}
});
});
},
flowreadInit:function(){
var ul = $(".gtoa-quick-list ul").html("");
var url = ctx + "done/list/1/8?_time="+(Math.random()*60);
$.get(url,{},function(res){
if(res!=""){
var obj = eval(res);
$.each(obj, function (index, item){
var _ul = "";
if(item.handdoneurl){
var tempctx = contextProcessor(ctx, item.handdoneurl, true);
_ul = tempctx + item.handdoneurl+"?recordid="+item.recordid+"&docid="+item.docid+"&filetypeid="+item.filetypeid+"&readitemid="+item.id;
}else if(item.readUrl){
_ul = oa_location + item.readUrl + item.recordid + "&workflowid=" + item.workflowid +"&userid="+$("#oa_userid").val()+"&portal=true";
}
var a = $("<a class='list-group-item gt-list-item' data-url='" + _ul + "'></a>").append("<sapn class='flow-type'>【"+item.filetypename+"】</sapn><label class='flow-date'>"+$.util.dateFtt(item.readtime,'MM月dd日 EE')+"</label><div class='gt-list-body'><h3>"+item.title+"&nbsp;</h3></div>").append(cov.jj(""));
a.click(function(){
window.open($(this).attr("data-url"))
});
ul.append(a)
});
}
});
},
draft:function(){
$.get(ctx +"workbench/shortcut/person?_time="+(Math.random()*60),function(res){
$(res).each(function(i,item){
$(".draft-"+item.type).html("");
$(JSON.parse(item.remark)).each(function(i,n){
$("<li data-id='"+n.id+"' data-url='"+n.url+"' title='"+n.name+"'><i style='color:#36c' class='fa fa-file-text-o'></i>"+index.getName(n.rname,n.name)+"</li>").appendTo($(".draft-"+item.type));
/*.click(function(){
index.open($(this).attr("data-url")+"&portal=true");
})*/
});
});
});
},
getName:function(one,two){
if(one != undefined && ""!=one && "自定义名称"!=one){
return one;
}else{
return two;
}
},
swtich:function(){
var tabs = $('.gt-swtich a');
var left = 2;
tabs.on('click',function(){
if($(this).hasClass('on') || $(this).hasClass('t-line')) return false;
var dataType = $(this).attr("data-type");
if(dataType=="todo"){
index.todo();
}else{
index.load($(this).attr("data-type"),false);
}
$(this).addClass('on').siblings('a').removeClass('on');
if($(this).index()== 0 ){
left = 2;
}else{
left = $('.gt-swtich a').eq(0).width()-3;
}
$(this).siblings('i').stop(true,true).animate({
left:left+'px'
},200);
});
},
getFileCount:function(){
$.get(ctx+"done/getFileCount",{},function(res) {
if (res != "") {
$("#fileCount").text(res);
}
})
}
};
var set={
img:function(){
var mt = $("#moduleType").val();
var str = "../cutimgs/";
return "<img src='../cutimgs/"+mt+".png'/>";
},
count:function(){
$(".count").text($(".ul-selected li").size());
},
show:function(type){
$(".ul-selected").html("");
$(person).each(function(i,n){
if(n.type == type){
$(".ul-selected").html("");
var items = JSON.parse(n.remark);
$(items).each(function(i,x){
set.ger(x);
});
}
});
$.get(ctx+"workbench/shortcut/oaDraft/"+type,function(res){
$(".ul-all").html("");
var count = res.length;
$(".count-all").text(count);
$(res).each(function(i,n){
if($(".ul-selected li[data-id='"+n.FILETYPEID+"']").size()){
$(".ul-all").append("<li class='added' data-id='"+n.FILETYPEID+"' data-url='"+n.flowurl+"'><i class='fa'></i>"+set.img()+"<h4 title='"+n.FLOWOP+"'>"+n.FLOWOP+"</h4></li>");
}else{
$(".ul-all").append("<li data-id='"+n.FILETYPEID+"' data-url='"+n.flowurl+"'><i class='fa fa-plus-circle'></i>"+set.img()+"<h4 title='"+n.FLOWOP+"'>"+n.FLOWOP+"</h4></li>");
}
});
$(".ul-all li").bind("click",function(){
if($(this).hasClass("added")){
//$(this).removeClass("added");
//$(".ul-selected").find("li[data-id='"+$(this).attr("data-id")+"']").remove();
}else{
$(this).find(".fa").removeClass("fa-plus-circle");
var _l = $(this);
set.ger({"id":_l.attr("data-id"),"name":_l.find("h4").attr("title"),"url":_l.attr("data-url")});
set.count();
}
});
});
set.count();
},
ger:function(x){
$(".ul-all li[data-id='"+x.id+"']").addClass("added");
if(x.rname==undefined||x.rname==""){
x.rname = "自定义名称";
}
var li = $("<li data-id='"+x.id+"' class='added' data-url='"+x.url+"'>"+set.img()+"<i class='fa fa-minus-circle'></i><h4 title='"+x.name+"'>"+x.name+"</h4></li>");
li.find("img,.fa").click(function(){
var li = $(this).parent();
li.remove();
$(".ul-all li[data-id='"+li.attr("data-id")+"']").removeClass("added").find(".fa").addClass("fa-plus-circle");
set.count();
});
var text = $("<h5 title='点击修改名称'>"+x.rname+"</h5>").click(function(){
var t = $(this);
layer.prompt({title: '请输入6个汉字以内的名称', formType:3,value:t.text()}, function(na, index){
t.text(na);
layer.close(index);
});
});
$(".ul-selected").append(li.append(text));
},
init:function(btn){
$(".short-btn button").click(function(){
$(".short-btn button").removeClass("btn-primary");
var id = $(this).attr("data-id");
$(this).addClass("btn-primary");
$("#moduleType").val(id);
set.show(id);
});
$(".short-btn button:first").click();
$("ul.ul-selected").sortable({connectWith: "div.move-dd"}).disableSelection();
},
fill:function(arr){
var hase = false;
$(person).each(function(i,n){
if(n.type == $("#moduleType").val()){
var items = JSON.parse(n.remark);
items.remark = arr;
hase = true;
}
});
if(!hase){
person.push({"category":"PERSON","type":$("#moduleType").val(),"remark":arr});
}
},
save:function(){
var arr=[];
$(".ul-selected li").each(function(i,n){
arr.push({id:$(n).attr("data-id"),'name':$(n).find("h4").text(),'rname':$(n).find("h5").text(),'url':$(n).attr("data-url")});
});
console.log(arr);
$.post(ctx+"workbench/shortcut/personsave",{"moduleType":$("#moduleType").val(),"shortcuts":JSON.stringify(arr)},function(res){
$.win.msg(res.msg);
set.fill(JSON.stringify(arr));
$.win.opener().index.draft();
});
}
}
$(document).ready(function () {
selectDepartment();
rightFloatAnimate();
$('.gtoa-left-menu').on('click','.menuItem', menu.click);
hoverMenu();
ReplaceMenu();
checkLinkMenu();
menuSlideFun();
initTopTabFunc();
});
var contextProcessor = function (ctx, url, onlyContext){
let externArray = [
/^justitia\/.*/g,
/^bf\/.*/g
];
externArray.forEach(function(reg){
let result = reg.test(url);
if(result){
ctx = '/';
}
});
let otherArray = [
/^\/{0,1}homepage\/.*/g
];
otherArray.forEach(function(reg){
let result = reg.test(ctx);
if(result){
ctx = '/oa/';
}
});
if(onlyContext)
return ctx;
else
return ctx + url;
};
function closePage(){
if(navigator.userAgent.indexOf("Firefox") != -1 || navigator.userAgent.indexOf("Chrome") != -1){
window.location.href = "about:blank";
window.close();
}else{
window.opener = null;
window.open("", "_self");
window.close();
}
}
/** 初始化加载判断 start**/
function ReplaceMenu(){
var userId = $("#oa_userid").val();
var deptid = $("#oa_deptid").val();
$(".gtoa-submenu a").each(function(i,n){
var menuType = $(n).attr("data-type");
var menuName = $(n).attr("title");
if(menuName=="出差管理" && menuType=="OLDOA-ZDH"){
var url = $(n).attr("data-url");
$(n).attr("data-url",url + "?userid=" + userId + "&deptcode=" + deptid + "&isNew=true&param=travel&url=main.html");
}
if(menuName=="请假管理" && menuType=="OLDOA-ZDH"){
var url = $(n).attr("data-url");
$(n).attr("data-url",url + "?userid=" + userId + "&deptcode=" + deptid + "&isNew=true&param=leave&url=main.html");
}
})
}
function checkLinkMenu(){
var linkname = GetQueryString("_type");
if(linkname!=null) {
changepage(linkname);
}
}
function GetQueryString(name){
var reg = new RegExp("(^|&)"+ name +"=([^&]*)(&|$)");
var r = window.location.search.substr(1).match(reg);
if(r!=null)return unescape(r[2]); return null;
}
/** 初始化加载判断 end**/
// 部门下拉选择
function selectDepartment() {
var btn = $('.gtoa-positon-select');
var lists = $('.gtoa-positon-select').siblings('ul');
var container = $('.gtoa-login-position').find('p span');
btn.on('click', function () {
if ($(this).hasClass('turnUp')) {
$(this).removeClass('turnUp').siblings('ul').slideUp();
} else {
$(this).addClass('turnUp').siblings('ul').slideDown();
}
});
lists.find('li').on('click', function () {
if ($(this).hasClass('on')) return false;
btn.removeClass('turnUp');
$(this).addClass('on').siblings('li.on').removeClass('on');
container.html($(this).text());
lists.hide();
settingDefaultDept($(this).find("a").attr("data-id"));
});
var btn2 = $('.gtoa-old-version-btn a');
btn2.on('click', function () {
if ($(this).hasClass('turnUp')) {
$(this).removeClass('turnUp').siblings('ul').slideUp();
} else {
$(this).addClass('turnUp').siblings('ul').slideDown();
}
});
}
/**
* 设置当前登录用户的默认部门
* @param deptId 要设置的默认部门ID
*/
function settingDefaultDept(deptId) {
if ($.util.isNotEmpty(deptId)) {
var config = {
url: ctx + "system/dept/settingDefaultDept",
type: "post",
dataType: "json",
data: {"deptId": deptId},
success: function (result) {
$.win.msg(result.msg);
var oaIp =$("#oa_ip").val();
var oa_userid = $("#oa_userid").val();
window.location.reload();
}
};
$.ajax(config);
}
}
// 左侧菜单点击收回
function menuSlideFun() {
$('.gtoa-slide-btn').on('click', function () {
if ($(this).hasClass('slide-left')) {
$(this).removeClass('slide-left');
$('.gtoa-left-menu').removeClass('menu-slide-left');
$('.gtoa-container').removeClass('gtoa-container-left');
} else {
$(this).addClass('slide-left');
$('.gtoa-left-menu').addClass('menu-slide-left');
$('.gtoa-container').addClass('gtoa-container-left');
}
});
}
/**
* 20190627-- rightFloatAnimate()
* 右上角漂浮动画,鼠标移入,动画区域隐藏(需要考虑鼠标在 iframe 中移动时,传出clientX,clientY)
* */
function rightFloatAnimate() {
var salixState = getCookie('salix');
if (salixState === 'none') {
$('.salix-animate').remove();
$('.salix-close').remove();
}
var frameWin = $('.gtoa-iframe')[0].contentWindow;
var $frameWin = $(frameWin);
var winWid = $(window).width();
// 在 iframe 中移动时,超出一定动画区域
$frameWin.on('mousemove', function (e) {
var x = e.clientX,y = e.clientY;
if (winWid - x < 350 && y < 320) {//进入动画区域
//console.log('进入');
$('.salix-animate').addClass('to-hide');
$('.salix-close').fadeIn();
} else {//离开动画区域
// console.log('移出')
$('.salix-animate').removeClass('to-hide');
$('.salix-close').fadeOut();
}
});
$(document).on('mousemove', function (e) {
var mLeft = e.clientX;
var mTop = e.clientY;
var winWid = $(window).width();
if (winWid - mLeft < 350 && mTop < 320) {//进入动画区域
//console.log('进入');
$('.salix-animate').addClass('to-hide');
$('.salix-close').fadeIn();
} else {//离开动画区域
// console.log('移出')
$('.salix-animate').removeClass('to-hide');
$('.salix-close').fadeOut();
}
});
$('.salix-close').click(function () {
$('.salix-animate').remove();
$('.salix-close').remove();
var Days = 365;
var exp = new Date();
exp.setTime(exp.getTime() + Days*24*60*60*1000);
document.cookie = "salix=none;expires=" + exp.toGMTString();
});
}
//=======================================================
var menu = {
//1.parse_C:标签解析页 2.parse_M:模块解析页面 3.parse_OLD 3.parse_I:独立的首页
OA_Location: "http://oa.sdic.com.cn/jsp/indexpage/main.jsp?portal=true&userid=" + $("#oa_userid").val()+"&curMid=",
type: ['parse_C', 'parse_M', 'parse_I'],
click: function () {
var id = $(this).attr("data-id"), url = $(this).attr('data-url'), dataType = $(this).attr('data-type'); //模块类型
dataType = ((undefined == dataType || "" == dataType) ? menu.type[1] : dataType); //"parse_" +
if (menu.type[2] != "parse_" + dataType) {
if($(this).next().find('dd').size() > 0){
}else {
if(dataType.indexOf("OLDOA") > -1){
$(".gtoa-container-tab").addClass('hide-tab');
}else{
url == "workbench/index"?$(".gtoa-container-tab").addClass('hide-tab'):$(".gtoa-container-tab").removeClass('hide-tab');
$(this).parents('li').addClass('on').siblings('li').removeClass('on');
}
var div = $(this).parents("li").find(".gtoa-submenu");
//if (url == "parse_tab" || dataType.indexOf("OLDOA") > -1) {
$(this).parents("ul").find("li").removeClass("on");
$(this).parents("li").addClass("on");
//}
//console.log('--------------------------------'+dataType);
if (undefined != url && url != "" && url != "#") {
$('.tabs-name').attr("data-id", id).html("<i class='" + $(this).find("i").prop("className") + "'></i><span>" + $(this).text() + "</span>");
tabs.init(id, url,dataType);
}
}
} else {
if("ALONE-SYSTEM"==id){//独立系统
window.open(url);
}else{
window.open(menu.OA_Location + id);
}
}
}
};
var tabs = {
init: function (id, url, dataType) {
$.win.loading("数据加载中,请稍后...");
//console.log("-------------------------"+dataType);
if (menu.type[2] == dataType) {
window.open(url);
} else {
$(".tabs-items").html("");
if (url.indexOf("parse_tab") > -1) {
$.get(ctx+"system/menu/tab/" + id +"?_time="+(Math.random()), function (res) {
$(res).each(function (i, n) {
var itemid = i;
$("<a href='javascript:;' class='tabs-item' data-id='" + n.menuId + "' data-url='" + n.url + "'>" + n.menuName + "</a>").bind("click", function () {
$(".tabs-items a").removeClass("active");
$(this).addClass("active");
tabs.setContent(itemid, $(this).attr("data-url"));
}).appendTo($(".tabs-items"));
});
$(".tabs-items a:first").click();
});
} else if (undefined != url && "" != url && "#" != url) {
tabs.setContent(id, url);
}
};
$.win.closeLoading();
},
setContent: function (id, url) {
var oa_userid = $("#oa_userid").val();
var oa_deptid = $("#oa_deptid").val();
if(url.indexOf("/") == 0){
url = url.replace("/","");
}
var iframe = '<iframe class="gtoa-iframe sino_iframe" width="100%" height="100%" src="' + url + '" frameborder="0" data-id="' + id + '"></iframe>';
try{
if(url.indexOf("http")==-1){
var begin = url.substr(0,3);
if(url.indexOf("http")==-1){
$(".gtoa-iframe").attr("src", contextProcessor(ctx, url));
}else{
$(".gtoa-iframe").attr("src",ctx + url);
}
}else{
$(".gtoa-iframe").attr("src",encodeURI(encodeURI(url+"&portal=true&userid="+oa_userid+"&deptid="+oa_deptid)));
}
}catch(err){
console.log(err);
}
$('.mainContent').html(iframe);
$('.mainContent iframe').load(function () {
//$.win.closeLoading();
});
},
click: function () {
//console.log('---------------------------tab.click');
}
};
// 20190626 左侧导航hover 交互
function hoverMenu() {
var leftMenu = $('.gtoa-left-menu');
leftMenu.on('mousemove','.gtoa-menu-list li',function(){
$(this).find('.gtoa-submenu').stop(true,true).show();
});
leftMenu.on('mouseleave','.gtoa-menu-list li',function(){
$(this).siblings('li').find('.gtoa-submenu').stop(true,true).fadeOut(10);
$(this).find('.gtoa-submenu').stop(true,true).fadeOut(300);
});
}
//20190911 添加顶部 tab 切换,背景色交互
function initTopTabFunc(){
// 页面初始化时
var lis = $('.gtoa-top-tab').find('li');
lis.each(function(i){
if($(this).hasClass('on')){
$('.gtoa-left-menu').addClass('top-tab-style-'+(i+1));
return false;
}
});
// 点击切换
lis.on('click',function(){
if($('.gtoa-slide-btn').hasClass('slide-left')){
$('.gtoa-slide-btn').removeClass('slide-left');
}
var tempIndex = $(this).index()+1;
if($(this).hasClass('on')){
return false;
}
$(this).addClass('on').siblings('.on').removeClass('on');
$('.gtoa-left-menu').removeClass().addClass('gtoa-left-menu top-tab-style-'+ tempIndex);
//切换法律导航
if($(this).hasClass('top-tab-law')){
changepage('law')
}else if($(this).hasClass('top-tab-tz')){//切换投资系统
window.location.href="http://oa.sdic.com.cn/tz/index.jsp?sysType=true"
}else if ($(this).hasClass('top-tab-medicine')) { // 切换资产管理系统
window.location.href="http://oa.sdic.com.cn/zcgl"
}else if ($(this).hasClass('top-tab-supervise')) { // 切换督办导航
changepage('db')
}else if ($(this).hasClass('top-tab-actsupervise')) { // 切换三年落实计划导航
changepage('act')
}else if ($(this).hasClass('top-tab-bf')) { // 切换督办导航
changepage('bf')
}else{//切换oa导航
changepage('oa')
}
return false;
});
}
function changepage(type){
$('.gtoa-menu-list').html("");
var firstpage = '<li class="on"><a href="javascript:;" data-url="workbench/index" data-type="M" class="menuItem"><i class="fa fa-home"></i><span>协同首页</span></a></li>';
var url = ctx + "workbench/changetype/" + ('law'==type?'law': 'db' == type ? 'db': 'act' == type ? 'act' : 'bf' == type ? 'bf': 'oa');
$.get(url,function(res){
if("law"!=type && "db" != type && "act" != type && "bf" != type){
$('.gtoa-menu-list').append(firstpage);
}
$(res).each(function (i, menu) {
var contentdiv = '';
if($(menu.children).size()>0){
contentdiv = '<div class="gtoa-submenu" style="display: none;"><dl>';
$(menu.children).each(function(i,menudiv){
var ddurl = '<dd><a href="javascript:void(0);" class="menuItem" data-url="'+menudiv.url+'" title="'+menudiv.menuName+'" data-id="'+menudiv.menuId+'" data-type="'+menudiv.menuType+'"><i></i><span>'+menudiv.menuName+'</span></a></dd>';
contentdiv = contentdiv+ddurl;
})
contentdiv = contentdiv+'</dl></div>';
}
var content='<li data-id="'+menu.menuId+'"><a href="javascript:void(0);" class="menuItem" data-url="'+menu.url+'" data-id="'+menu.menuId+'" data-type="'+menu.menuType+'" title="'+menu.menuName+'"><i class="fa '+menu.icon+'"></i><span>'+menu.menuName+'</span></a>'+contentdiv+'</li>';
$('.gtoa-menu-list').append(content);
});
if("gtoa-submenu");
var $a = $(".gtoa-menu-list a:first");
if($a.next().find("a.menuItem").size() > 0){
$a.next().find("a.menuItem:first").click();
}else{
$a.click();
}
if("law"!=type){
ReplaceMenu();
}
});
}
function getCookie(name) {
var arr,reg=new RegExp("(^| )"+name+"=([^;]*)(;|$)");
if(arr=document.cookie.match(reg))
return unescape(arr[2]);
else
return null;
}
// 弹出开发日志
function jumpChangelog () {
$.win.open(ctx + 'changelog', '更新日志', true, false)
}
<!DOCTYPE html> <!DOCTYPE html>
<html> <html lang="en" xmlns:th="http://www.thymeleaf.org">
<head> <head>
<meta charset="utf-8"> <meta charset="UTF-8">
<title>index</title> <meta name="viewport" content="width=device-width, initial-scale=1.0,maximum-scale=1.0,user-scalable=no">
<meta http-equiv="X-UA-Compatible" content="ie=Edge,chrome=1">
<title>国投集团 | 协同办公平台</title>
<script th:inline="javascript">var ctx = [[@{/}]]; </script>
<link rel="shortcut icon" th:href="@{/favicon.ico}">
<link th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/>
<link rel="stylesheet" th:href="@{/workbench/css/common/common.css}">
<link rel="stylesheet" th:href="@{/css/plugins/toastr/toastr.min.css}" />
<link rel="stylesheet" th:href="@{/js/viewer/css/viewer.css}">
<script th:src="@{/js/jquery.min.js}"></script>
<script th:src="@{/js/bootstrap.min.js}"></script>
<script th:src="@{/ajax/libs/fullscreen/jquery.fullscreen.js}"></script>
<script th:src="@{/js/plugins/pace/pace.min.js}"></script>
<script th:src="@{/js/plugins/layer/layer.js?v=2.4}"></script>
<script th:src="@{/js/viewer/js/viewer.js?v=2.4}"></script>
<script th:src="@{/js/viewer/view-image.js?v=2.4}"></script>
<script th:src="@{/ajax/libs/blockUI/jquery.blockUI.js}"></script>
<script th:src="@{/js/platform.js}"></script>
<!-- 用户老OA法律模块章程管理中上传章程扫描件功能
<script th:src="@{/js/asyncbox/asyncbox.v1.5.beta.min.js}"></script>
-->
</head> </head>
<body> <body class="">
<p>index page</p> <div class="gtoa-header">
<div shiro:principal property="userName"></div>
<input type="hidden" id="oa_ip" name="oa_ip" th:value="${ip}" />
<input type="hidden" id="oa_userid" name="oa_userid" th:value="${oldUserId}" />
<input type="hidden" id="oa_deptid" name="oa_deptid" th:value="${deptHistoryId}" />
<!-- <div class="gtoa-logo"><a href="javascript:void(0);"><img th:src="@{/workbench/img/logo.png}"></a></div> -->
<div class="gtoa-logo"><a href="javascript:void(0);"><img th:src="@{/workbench/img/logo.png}"></a><h1>协同办公平台</h1></div>
<div class="gtoa-top-tab">
<ul class="clearfix">
<li class="top-tab-oa" th:classappend="${_type} eq 'oa'?'on':''">
<a href="javascript:;">办公审批</a>
<em class="left-radius"></em>
<em class="right-radius"></em>
<div class="header-bottom-line"></div>
</li>
<li class="top-tab-tz" th:if="!${isextendnet}" >
<a href="javascript:;">投资决策</a>
<em class="left-radius"></em>
<em class="right-radius"></em>
<div class="header-bottom-line"></div>
</li>
<li class="top-tab-law" th:if="!${isextendnet}" th:classappend="${_type} eq 'law'?'on':''">
<a href="javascript:;" >法律管理</a>
<em class="left-radius"></em>
<em class="right-radius"></em>
<div class="header-bottom-line"></div>
</li>
<li class="top-tab-supervise" th:if="!${isextendnet}" th:classappend="${_type} eq 'db'?'on':''">
<a href="javascript:;">督办管理</a>
<em class="left-radius"></em>
<em class="right-radius"></em>
<div class="header-bottom-line"></div>
</li>
<!-- <li class="top-tab-actsupervise" th:if="!${isextendnet}" th:classappend="${_type} eq 'act'?'on':''">
<a href="javascript:;">三年行动落实</a>
<em class="left-radius"></em>
<em class="right-radius"></em>
<div class="header-bottom-line"></div>
</li> -->
<li class="top-tab-medicine" th:if="!${isextendnet}">
<a href="javascript:;" >资产管理</a>
<em class="left-radius"></em>
<em class="right-radius"></em>
<div class="header-bottom-line"></div>
</li>
<li class="top-tab-bf" th:if="${!isextendnet && user.companyId =='164394'}" th:classappend="${_type} eq 'bf'?'on':''">
<a href="javascript:;" >业财管理</a>
<em class="left-radius"></em>
<em class="right-radius"></em>
<div class="header-bottom-line"></div>
</li>
</ul>
</div>
<div class="gtoa-setting-box">
<div class="gtoa-old-version-btn">
<a href="javascript:void(0)">
<i class="fa fa-cog"></i><span>设置</span>
</a>
<ul>
<li>
<a href="javascript:jumpChangelog()">
<i class="fa fa-bell-o"></i><span>更新日志</span>
</a>
</li>
<li>
<a th:href="${'http://172.30.201.204' +'/jsp/indexpage/main.jsp?portal=true&old_sys=true&userid='+oldUserId}">
<i class="fa fa-refresh"></i><span>切回旧版</span>
</a>
</li>
<li th:if="${environment =='intranet' && ishasAccount=='true'}">
<a href="http://oa.sdic.com.cn">
<i class="fa fa-power-off"></i><span>切换身份</span>
</a>
</li>
<li th:if="${environment =='intranet' && ishasAccount=='false'}">
<a href="javascript:closePage()">
<i class="fa fa-power-off"></i><span>退出</span>
</a>
</li>
<li th:if="${environment !='intranet'}">
<a th:href="@{/logout}">
<i class="fa fa-power-off"></i><span>退出</span>
</a>
</li>
</ul>
</div>
</div>
<div class="gtoa-login-status">
<div class="gtoa-login-name"><span th:text="${user.userName}"></span></div>
<div class="gtoa-login-position">
<p><span th:text="${user.deptName}">部门名称</span></p>
<em class="gtoa-positon-select" th:if="${user.depts !=null && user.depts.size() > 1}"><img th:src="@{/workbench/img/icon-down.png}"></em>
<ul>
<li th:each="d:${user.depts}">
<a href="javascript:;" th:data-id="${d.deptId}" th:data-number="${d.deptNumber}" th:title="${d.note}" th:text="${d.note}">用户部门</a>
</li>
</ul>
</div>
</div>
</div>
<div class="gtoa-left-menu">
<ul class="gtoa-menu-list">
<li class="on">
<a href="javascript:;" data-url="workbench/index" data-type="M" class="menuItem">
<i class="fa fa-home"></i><span>协同首页</span>
</a>
</li>
<li th:data-id="${menu.menuId}" th:each="menu:${menus}">
<a href="javascript:void(0);" class="menuItem" th:data-url="${menu.url}" th:data-id="${menu.menuId}"
th:data-type="${menu.menuType}" th:title="${menu.menuName}">
<i th:class="${'fa '+ menu.icon}"></i>
<span th:text="${menu.menuName}">模块名称</span>
</a>
<div class="gtoa-submenu" th:if="${not #lists.isEmpty(menu.children)}">
<dl>
<dd th:each="cmenu : ${menu.children}">
<a href="javascript:void(0);" class="menuItem" th:data-url="${cmenu.url}" th:title="${cmenu.menuName}" th:data-id="${cmenu.menuId}" th:data-type="${cmenu.menuType}">
<i></i><span th:text="${cmenu.menuName}">模块名称</span>
</a>
</dd>
</dl>
</div>
</li>
</ul>
<a href="javascript:;" class='gtoa-slide-btn'>
<img th:src="@{/workbench/img/icon-left-btn.png}" class="gtoa-left-btn">
<img th:src="@{/workbench/img/icon-right-btn.png}" class="gtoa-right-btn">
</a>
</div>
<div class="gtoa-container">
<div class="gtoa-container-tab hide-tab">
<div class="tabs-name pull-left" data-id="main"><span></span></div>
<div class="tabs-items pull-right"></div>
</div>
<!-- <div class="row mainContent" id="content-main"> -->
<iframe th:src="@{/workbench/index}" frameborder="0" class="gtoa-iframe sino_iframe" name="iframe0" width="100%" height="100%" th:data-id="@{/system/main}"></iframe>
<!-- </div> -->
</div>
<!-- 20190627-- 柳枝动画 -->
<div class="salix-animate">
<img th:src="@{/workbench/img/salix/salix-03.png}" class="salix salix-3">
<img th:src="@{/workbench/img/salix/salix-01.png}" class="salix salix-1">
<img th:src="@{/workbench/img/salix/salix-02.png}" class="salix salix-2">
</div>
<div class="salix-close" title="隐藏柳枝动画">
<i class="fa fa-times-circle-o"></i>
</div>
<script th:src="@{/workbench/js/oa-common.js}"></script>
</body> </body>
</html> </html>
\ No newline at end of file
<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0,maximum-scale=1.0,user-scalable=no">
<meta http-equiv="X-UA-Compatible" content="ie=Edge,chrome=1">
<title>首页</title>
<script th:inline="javascript"> var ctx = [[@{/}]]; </script>
<link rel="shortcut icon" th:href="@{/favicon.ico}">
<link rel="bookmark" th:href="@{/favicon.ico}">
<link rel="stylesheet" th:href="@{/css/font-awesome.min.css}">
<link rel="stylesheet" th:href="@{/css/bootstrap.min.css?v=3.3.6}">
<script th:src="@{/js/jquery.min.js}"></script>
<script th:src="@{/js/bootstrap.min.js}"></script>
<script th:src="@{/js/plugins/layer/layer.js?v=2.4}"></script>
<script th:src="@{/workbench/js/index.js}"></script>
<script th:src="@{/js/platform.js}"></script>
<script th:src="@{/ajax/libs/blockUI/jquery.blockUI.js}"></script>
<link rel="stylesheet" th:href="@{/workbench/css/index.css}">
<style type="text/css">
.list-used-info {
height: auto !important;
padding: .5rem .2rem 0;
}
.comment-used-info {
font-size: 1.1rem;
color: red;
padding-top: .5rem;
display: inline-block;
}
.unimportant-tips {
display: flex;
flex-wrap: wrap;
}
.unimportant-tips .done {
flex-basis: 20rem;
margin-bottom: 2rem;
margin-top: .7rem;
flex-grow: 1;
}
.unimportant-tips .login {
flex-basis: 28rem;
flex-grow: 1;
}
</style>
</head>
<body class="gt-body default-white">
<div class="row gt-row">
<div class="col-lg-8 col-md-7" style="padding-bottom: 25px;">
<div class="gt-waitdo">
<ul class="gt-waitdo-group">
<li class="gt-waitdo-item gtoa-to-do on">
<p>待办<i class="fa fa-hourglass"></i><em class="number-do number-left number-other"></em></p>
<div class="gtoa-document-floating">
<div class="gt-i-title do">
<div class="gt-swtich">
<a href="javascript:;" data-type='todo' class="on" onclick="switchingSystem('local')">
协同办公系统<span class="label number-do number-do-top"></span>
</a>
<a href="javascript:;" class="t-line">|</a>
<a href="javascript:;" data-type='do-other' onclick="switchingSystem('old')">
其他系统
<span class="label number-other number-other-top"></span>
</a>
</div>
<div class="gt-i-btn">
<a href="javascript:;" id="moreList" onclick="$.win.open(ctx+'portal/msg/list_read/todo','待办信息列表',['80%','80%'],false,true);"><i class="fa fa-list"></i>更多</a>
</div>
</div>
<div class="gt-waitdo-body list-do list-other">
<ul class="list-group">
<a class="list-group-item gt-list-item">
<span class="gt-list-type">类别</span>
<div class="gt-list-body">
<h3 class=""></h3>
<span class="label label-danger"></span><span></span><span class="pull-right"></span>
</div>
</a>
</ul>
</div>
</div>
</li>
<li class="gt-waitdo-item gtoa-to-read">
<p>待阅<i class="fa fa-file-text"></i><em class="number-read"></em></p>
<div class="gtoa-document-floating to-read">
<div class="gt-i-title read">
<h3 class="title-read">您有<b class="number-read"></b>条待阅需要处理</h3>
<div class="gt-i-btn">
<a href="javascript:;" th:onclick="index.toberead()"><i class="fa fa-refresh"></i>刷新</a>
<a href="javascript:;" onclick="$.win.open(ctx+'portal/msg/list_read/toberead','待阅信息列表',['80%','80%'],false,true);"><i class="fa fa-list"></i>更多</a>
</div>
</div>
<div class="gt-waitdo-body list-read">
<ul class="list-group"></ul>
</div>
</div>
</li>
<li class="gt-waitdo-item gtoa-meeting">
<p style="margin-left: 10px;width: 80px;">会议活动<i class="fa fa-users"></i><em class="number-meet"></em></p>
<div class="gtoa-document-floating meeting">
<div class="gt-i-title meet">
<h3 class="title-meet">您有<b class="number-meet"></b>条会议需要处理</h3>
<div class="gt-i-btn">
<a href="javascript:;" th:onclick="index.load('meet')"><i class="fa fa-refresh"></i>刷新</a>
<a href="javascript:;" th:onclick="index.open('/jsp/module/sdic/meeting/MeetInfoList.jsp?listType=yaochajia&portal=true')"><i class="fa fa-list"></i>更多</a>
</div>
</div>
<div class="gt-waitdo-body list-meet">
<ul class="list-group" style="margin-bottom:0px"></ul>
</div>
</div>
</li>
</ul>
</div>
<div class="gtoa-draft">
<div class="gt-i-title draft">
<h3><i class="fa fa-pencil"></i>我要起草</h3>
<div class="gt-i-btn">
<a href="javascript:;" class="gtoa-quick-btn" data-type="refresh"><i class="fa fa-refresh"></i>刷新</a>
<a href="javascript:;" class="gtoa-quick-btn" data-type="draft"><i class="fa fa-cog"></i>设置</a>
</div>
</div>
<div class="gt-draft-container">
<div class="row">
<div class="col-xs-4" >
<div class="gt-draft-item m1">
<a href="javascript:;" class="gt-draft-conner"></a>
<div class="gt-draft-title"><span class="gt-draft-mark t1">签报<i class="fa fa-angle-right"></i></span></div>
<ul class="gt-draft draft-SC-QB"></ul>
</div>
</div>
<div class="col-xs-4">
<div class="gt-draft-item m2">
<a href="javascript:;" class="gt-draft-conner"></a>
<div class="gt-draft-title"><span class="gt-draft-mark t2">收发文<i class="fa fa-angle-right"></i></span></div>
<ul class="gt-draft draft-SC-SF"></ul>
</div>
</div>
<div class="col-xs-4">
<div class="gt-draft-item m3">
<a href="javascript:;" class="gt-draft-conner"></a>
<div class="gt-draft-title"><span class="gt-draft-mark t3">会议纪要<i class="fa fa-angle-right"></i></span></div>
<ul class="gt-draft draft-SC-HYJY"></ul>
</div>
</div>
</div>
<div class="row" style="margin-top:20px;">
<div class="col-xs-6" >
<div class="gt-draft-item m4">
<a href="javascript:;" class="gt-draft-conner"></a>
<div class="gt-draft-title" style="width:35%"><span class="gt-draft-mark t4">日常<i class="fa fa-angle-right"></i></span></div>
<ul class="gt-draft p50 draft-SC-DAILY"></ul>
</div>
</div>
<div class="col-xs-6">
<div class="gt-draft-item m5">
<a href="javascript:;" class="gt-draft-conner"></a>
<div class="gt-draft-title" style="width:35%"><span class="gt-draft-mark t5">其他<i class="fa fa-angle-right"></i></span></div>
<ul class="gt-draft p50 draft-SC-OTHER"></ul>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="col-lg-4 col-md-5" th:if="!${isextendnet}">
<!-- 已办、已阅开始 -->
<div class="gtoa-read" th:if="${not #strings.startsWith(deptHistoryId,'001043') && not #strings.startsWith(deptHistoryId,'001082019')}">
<div class="gt-i-title draft">
<div class="gt-matter">
<a href="javascript:;" data-type='done-matter' class="on" onclick="matterChange('done')">
<i class="fa fa-calendar-check-o on"></i>已办事项
</a>
<a href="javascript:;" class="t-line">|</a>
<a href="javascript:;" data-type='read-matter' onclick="matterChange('read')">
<i class="fa fa-calendar-check-o"></i>已阅事项
</a>
</div>
<div class="gt-i-btn">
<a href="javascript:;" id="matterList" class="gtoa-read-btn" data-type="more" onclick="$.win.open(ctx+'portal/msg/list_read/done','已办信息列表',['80%','80%']);"><i class="fa fa-cog"></i>更多</a>
</div>
</div>
<div class="gtoa-quick-list">
<ul style="height:618px;margin-top:10px;"></ul>
</div>
</div>
<!-- 快捷方式开始 -->
<div class="gtoa-quick" th:if="${#strings.startsWith(deptHistoryId,'001043') || #strings.startsWith(deptHistoryId,'001082019')}">
<div class="gt-i-title draft">
<h3><i class="fa fa-link"></i>快捷方式</h3>
<div class="gt-i-btn">
<a href="javascript:;" class="gtoa-quick-btn" data-type="shortcut"><i class="fa fa-cog"></i>更多</a>
</div>
</div>
<div class="gtoa-quick-list">
<ul class="clearfix"></ul>
</div>
</div>
<div class="gtoa-deal-race unimportant-tips">
<div class="done">
<h3 th:text="${#dates.format(new java.util.Date().getTime(), 'yyyy年MM月dd日')}">2019年05月21日</h3>
<p>您共处理了<b id="fileCount"></b>个文件</p>
</div>
<div class="login">
<ul class="list-used-info">
<li>当前在线人数:<span th:text="${onlineNow}">当前在线人数</span></li>
<li>系统日访问量:<span th:text="${loginTimesToday}">系统当天访问次数(所有人)</span></li>
<li>系统总访问量:<span th:text="${loginTimesAll}">系统总登录次数(所有人)</span></li>
</ul>
<hr style="margin: 0;">
<span class="comment-used-info">
因为Http协议的特性,统计数据与实际情况可能存在出入。
</span>
</div>
</div>
</div>
</div>
<input type="hidden" id="oa_location" name="oa_location" th:value="${ip}" />
<input type="hidden" id="oa_userid" name="oa_userid" th:value="${oldUserId}" />
<input type="hidden" id="loginName" name="loginName" th:value="${loginName}" />
<input type="hidden" id="password" name="password" th:value="${password}" />
<input type="hidden" id="oa_deptid" name="oa_deptid" th:value="${deptHistoryId}" />
</div>
<script th:inline="javascript">
var oa_location = [[${oa_location}]];
window.onload = function(){
window.addEventListener("message", receiveMessage, false);
}
window.onmessage = function(message){
window.addEventListener("message", receiveMessage, false)
}
window.addEventListener("message", receiveMessage, false);
$(function(){
index.init([[${#strings.startsWith(deptHistoryId,'001043')}]] || [[${#strings.startsWith(deptHistoryId,'001041')}]] || [[${#strings.startsWith(deptHistoryId,'001082019')}]]);
});
//window.addEventListener("message", receiveMessage, false)
function receiveMessage(event) {
var origin = event.origin || event.originalEvent.origin;
deleteMessageByRecordId(event.data);
}
function deleteMessageByRecordId(recordid){
$.get(ctx +"portal/msg/delMessageByRecordid?recordid="+recordid+"&_time="+(Math.random()*60),function(res){
console.log("---------------------------"+res);
setTimeout(reload,500);
});
}
//兼容旧系统的刷新功能
function reloadtop(){
window.location.reload();
}
//兼容旧系统刷新待阅功能
function reloaddy(){
window.location.reload();
}
//首页待办更多事件
function switchingSystem(type){
if(type=="local"){
$("#moreList").attr("onclick","$.win.open(ctx+'portal/msg/list_read/todo','待办信息列表',['80%','80%'],false,true);");
}else if(type=="old"){
$("#moreList").attr("onclick","index.open('/jsp/module/extenddb/extenddb_list.jsp?1=1')");
}
}
//首页已办、已阅更多事件
function matterChange(type){
if(type=="done"){
$("#matterList").attr("onclick","$.win.open(ctx+\"portal/msg/list_read/done\",'已办信息列表',['80%','80%']);");
}else if(type=="read"){
$("#matterList").attr("onclick","$.win.open(ctx+\"portal/msg/list_read/read\",'已阅信息列表',['80%','80%']);");
}
}
function reloadthird(){
index.load('do-other',true);
}
function reload(){
$(['do','read','meet']).each(function(i,n){
index.load(n,true);
});
}
</script>
</body>
</html>
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:web="http://java.sun.com/xml/ns/javaee"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
</web-app>
<%@ page language="java" contentType="text/html;charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<meta http-equiv="refresh" content="0;url=${pageContext.request.contextPath}/login">
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment