diff --git a/.babelrc b/.babelrc
new file mode 100644
index 0000000..cca6759
--- /dev/null
+++ b/.babelrc
@@ -0,0 +1,33 @@
+{
+ "presets": [
+ [
+ "env",
+ {
+ "targets": {
+ "browsers": [
+ "ie>=8",
+ "chrome>=49"
+ ]
+ },
+ "loose": true,
+ "modules": false,
+ "debug": false,
+ "uglify": false,
+ "useBuiltIns": true
+ }
+ ],
+ "es2015-loose",
+ "stage-0"
+ ],
+ "plugins": [
+ [
+ "transform-runtime",
+ {
+ "corejs": false,
+ "helpers": false,
+ "polyfill": false,
+ "regenerator": true
+ }
+ ]
+ ]
+}
diff --git a/.eslintrc.js b/.eslintrc.js
index 816ba7b..9a8eff3 100644
--- a/.eslintrc.js
+++ b/.eslintrc.js
@@ -1,41 +1,33 @@
// https://eslint.org/docs/user-guide/configuring
// const rules = require('./eslint/rules');
module.exports = {
- root: true,
- parser: "babel-eslint",
- parserOptions: {
- ecmaVersion: 6,
- sourceType: 'module',
- },
- env: {
- browser: true,
- // mocha: true,
- es6: true,
- node: true,
- amd: true,
- // jasmine: false
- },
- globals: {
- describe: false,
- it: false,
- afterEach:false
- },
- extends: [
- // https://github.com/vuejs/eslint-plugin-vue#priority-a-essential-error-prevention
- // consider switching to `plugin:vue/strongly-recommended` or `plugin:vue/recommended` for stricter rules.
- // 'plugin:vue/essential',
- // https://github.com/standard/standard/blob/master/docs/RULES-en.md
- 'eslint:recommended',
- 'djcps'
- ],
- // required to lint *.vue files
- plugins: [
- "html",
- "import",
- "json",
- "node",
- "promise"
- ],
- // add your custom rules here
- rules: {}
+ root: true,
+ env: {
+ browser: true,
+ node: true
+ },
+ globals: {
+ describe: false,
+ it: false,
+ afterEach: false,
+ 'jQuery': true,
+ '$': true,
+ 'layui': true
+ },
+ extends: [
+ // https://github.com/vuejs/eslint-plugin-vue#priority-a-essential-error-prevention
+ // consider switching to `plugin:vue/strongly-recommended` or `plugin:vue/recommended` for stricter rules.
+ // 'plugin:vue/essential',
+ // https://github.com/standard/standard/blob/master/docs/RULES-en.md
+ 'eslint:recommended',
+ 'djcps'
+ ],
+ plugins: [
+ "html",
+ "json",
+ "node",
+ "promise"
+ ],
+ // add your custom rules here
+ rules: {}
};
diff --git a/.gitignore b/.gitignore
index c70eda9..73485f9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,5 +2,5 @@ node_modules
package-lock.json
.idea
temp_views
-src/compileViews
dist
+/bin/config/dev.config.js
diff --git a/.postcssrc.js b/.postcssrc.js
new file mode 100644
index 0000000..eee3e92
--- /dev/null
+++ b/.postcssrc.js
@@ -0,0 +1,10 @@
+// https://github.com/michael-ciniawsky/postcss-load-config
+
+module.exports = {
+ "plugins": {
+ "postcss-import": {},
+ "postcss-url": {},
+ // to edit target browsers: use "browserslist" field in package.json
+ "autoprefixer": {}
+ }
+}
diff --git a/app.js b/app.js
deleted file mode 100644
index dfbbdcb..0000000
--- a/app.js
+++ /dev/null
@@ -1,74 +0,0 @@
-const createError = require('http-errors');
-const express = require('express');
-const path = require('path');
-const logger = require('morgan');
-const cookieParser = require('cookie-parser');
-const bodyParser = require('body-parser');
-const merge = require('webpack-merge');
-const sysConfig = require('./sysConfig');
-const routes = require('./routes/index');
-
-// 代理插件
-const proxy = require('http-proxy-middleware');
-const cors = require('cors');
-
-const app = express();
-// todo cors将设置access-control-allow-origin:*,解决跨域问题( express proxy)
-app.use(cors());
-
-// view engine setup
-const {artTemplateOption} = require('./lib/art-template.js');
-app.engine('.html', require('express-art-template'));
-app.set('view options', merge(artTemplateOption, {
- //todo 配置项确定
- extname: '.html'
-}));
-
-app.set('views', path.join(__dirname, sysConfig.dev.tplPath));
-// uncomment after placing your favicon in /public
-// app.use(favicon(path.join(__dirname, 'public', 'favicon.ico')))
-
-app.use(logger('dev'));
-app.use(bodyParser.json());
-app.use(bodyParser.urlencoded({extended: false}));
-app.use(cookieParser());
-app.use(sysConfig.dev.publicPath, express.static(sysConfig.dev.outPutPath));
-// app.use(sysConfig.dev.publicPath, express.static(path.join(__dirname, 'dist/static')));
-
-app.use('/', routes);
-
-//ignore favicon.ico request
-app.use(function (req, res, next) {
- if (req.url === '/favicon.ico') {
- console.log('ignore');
- } else {
- console.log(req.url);
- res.end();
- }
-});
-
-// 设置代理
-app.use('/dj_server', proxy({
- // target: 'https://api.douban.com/',
- target: 'http://localhost:3999',
- pathRewrite: {'^/dj_server': ''},
- changeOrigin: true
-}));
-
-// catch 404 and forward to error handler
-app.use(function (req, res, next) {
- next(createError(404));
-});
-
-// error handler
-app.use(function (err, req, res, next) {
- // set locals, only providing error in development
- res.locals.message = err.message;
- res.locals.error = req.app.get('env') === 'development' ? err : {};
-
- // render the error page
- res.status(err.status || 500);
- res.render('error');
-});
-
-module.exports = app;
diff --git a/app_temp.js b/app_temp.js
deleted file mode 100644
index 43035e7..0000000
--- a/app_temp.js
+++ /dev/null
@@ -1,152 +0,0 @@
-const express = require('express');
-const fs = require('fs');
-require('shelljs/global');
-const path = require('path');
-const logger = require('morgan');
-const cookieParser = require('cookie-parser');
-const bodyParser = require('body-parser');
-const merge = require('webpack-merge');
-const sysConfig = require('./sysConfig');
-const routes = require('./routes/index');
-
-// 代理插件
-const proxy = require('http-proxy-middleware');
-const cors = require('cors');
-
-const app = express();
-const isDev = app.get('env') === 'development';
-
-// todo cors将设置access-control-allow-origin:*,解决跨域问题( express proxy)
-app.use(cors());
-
-// view engine setup
-const {artTemplateOption} = require('./lib/art-template.js');
-app.engine('.html', require('express-art-template'));
-app.set('view options', merge(artTemplateOption, {
- //todo 配置项确定
- extname: '.html'
-}));
-
-app.set('views', path.join(__dirname, sysConfig.dev.tplPath));
-// uncomment after placing your favicon in /public
-// app.use(favicon(path.join(__dirname, 'public', 'favicon.ico')))
-
-app.use(logger('dev'));
-app.use(bodyParser.json());
-app.use(bodyParser.urlencoded({extended: false}));
-app.use(cookieParser());
-app.use(sysConfig.dev.publicPath, express.static(sysConfig.dev.outPutPath));
-// app.use(sysConfig.dev.publicPath, express.static(path.join(__dirname, 'dist/static')));
-
-app.use('/', routes);
-
-//ignore favicon.ico request
-app.use(function (req, res, next) {
- if (req.url === '/favicon.ico') {
- console.log('ignore');
- } else {
- console.log(req.url);
- res.end();
- }
-});
-
-// 设置代理
-app.use('/dj_server', proxy({
- // target: 'https://api.douban.com/',
- target: 'http://localhost:3999',
- pathRewrite: {'^/dj_server': ''},
- changeOrigin: true
-}));
-
-// catch 404 and forward to error handler
-app.use(function (req, res, next) {
- const err = new Error('Not Found');
- err.status = 404;
- next(err);
-});
-
-// error handlers
-
-// development error handler
-// will print stacktrace
-if (isDev) {
- app.use(function (err, req, res, next) {
- res.status(err.status || 500);
- console.log(err);
- res.render('error', {
- message: err.message,
- error: err
- });
- });
-} else {
- // production error handler
- // no stacktraces leaked to user
- app.use(function (err, req, res, next) {
- res.status(err.status || 500);
- res.render('error', {
- message: err.message,
- error: {}
- });
- });
-}
-
-if (isDev) {
- const serverPort = 25999;
- const webpack = require('webpack');
- const webpackDevMiddleware = require('webpack-dev-middleware');
- const webpackHotMiddleware = require('webpack-hot-middleware');
- const webpackDevConfig = require('./webpack.temp.config.js');
-
- const compiler = webpack(webpackDevConfig);
-
- app.use(webpackDevMiddleware(compiler, {
- publicPath: webpackDevConfig.output.publicPath,
- noInfo: true,
- stats: {
- colors: true
- }
- }));
- app.use(webpackHotMiddleware(compiler));
-
- // browsersync is a nice choice when modifying only views (with their css & js)
- const bs = require('browser-sync').create();
- app.listen(sysConfig.dev.port, function () {
- bs.init({
- open: false,
- ui: false,
- notify: false,
- proxy: 'localhost:' + sysConfig.dev.port,
- files: ['./src/views/**'],
- serverPort: serverPort
- });
- console.log(`App (dev) is going to be running on port ${serverPort} (by browsersync).`);
- });
-
- var viewPath = path.join(__dirname, sysConfig.dev.tplPath);
- rm('-rf', viewPath);
- // 在源码有更新时,更新模板
- compiler.plugin('emit', function (compilation, cb) {
- // console.log('compilation.assets = ', compilation.assets);
- for (var filename in compilation.assets) {
- if (filename.endsWith('.html')) {
- let filepath = path.resolve(viewPath, filename);
- let dirname = path.dirname(filepath);
- if (!fs.existsSync(dirname)) {
- mkdir('-p', dirname);
- }
- // console.log('compilation.assets[filename].source() = ', compilation.assets[filename].source());
- fs.writeFile(filepath, compilation.assets[filename].source(), (err) => {
- if (err) throw err;
- });
- }
- }
- cb();
- });
-} else {
- app.use(express.static(path.join(__dirname, 'public')));
- app.listen(sysConfig.dev.port, function () {
- console.log(`App (production) is now running on port ${sysConfig.dev.port}!`);
- });
-}
-
-module.exports = app;
diff --git a/build/compile_node/compile-art-template.js b/bin/build/compile-art-template.js
similarity index 60%
rename from build/compile_node/compile-art-template.js
rename to bin/build/compile-art-template.js
index bb3524d..26817df 100644
--- a/build/compile_node/compile-art-template.js
+++ b/bin/build/compile-art-template.js
@@ -1,25 +1,21 @@
-// const artTemplate = require('art-template')
-const path = require('path');
-const {artTemplateRenderFn} = require('../../lib/art-template');
+const {artTemplateRenderFn} = require('./lib/art-template');
const fs = require('fs');
-const common = require('../common');
-const rootPath = path.join(__dirname, '../../');
-const glob = require('glob');
-var sysConfig = require('../../sysConfig');
-
+const utils = require('./utils');
+const files = require('../config/files');
require('shelljs/global');
const webTile = '各个页面统一title';
+// todo renderData 存到其他地方(node服务器?)
let renderData = {
- 'index.html': {
+ 'index': {
title: '首页 - ' + webTile,
pageNav: 'index'
},
- 'about.html': {
+ 'about': {
title: '首页 - ' + webTile,
pageNav: 'about'
},
- 'error.html': {
+ 'error': {
title: '错误 - ' + webTile,
message: '错误message',
error: {
@@ -30,8 +26,9 @@ let renderData = {
};
//html模板所在页面
-const tempaltePath = 'dist/' + sysConfig.dev.tplPath + '/';
-const outPutPath = 'dist/';
+const tempaltePath = files.tplPath;
+// 'dist/'
+const outPutPath = files.buildPath;
// rm('-rf', path.join(rootPath, outPutPath));
/**
* node端html模板渲染函数
@@ -41,8 +38,9 @@ const outPutPath = 'dist/';
* @returns {*}
*/
let nodeRenderFn = function (htmlToString, renderData, options) {
+ // todo layui标签模板引入时,会被编译
return artTemplateRenderFn(htmlToString, renderData, Object.assign({}, {
- root: rootPath + tempaltePath,
+ root: tempaltePath,
extname: '.html'
// imports: {
// outSide: function (name) {
@@ -51,25 +49,27 @@ let nodeRenderFn = function (htmlToString, renderData, options) {
// }
}, options));
};
-const entries = common.getEntry(path.join(rootPath, tempaltePath + '*.html'), path.join(rootPath, tempaltePath));
+const entries = utils.getEntry(tempaltePath + '/*.html', tempaltePath + '/', (value) => {
+ return value;
+});
for (let item of Object.keys(entries)) {
- console.log('item = ', item);
- console.log('entries(item) = ', entries[item]);
let filePath = entries[item];
fs.readFile(filePath, function (e, v) {
let ret = v.toString();
const template = nodeRenderFn(ret, renderData[item]);
- let dirname = path.join(rootPath, outPutPath);
+ let dirname = outPutPath;
if (!fs.existsSync(dirname)) {
mkdir('-p', dirname);
}
- fs.writeFile(path.join(rootPath, outPutPath + item), template, function (err) {
+ const file_html = `${outPutPath}/${item}.html`;
+ fs.writeFile(file_html, template, function (err) {
+ console.log('build ----- ', file_html);
if (err) throw err;
});
}
);
}
-// rm('-rf', path.join(rootPath, tempaltePath));
+// rm('-rf', tempaltePath);
diff --git a/lib/art-template.js b/bin/build/lib/art-template.js
similarity index 100%
rename from lib/art-template.js
rename to bin/build/lib/art-template.js
diff --git a/lib/tools.js b/bin/build/lib/tools.js
similarity index 100%
rename from lib/tools.js
rename to bin/build/lib/tools.js
diff --git a/build/utils.js b/bin/build/utils.js
similarity index 60%
rename from build/utils.js
rename to bin/build/utils.js
index 10aa763..124e619 100644
--- a/build/utils.js
+++ b/bin/build/utils.js
@@ -1,7 +1,9 @@
'use strict';
const path = require('path');
-const config = require('../sysConfig');
+const config = require('../config/index');
const ExtractTextPlugin = require('extract-text-webpack-plugin');
+const glob = require('glob');
+const files_config = require('../config/files');
// const packageConfig = require('../package.json');
/**
@@ -16,6 +18,7 @@ exports.assetsPath = function (_path) {
return path.posix.join(assetsSubDirectory, _path);
};
+
exports.cssLoaders = function (options) {
options = options || {};
@@ -35,9 +38,8 @@ exports.cssLoaders = function (options) {
// generate loader string to be used with extract text plugin
function generateLoaders(loader, loaderOptions) {
- // todo 暂时移除postcssLoader
- // const loaders = options.usePostCSS ? [cssLoader, postcssLoader] : [cssLoader];
- const loaders = [cssLoader];
+ const loaders = options.usePostCSS ? [cssLoader, postcssLoader] : [cssLoader];
+ // const loaders = [cssLoader];
if (loader) {
loaders.push({
loader: loader + '-loader',
@@ -49,21 +51,21 @@ exports.cssLoaders = function (options) {
// Extract CSS when that option is specified
// (which is the case during production build)
- // if (options.extract) {
+ if (options.extract) {
return ExtractTextPlugin.extract({
- use: loaders
- // fallback: 'vue-style-loader'
+ use: loaders,
+ fallback: 'style-loader'
});
- // } else {
- // return ['vue-style-loader'].concat(loaders);
- // }
+ } else {
+ return ['style-loader'].concat(loaders);
+ }
}
// https://vue-loader.vuejs.org/en/configurations/extract-css.html
return {
css: generateLoaders(),
// postcss: generateLoaders(),
- less: generateLoaders('less'),
+ less: generateLoaders('less')
// sass: generateLoaders('sass', {indentedSyntax: true}),
// scss: generateLoaders('sass'),
// stylus: generateLoaders('stylus'),
@@ -86,3 +88,31 @@ exports.styleLoaders = function (options) {
return output;
};
+
+/**
+ * 遍历项目文件,获取入口js,用于生成多页入口
+ * @param globPath
+ * @param pathDir
+ * @param formatFn 自定义内容格式
+ */
+exports.getEntry = function (globPath, pathDir, formatFn) {
+ // globPath = files_config.rootPath + globPath;
+ // pathDir = files_config.rootPath + pathDir;
+ const files = glob.sync(globPath);
+ const entries = {};
+ let {entry, dirname, basename, pathname, extname} = {};
+
+ for (let i = 0; i < files.length; i++) {
+ entry = files[i];
+ dirname = path.dirname(entry);
+ extname = path.extname(entry);
+ basename = path.basename(entry, extname);
+ pathname = path.normalize(path.join(dirname, basename));
+ pathDir = path.normalize(pathDir);
+ if (pathname.startsWith(pathDir)) {
+ pathname = pathname.substring(pathDir.length);
+ }
+ entries[pathname] = formatFn ? formatFn(entry) : [entry];
+ }
+ return entries;
+};
diff --git a/bin/build/webpack.base.conf.js b/bin/build/webpack.base.conf.js
new file mode 100644
index 0000000..69588cb
--- /dev/null
+++ b/bin/build/webpack.base.conf.js
@@ -0,0 +1,146 @@
+// 移除node开发环境,webpack警告
+process.noDeprecation = true;
+
+// const path = require('path');
+const webpack = require('webpack');
+const sysConfig = require('../config/index');
+const utils = require('./utils');
+
+const CommonsChunkPlugin = webpack.optimize.CommonsChunkPlugin;
+// const merge = require('webpack-merge');
+
+const Es3ifyPlugin = require('es3ify-webpack-plugin');
+const files = require('../config/files');
+const HtmlWebpackPlugin = require('html-webpack-plugin');
+const entries = utils.getEntry(files.appPath + '/scripts/page/**/*.js', files.appPath + '/scripts/page/');
+const chunks = Object.keys(entries);
+
+let webpackConfig = {
+ // entry: merge({
+ // // layui: `${files.staticPath}/lib/layui/layui.js`,
+ // // jquery: ['jquery']
+ // }, entries,
+ entry: entries,
+ output: {
+ path: files.buildPath,
+ filename: '[name].js',
+ publicPath: process.env.NODE_ENV === 'production'
+ ? sysConfig.build.assetsPublicPath
+ : sysConfig.dev.assetsPublicPath
+ },
+ resolve: {
+ extensions: ['.js']
+ },
+ externals: {
+ // 'layui': 'window.layui' // 使用时,依旧用require的方式来使用,webpack不会把它编译进文件里
+ },
+ module: {
+ rules: [
+ {
+ test: /\.js$/,
+ exclude: /(node_modules)/,
+ //include: path.join(projectDirname, 'src'),
+ include: [files.staticPath],
+ use: {
+ loader: 'babel-loader',
+ /*options: {
+ presets: ['env']
+ }*/
+ options: {
+ presets: ['env', 'es2015-loose']
+ //presets: ['env'],
+ //plugins: ['transform-runtime', 'proxy']
+ }
+ }
+ },
+ {
+ test: /\.html$/,
+ use: [{
+ loader: 'html-loader',
+ options: {
+ minimize: false
+ }
+ }]
+ },
+ {
+ test: /\.(png|jpe?g|gif|svg)(\?.*)?$/,
+ loader: 'url-loader',
+ options: {
+ limit: 10000,
+ name: utils.assetsPath('img/[name].[hash:7].[ext]')
+ }
+ },
+ {
+ test: /\.(mp4|webm|ogg|mp3|wav|flac|aac)(\?.*)?$/,
+ loader: 'url-loader',
+ options: {
+ limit: 10000,
+ name: utils.assetsPath('media/[name].[hash:7].[ext]')
+ }
+ },
+ {
+ test: /\.(woff2?|eot|ttf|otf)(\?.*)?$/,
+ loader: 'url-loader',
+ options: {
+ limit: 10000,
+ name: utils.assetsPath('fonts/[name].[hash:7].[ext]')
+ }
+ }
+ ]
+ },
+ plugins: [
+ new Es3ifyPlugin(),
+ // new webpack.ProvidePlugin({ // 加载jq
+ // // $: 'jquery'
+ // }),
+ // new webpack.ProvidePlugin({
+ // $: 'jquery',
+ // jQuery: 'jquery',
+ // 'window.jQuery': 'jquery'
+ // }),
+ new CommonsChunkPlugin({
+ name: 'vendors', // 将公共模块提取,生成名为`vendors`的chunk
+ chunks: chunks,
+ minChunks: chunks.length // 提取所有entry共同依赖的模块
+ })
+
+ ]
+};
+const html = utils.getEntry(files.htmlPath + '/**/*.html', files.htmlPath + '/');
+const pages = Object.keys(html);
+pages.forEach(function (pathname) {
+ pathname.replace('');
+ const conf = {
+ // filename: '../' + files.tplName + '/' + pathname + '.html', // 生成的html存放路径,相对于outPutPath
+ filename: `${files.tplPath}/${pathname}.html`, // 生成的html存放路径,相对于outPutPath
+ template: `${files.htmlPath}/${pathname}.html`, // html模板路径
+ inject: false // js插入的位置,true/'head'/'body'/false
+ /*
+ * 压缩这块,调用了html-minify,会导致压缩时候的很多html语法检查问题,
+ * 如在html标签属性上使用{{...}}表达式,很多情况下并不需要在此配置压缩项,
+ * 另外,UglifyJsPlugin会在压缩代码的时候连同html一起压缩。
+ * 为避免压缩html,需要在html-loader上配置'html?-minimize',见loaders中html-loader的配置。
+ */
+ // minify: { //压缩HTML文件
+ // removeComments: true, //移除HTML中的注释
+ // collapseWhitespace: false //删除空白符与换行符
+ // }
+ };
+ if (pathname in webpackConfig.entry) {
+ conf.favicon = files.faviconPath;
+ conf.inject = 'body';
+ conf.chunks = ['manifest', 'vendors', pathname];
+ // conf.chunks = ['vendors', 'jquery', pathname];
+ // conf.chunksSortMode = function (chunk1, chunk2) {
+ // // const order = ['vendors', 'jquery', 'layui', pathname];
+ // // const order1 = order.indexOf(chunk1.names[0]);
+ // // const order2 = order.indexOf(chunk2.names[0]);
+ // // return order1 - order2;
+ // // };
+ conf.chunksSortMode = 'manual';
+ conf.hash = true;
+ }
+ webpackConfig.plugins.push(new HtmlWebpackPlugin(conf));
+});
+
+module.exports = webpackConfig;
diff --git a/bin/build/webpack.dev.conf.js b/bin/build/webpack.dev.conf.js
new file mode 100644
index 0000000..420f431
--- /dev/null
+++ b/bin/build/webpack.dev.conf.js
@@ -0,0 +1,82 @@
+// 移除node开发环境,webpack警告
+process.noDeprecation = true;
+
+const webpack = require('webpack');
+const sysConfig = require('../config/index');
+const merge = require('webpack-merge');
+const files = require('../config/files');
+const utils = require('./utils');
+const CopyWebpackPlugin = require('copy-webpack-plugin');
+const baseWebpackConfig = require('./webpack.base.conf');
+
+let webpackConfig = merge(baseWebpackConfig, {
+ //ps:inline-source-map 其他方式(cheap-module-eval-source-map)压缩会导致开发环境在ie8下,编译异常 取消标识符,坑爹:注意webpack重启才能检验,忘记已经去除ie8 热更新了
+ devtool: 'inline-source-map',
+ module: {
+ rules: utils.styleLoaders({sourceMap: sysConfig.dev.cssSourceMap, usePostCSS: true})
+ },
+ plugins: [
+ new CopyWebpackPlugin([
+ {
+ from: files.staticPath,
+ to: sysConfig.dev.assetsSubDirectory,
+ ignore: ['.*']
+ }
+ ])
+ ]
+});
+
+// for (const key of Object.keys(webpackConfig.entry)) {
+// webpackConfig.entry[key].unshift("babel-polyfill");// 限制项目使用新语法,基础的兼容问题,采用meta注入js解决
+// }
+if (sysConfig.dev.screw_ie8) {
+ webpackConfig.plugins.push(
+ new webpack.HotModuleReplacementPlugin(),
+ new webpack.NamedModulesPlugin(), // HMR shows correct file names in console on update.
+ new webpack.NoEmitOnErrorsPlugin()
+ );
+}
+
+// if (sysConfig.dev.screw_ie8) {
+// // const hotMiddlewareScript = 'webpack-hot-middleware/client?reload=true';
+// const hotMiddlewareScript = 'webpack-dev-server/client?http://localhost:' + sysConfig.dev.serverPort;
+// for (const key of Object.keys(webpackConfig.entry)) {
+// webpackConfig.entry[key].unshift("babel-polyfill", hotMiddlewareScript, 'webpack/hot/dev-server');
+// }
+// webpackConfig.plugins.push(
+// new webpack.HotModuleReplacementPlugin(),
+// new webpack.NoEmitOnErrorsPlugin()
+// );
+// } else {
+// for (const key of Object.keys(webpackConfig.entry)) {
+// webpackConfig.entry[key].unshift("babel-polyfill");
+// }
+// }
+
+module.exports = webpackConfig;
+//todo
+// module.exports = new Promise((resolve, reject) => {
+// portfinder.basePort = process.env.PORT || config.dev.port
+// portfinder.getPort((err, port) => {
+// if (err) {
+// reject(err)
+// } else {
+// // publish the new Port, necessary for e2e tests
+// process.env.PORT = port
+// // add port to devServer config
+// devWebpackConfig.devServer.port = port
+//
+// // Add FriendlyErrorsPlugin
+// devWebpackConfig.plugins.push(new FriendlyErrorsPlugin({
+// compilationSuccessInfo: {
+// messages: [`Your application is running here: http://${devWebpackConfig.devServer.host}:${port}`],
+// },
+// onErrors: config.dev.notifyOnErrors
+// ? utils.createNotifierCallback()
+// : undefined
+// }))
+//
+// resolve(devWebpackConfig)
+// }
+// })
+// })
diff --git a/bin/build/webpack.prod.conf.js b/bin/build/webpack.prod.conf.js
new file mode 100644
index 0000000..00aef20
--- /dev/null
+++ b/bin/build/webpack.prod.conf.js
@@ -0,0 +1,131 @@
+// 移除node开发环境,webpack警告
+process.noDeprecation = true;
+
+const webpack = require('webpack');
+const sysConfig = require('../config/index');
+const files = require('../config/files');
+const merge = require('webpack-merge');
+const CopyWebpackPlugin = require('copy-webpack-plugin');
+const utils = require('./utils');
+const CleanWebpackPlugin = require('clean-webpack-plugin');
+const baseWebpackConfig = require('./webpack.base.conf');
+const ExtractTextPlugin = require('extract-text-webpack-plugin');
+const OptimizeCSSPlugin = require('optimize-css-assets-webpack-plugin');
+
+let webpackConfig = merge(baseWebpackConfig, {
+ output: {
+ path: files.buildPath,
+ filename: utils.assetsPath('js/[name].[chunkhash].js'),
+ chunkFilename: utils.assetsPath('js/[id].[chunkhash].js')
+ },
+ devtool: sysConfig.build.productionSourceMap ? '#source-map' : false,
+ module: {
+ rules: utils.styleLoaders({
+ sourceMap: sysConfig.build.productionSourceMap,
+ extract: true,
+ usePostCSS: true
+ })
+ },
+ plugins: [
+ new CleanWebpackPlugin(['dist'], {
+ root: files.rootPath,
+ verbose: true,
+ dry: false
+ }),
+ // new CleanWebpackPlugin(
+ // ['static'],
+ // {
+ // root: files.buildPath, //根目录
+ // verbose: true, //开启在控制台输出信息
+ // dry: false //启用删除文件
+ // }),
+ new ExtractTextPlugin({
+ filename: utils.assetsPath('css/[name].[contenthash].css'),
+ // Setting the following option to `false` will not extract CSS from codesplit chunks.
+ // Their CSS will instead be inserted dynamically with style-loader when the codesplit chunk has been loaded by webpack.
+ // It's currently set to `true` because we are seeing that sourcemaps are included in the codesplit bundle as well when it's `false`,
+ // increasing file size: https://github.com/vuejs-templates/webpack/issues/1110
+ allChunks: true
+ }),
+ // Compress extracted CSS. We are using this plugin so that possible
+ // duplicated CSS from different components can be deduped.
+ new OptimizeCSSPlugin({
+ cssProcessorOptions: sysConfig.build.productionSourceMap
+ ? {safe: true, map: {inline: false}}
+ : {safe: true}
+ }),
+ new webpack.optimize.UglifyJsPlugin({ // 压缩代码
+ output: {
+ // screw_ie8: false,
+ // beautify: true, //有正常的空格和断句,注释也会保留,
+ // comments: true,
+ // 最紧凑的输出
+ beautify: false,
+ // 删除所有的注释
+ comments: false,
+ quote_keys: true, //SCRIPT1048: 缺少标识符
+ keep_quoted_props: true // 是否保留对象字面量中的引号。
+ },
+ // screw_ie8: false,
+ compress: {
+ // screw_ie8: false,
+ // 在UglifyJs删除没有用到的代码时不输出警告
+ warnings: false,
+ properties: false,
+ // 删除所有的 `console` 语句,可以兼容ie浏览器
+ drop_console: true,
+ // 内嵌定义了但是只用到一次的变量
+ collapse_vars: true,
+ // 提取出出现多次但是没有定义成变量去引用的静态值
+ reduce_vars: true
+ },
+ mangle: {
+ eval: true,
+ screw_ie8: false, //是否把支持IE8的代码clear掉
+ except: ['$super', '$', 'exports', 'require'] // 排除关键字
+ }
+ // sourceMap: config.build.productionSourceMap // 打包到测试环境时,可开启,方便调试
+ }),
+ new CopyWebpackPlugin([
+ {
+ from: files.staticPath,
+ to: sysConfig.build.assetsSubDirectory,
+ ignore: ['.*']
+ }
+ ]),
+ // keep module.id stable when vendor modules does not change
+ new webpack.HashedModuleIdsPlugin(),
+ // enable scope hoisting 提升作用域 es module 中需要配合使用
+ new webpack.optimize.ModuleConcatenationPlugin(),
+ // extract webpack runtime and module manifest to its own file in order to
+ // prevent vendor hash from being updated whenever app bundle is updated
+ new webpack.optimize.CommonsChunkPlugin({
+ name: 'manifest',
+ minChunks: Infinity
+ })
+ ]
+});
+
+if (sysConfig.build.productionGzip) {
+ const CompressionWebpackPlugin = require('compression-webpack-plugin');
+
+ webpackConfig.plugins.push(
+ new CompressionWebpackPlugin({
+ asset: '[path].gz[query]',
+ algorithm: 'gzip',
+ test: new RegExp(
+ '\\.(' +
+ sysConfig.build.productionGzipExtensions.join('|') +
+ ')$'
+ ),
+ threshold: 10240,
+ minRatio: 0.8
+ })
+ );
+}
+if (sysConfig.build.bundleAnalyzerReport) {
+ const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
+ webpackConfig.plugins.push(new BundleAnalyzerPlugin());
+}
+
+module.exports = webpackConfig;
diff --git a/bin/config/dev.config.js b/bin/config/dev.config.js
new file mode 100644
index 0000000..f1262b7
--- /dev/null
+++ b/bin/config/dev.config.js
@@ -0,0 +1,5 @@
+module.exports = {
+ screw_ie8: true,
+ BASIC_URL: 'http://192.168.23.7:80',
+ WEBSOCKET_URL: 'ws://192.168.2.94:8080/djwmsservice'
+};
diff --git a/bin/config/files.js b/bin/config/files.js
new file mode 100644
index 0000000..f3f8659
--- /dev/null
+++ b/bin/config/files.js
@@ -0,0 +1,42 @@
+const path = require('path');
+/**
+ * 各类资源的路径,加入绝对路径保证各个层级的文件引用正常
+ */
+module.exports = ((filesName) => {
+ const files = filesName;
+ // const appPath = path.resolve(files.root, files.appName);
+ // files.appPath = appPath;
+
+ // files.dllPath = path.resolve(files.root, `${files.buildName}/dll`);
+ // files.jsPath = path.resolve(appPath, files.jsName);
+ // files.cssPath = path.resolve(appPath, files.cssName);
+ // files.imgPath = path.resolve(appPath, files.imgName);
+ // files.fontPath = path.resolve(appPath, files.fontName);
+ // files.viewPath = path.resolve(appPath, files.viewName);
+ // files.testPath = path.resolve(appPath, files.testName);
+ // files.htmlPath = path.resolve(appPath, files.htmlName);
+ // files.componentPath = path.resolve(appPath, files.componentName);
+ const rootPath = path.join(__dirname, '../../');
+ const appPath = path.resolve(rootPath, `src`);
+ files.appPath = appPath;
+ files.rootPath = rootPath;
+ files.staticPath = path.resolve(rootPath, files.staticName);
+ files.tplPath = path.resolve(rootPath, files.tplName);
+ files.buildPath = path.resolve(rootPath, files.buildName);
+ files.faviconPath = path.resolve(rootPath, files.faviconName);
+ files.htmlPath = path.resolve(appPath, files.htmlName);
+ return files;
+})({
+ // root: process.cwd(), // 根目录
+ faviconName: 'favicon.ico',
+ buildName: 'dist', // 打包文件
+ // componentName: 'component', // 公共组件文件
+ htmlName: 'views', // 视图文件
+ // cssName: 'source/css', // 公共样式文件
+ // fontName: 'source/font', // 公共字体文件
+ // imgName: 'source/img', // 公共图片文件
+ // jsName: 'source/js', // 公共脚本文件
+ staticName: 'static', // 静态资源包文件
+ tplName: 'temp_views', // 视图模板文件
+ testName: 'test' // 测试文件
+});
diff --git a/bin/config/index.js b/bin/config/index.js
new file mode 100644
index 0000000..4b6081f
--- /dev/null
+++ b/bin/config/index.js
@@ -0,0 +1,45 @@
+'use strict';
+let dev_config;
+try {
+ // 本地维护,不上传github
+ dev_config = require('./dev.config');
+} catch (e) {
+ dev_config = {};
+}
+module.exports = {
+ dev: {
+ cssSourceMap: true,
+ host: '0.0.0.0',
+ serverPort: 2082,
+ expressPort: 24999,
+ autoOpenBrowser: true,
+ assetsPublicPath: '/', // 'https://cdn.xxxxx.com', // 添加路径前缀,后续cdn扩展
+ assetsSubDirectory: 'static', //静态资源指向目录
+ // publicPath: '/static',
+ // tplPath: 'temp_views',
+ screw_ie8: dev_config.screw_ie8 || false
+ // outPutPath: path.join(__dirname, '../dist/static')
+ },
+
+ build: {
+ // Template for index.html
+ // index: path.resolve(__dirname, '../dist/index.html'),
+ //
+ // // Paths
+ // assetsRoot: path.resolve(__dirname, '../dist'),
+ assetsPublicPath: '/',
+ assetsSubDirectory: 'static', //静态资源指向目录
+ bundleAnalyzerReport: false, //会打断npm && npm 这类npm指令继续执行
+ // Gzip off by default as many popular static hosts such as
+ // Surge or Netlify already gzip all static assets for you.
+ // Before setting to `true`, make sure to:
+ // npm install --save-dev compression-webpack-plugin
+ productionGzip: true,
+ productionGzipExtensions: ['js', 'css'],
+
+ // publicPath: '/static',
+ // outPutPath: path.join(__dirname, '../dist/static'),
+ // tplPath: 'temp_views',
+ productionSourceMap: false
+ }
+};
diff --git a/bin/pathTest.js b/bin/pathTest.js
deleted file mode 100644
index 5c55843..0000000
--- a/bin/pathTest.js
+++ /dev/null
@@ -1,12 +0,0 @@
-var path = require('path');
-var sysConfig = require('../sysConfig')
-console.log('path.join(__dirname, \'dist/static\')' + ' = ', path.join(__dirname, '../dist/static'));
-console.log('path.resolve(__dirname, \'dist/static\')' + ' = ', path.resolve(__dirname, '../dist/static'));
-console.log('sysConfig' + ' = ', sysConfig.dev.assetsRoot,sysConfig.dev.publicPath);
-// let root = __dirname;
-// function log(Fn) {
-// console.log(Fn + ' = ', _eval(Fn, 'string', {path: path, __dirname: root}));
-// }
-//
-// log('path.join(__dirname, \'dist/static\')');
-// log('path.resolve(__dirname, \'dist/static\')');
diff --git a/bin/server/expressServer.js b/bin/server/expressServer.js
new file mode 100644
index 0000000..89629b1
--- /dev/null
+++ b/bin/server/expressServer.js
@@ -0,0 +1,90 @@
+const express = require('express');
+// const fs = require('fs');
+// require('shelljs/global');
+const logger = require('morgan');
+const cookieParser = require('cookie-parser');
+const bodyParser = require('body-parser');
+const merge = require('webpack-merge');
+const sysConfig = require('../config/index');
+const files = require('../config/files');
+const routes = require('./routes/index');
+
+// 代理插件
+const proxy = require('http-proxy-middleware');
+const cors = require('cors');
+
+const app = express();
+// const isDev = app.get('env') === 'development';
+
+//cors将设置access-control-allow-origin:*,解决跨域问题( express proxy)
+app.use(cors());
+
+// view engine setup
+const {artTemplateOption} = require('../build/lib/art-template.js');
+app.engine('.html', require('express-art-template'));
+app.set('view options', merge(artTemplateOption, {
+ extname: '.html'
+}));
+
+app.set('views', files.tplPath);
+// uncomment after placing your favicon in /public
+// app.use(favicon(path.join(__dirname, 'public', 'favicon.ico')))
+
+app.use(logger('dev'));
+app.use(bodyParser.json());
+app.use(bodyParser.urlencoded({extended: false}));
+app.use(cookieParser());
+
+// app.locals.env = process.env.NODE_ENV || 'dev';
+
+app.use('/', routes);
+
+// 设置代理
+app.use('/dj_server', proxy({
+ // target: 'https://api.douban.com/',
+ target: 'http://192.168.2.167:3999',
+ pathRewrite: {'^/dj_server': ''},
+ changeOrigin: true
+}));
+
+//ignore favicon.ico request
+app.use(function (req, res, next) {
+ res.writeHead(200, {
+ 'Content-Type': 'text/event-stream',
+ 'Cache-Control': 'no-cache',
+ 'Connection': 'keep-alive'
+ });
+ // if (req.url === '/favicon.ico') {
+ // console.log('ignore /favicon.ico');
+ // } else {
+ // res.end();
+ // }
+ res.end();
+});
+
+// catch 404 and forward to error handler
+app.use(function (req, res, next) {
+ const err = new Error('Not Found');
+ err.status = 404;
+ next(err);
+});
+
+// error handlers
+
+// development error handler
+// will print stacktrace
+app.use(function (err, req, res, next) {
+ res.status(err.status || 500);
+ console.log(err);
+ res.render('error', {
+ message: err.message,
+ error: err
+ });
+});
+
+const port = process.env.PORT || sysConfig.dev.expressPort;
+app.use(sysConfig.dev.assetsPublicPath, express.static(files.buildPath));
+// app.use(express.static(path.join(__dirname, 'public')));
+app.listen(port, function () {
+ console.log(`App (production) is now running on port ${port}!`);
+});
diff --git a/routes/index.js b/bin/server/routes/index.js
similarity index 50%
rename from routes/index.js
rename to bin/server/routes/index.js
index 233575a..72d00e9 100644
--- a/routes/index.js
+++ b/bin/server/routes/index.js
@@ -1,7 +1,7 @@
-var express = require('express');
-var router = express.Router();
+const express = require('express');
+const router = express.Router();
-var webTile = '坑爹的API';
+const webTile = '坑爹的API';
/* GET home page. */
router.get('/', function (req, res, next) {
res.render('index.html', {
@@ -10,11 +10,18 @@ router.get('/', function (req, res, next) {
});
});
-router.get('/about.html', function (req, res, next) {
+router.get('/about', function (req, res, next) {
res.render('about.html', {
title: '关于 - ' + webTile,
pageNav: 'about'
});
});
+router.get('/login', function (req, res, next) {
+ res.render('login.html', {
+ title: '登录 - ' + webTile,
+ pageNav: 'login'
+ });
+});
+
module.exports = router;
diff --git a/bin/server/webpackDevServer.js b/bin/server/webpackDevServer.js
new file mode 100644
index 0000000..fdfea70
--- /dev/null
+++ b/bin/server/webpackDevServer.js
@@ -0,0 +1,59 @@
+/**
+ * 开发运行环境,除了view/*.html的文件改动需要手动刷新,其他的src/* 的修改支持热更新
+ */
+const fs = require('fs');
+const path = require('path');
+const webpack = require('webpack');
+const WebpackDevServer = require('webpack-dev-server');
+const config = require('../build/webpack.dev.conf');
+const files = require('../config/files');
+const sysConfig = require('../config/index');
+require('shelljs/global');
+
+let expressPort = sysConfig.dev.expressPort || 24999;
+let serverPort = sysConfig.dev.serverPort || 2082;
+
+const options = {
+ publicPath: '/',
+ hot: sysConfig.dev.screw_ie8,
+ inline: sysConfig.dev.screw_ie8,
+ port: serverPort,
+ host: sysConfig.dev.host,
+ proxy: {
+ '*': 'http://localhost:' + expressPort
+ },
+ open: sysConfig.dev.autoOpenBrowser
+};
+
+WebpackDevServer.addDevServerEntrypoints(config, options);
+
+const compiler = webpack(config);
+// 启动服务
+new WebpackDevServer(compiler, options).listen(serverPort, sysConfig.dev.host, function (err) {
+ if (err) {
+ console.log(err);
+ } else {
+ console.log(`dev server on http://localhost:${serverPort}\n`);
+ }
+});
+
+const viewPath = files.tplPath;
+rm('-rf', viewPath);
+// // 在源码有更新时,更新模板
+compiler.plugin('emit', function (compilation, cb) {
+ // console.log('compilation.assets = ', compilation.assets);
+ for (const filename in compilation.assets) {
+ if (filename.endsWith('.html')) {
+ let filepath = path.resolve(viewPath, filename);
+ let dirname = path.dirname(filepath);
+ if (!fs.existsSync(dirname)) {
+ mkdir('-p', dirname);
+ }
+ // console.log('compilation.assets[filename].source() = ', compilation.assets[filename].source());
+ fs.writeFile(filepath, compilation.assets[filename].source(), (err) => {
+ if (err) throw err;
+ });
+ }
+ }
+ cb();
+});
diff --git a/bin/www b/bin/www
deleted file mode 100644
index 6d87bf7..0000000
--- a/bin/www
+++ /dev/null
@@ -1,90 +0,0 @@
-#!/usr/bin/env node
-
-/**
- * Module dependencies.
- */
-
-var app = require('../app');
-var debug = require('debug')('webpack-art-template:server');
-var http = require('http');
-
-/**
- * Get port from environment and store in Express.
- */
-
-var port = normalizePort(process.env.PORT || '54999');
-app.set('port', port);
-
-/**
- * Create HTTP server.
- */
-
-var server = http.createServer(app);
-
-/**
- * Listen on provided port, on all network interfaces.
- */
-
-server.listen(port);
-server.on('error', onError);
-server.on('listening', onListening);
-
-/**
- * Normalize a port into a number, string, or false.
- */
-
-function normalizePort(val) {
- var port = parseInt(val, 10);
-
- if (isNaN(port)) {
- // named pipe
- return val;
- }
-
- if (port >= 0) {
- // port number
- return port;
- }
-
- return false;
-}
-
-/**
- * Event listener for HTTP server "error" event.
- */
-
-function onError(error) {
- if (error.syscall !== 'listen') {
- throw error;
- }
-
- var bind = typeof port === 'string'
- ? 'Pipe ' + port
- : 'Port ' + port;
-
- // handle specific listen errors with friendly messages
- switch (error.code) {
- case 'EACCES':
- console.error(bind + ' requires elevated privileges');
- process.exit(1);
- break;
- case 'EADDRINUSE':
- console.error(bind + ' is already in use');
- process.exit(1);
- break;
- default:
- throw error;
- }
-}
-
-/**
- * Event listener for HTTP server "listening" event.
- */
-
-function onListening() {
- var addr = server.address();
- var bind = typeof addr === 'string'
- ? 'pipe ' + addr
- : 'port ' + addr.port;
- debug('Listening on ' + bind);
-}
diff --git a/build/common.js b/build/common.js
deleted file mode 100644
index 4a5c473..0000000
--- a/build/common.js
+++ /dev/null
@@ -1,23 +0,0 @@
-'use strict';
-var path = require('path');
-var glob = require('glob');
-
-exports.getEntry = function (globPath, pathDir,options) {
- var files = glob.sync(globPath,options);
- var entries = {}, entry, dirname, basename, pathname, extname;
-
- for (var i = 0; i < files.length; i++) {
- entry = files[i];
- dirname = path.dirname(entry);
- // extname = path.extname(entry);
- // basename = path.basename(entry, extname);
- basename = path.basename(entry);
- pathname = path.normalize(path.join(dirname, basename));
- pathDir = path.normalize(pathDir);
- if (pathname.startsWith(pathDir)) {
- pathname = pathname.substring(pathDir.length);
- }
- entries[pathname] = entry;
- }
- return entries;
-};
diff --git a/package.json b/package.json
index c1880f9..d7b2892 100644
--- a/package.json
+++ b/package.json
@@ -3,10 +3,10 @@
"version": "1.0.0",
"main": "index.js",
"scripts": {
- "dev": "node server",
- "browsersync": "cross-env NODE_ENV=development node app_temp",
- "build:webpack": "cross-env NODE_ENV=production webpack --config webpack.dev.config.js --progress --hide-modules",
- "node:compile": "node build/compile_node/compile-art-template",
+ "start": "concurrently \"node bin/server/webpackDevServer\" \"node bin/server/expressServer\"",
+ "unit": "cross-env BABEL_ENV=test karma start test/unit/karma.conf.js --single-run",
+ "build:webpack": "cross-env NODE_ENV=production webpack --config bin/build/webpack.prod.conf.js --progress --hide-modules",
+ "node:compile": "node bin/build/compile-art-template.js",
"build": "npm run build:webpack&&npm run node:compile"
},
"keywords": [],
@@ -24,24 +24,29 @@
"morgan": "^1.9.1"
},
"devDependencies": {
- "art-template-loader": "^1.4.3",
"autoprefixer": "^7.1.2",
"autoprefixer-loader": "^3.2.0",
- "babel-core": "^6.0.0",
- "babel-eslint": "^8.2.1",
- "babel-loader": "^7.1.1",
- "babel-polyfill": "^6.20.0",
- "babel-preset-es2015": "^6.0.0",
- "babel-preset-stage-3": "^6.17.0",
+ "babel-core": "^6.26.3",
+ "babel-loader": "^7.1.5",
+ "babel-plugin-transform-runtime": "^6.23.0",
+ "babel-polyfill": "^6.26.0",
+ "babel-preset-env": "^1.7.0",
+ "babel-preset-es2015": "^6.24.1",
+ "babel-preset-es2015-loose": "^8.0.0",
+ "babel-preset-stage-0": "^6.24.1",
"browser-sync": "^2.26.3",
+ "chai": "^4.2.0",
+ "clean-webpack-plugin": "^1.0.1",
+ "compression-webpack-plugin": "^1.1.11",
+ "copy-webpack-plugin": "^4.0.1",
"cross-env": "^3.0.0",
"css-loader": "^0.23.1",
+ "es3ify-loader": "^0.2.0",
+ "es3ify-webpack-plugin": "^0.1.0",
"eslint": "^4.2.0",
"eslint-config-djcps": "^0.0.4",
- "eslint-friendly-formatter": "^3.0.0",
"eslint-loader": "^1.9.0",
"eslint-plugin-html": "^4.0.2",
- "eslint-plugin-import": "^2.7.0",
"eslint-plugin-json": "^1.2.0",
"eslint-plugin-node": "^5.2.0",
"eslint-plugin-promise": "^3.4.0",
@@ -52,16 +57,27 @@
"html-loader": "^0.4.3",
"html-webpack-plugin": "^2.29.0",
"http-proxy-middleware": "^0.19.1",
- "jquery": "^3.3.1",
+ "jquery": "^1.12.4",
+ "karma": "^4.0.1",
+ "karma-chai": "^0.1.0",
+ "karma-chrome-launcher": "^2.2.0",
+ "karma-ie-launcher": "^1.0.0",
+ "karma-mocha": "^1.3.0",
"less": "^3.9.0",
"less-loader": "^4.1.0",
- "postcss-loader": "^0.9.1",
- "postcss-uncss": "^0.15.0",
- "postcss-write-svg": "jonathantneal/postcss-write-svg",
+ "mocha": "^6.0.2",
+ "optimize-css-assets-webpack-plugin": "^3.2.0",
+ "portfinder": "^1.0.13",
+ "postcss": "^7.0.14",
+ "postcss-import": "^12.0.1",
+ "postcss-loader": "^3.0.0",
+ "postcss-url": "^8.0.0",
+ "resolve-url-loader": "^3.0.1",
"shelljs": "^0.8.3",
"style-loader": "^0.13.0",
"url-loader": "^1.1.2",
- "webpack": "^3.3.0",
+ "webpack": "^3.12.0",
+ "webpack-bundle-analyzer": "^2.9.0",
"webpack-dev-middleware": "^2.0.6",
"webpack-dev-server": "^2.11.3",
"webpack-hot-middleware": "^2.24.3",
diff --git a/readme.md b/readme.md
index 58b6749..27b3317 100644
--- a/readme.md
+++ b/readme.md
@@ -1,3 +1,17 @@
-最近在尝试用webpack配合art-template-loader在build的时候,编译带参数(例如:{{className}})的html模板,输出html文件。
-在html-webpack-plugin配置这里,不知道怎么进行配置,才能”传入参数(option)“让其进行编译
+# 前端工程化后续计划
+
+----
+- [x] #### 问题1:改变代码时所有的 chunkhash 都会改变?
+描述:理想状态希望,非公共模块改动时,只用替换某几个文件就能完成上线工作,从而最大利用缓存
解决方案:webpack好像有这方面的功能,会基于文件内容生成对应的文件hash名,当文件没有改动时,hash值是不会改变的
通过配置各类webpack插件解决
[Vendor chunk hash varies when app chunk changes](https://github.com/webpack/webpack/issues/1150)
+
+
+- [x] #### 问题2:公共的css,还没有额外输出为一个文件;postcss 插件引入
+解决方案:webpack配置优化
+
+#### 问题3:static 文件有些可以再压缩
+描述:现在layui和自定义layui组件是,放在static文件中引入,希望通过webpack统一管理
+
+
+- [x] #### 问题4:资源地址问题
+准备将启动有关的地址全改为绝对地址,利于后续文件维护
但是不知道会对性能有多大影响(暂时没发现多大影响)
diff --git a/server.js b/server.js
deleted file mode 100644
index 71afa0c..0000000
--- a/server.js
+++ /dev/null
@@ -1,90 +0,0 @@
-const fs = require('fs');
-const path = require('path');
-const webpack = require('webpack');
-const WebpackDevServer = require('webpack-dev-server');
-const config = require('./webpack.dev.config');
-const sysConfig = require('./sysConfig');
-const merge = require('webpack-merge');
-require('shelljs/global');
-
-const serverPort = 24999;
-const devPort = 2082;
-
-const exec = require('child_process').exec;
-const cmdStr = 'cross-env PORT=' + serverPort + ' supervisor ./bin/www';
-// const cmdStr = 'cross-env supervisor ./bin/www'
-
-exec(cmdStr, function (err, stdout, stderr) {
- if (err) {
- console.error('err = ', err);
- } else {
- console.log('stdout = ', stdout);
- }
-});
-
-//todo webpack/hot/dev-server?
-for (const i in config.entry) {
- config.entry[i].unshift('webpack-dev-server/client?http://localhost:' + devPort, 'webpack/hot/dev-server');
-}
-config.plugins.push(new webpack.HotModuleReplacementPlugin());
-
-const proxy = {
- '*': 'http://localhost:' + serverPort,
- // '/djwmsservice': 'http://192.168.2.167:3000',
- // '/djwmsservice': {
- // target: 'http://localhost:3000',
- // pathRewrite: {'^/djwmsservice': ''},
- // // target是域名的话,需要这个参数,
- // changeOrigin: true,
- // // 设置支持https协议的代理
- // secure: false
- // }
-};
-
-const compiler = webpack(config);
-// 启动服务
-new WebpackDevServer(compiler, {
- publicPath: sysConfig.dev.publicPath + '/',
- hot: true,
- proxy: proxy
- // open: sysConfig.dev.autoOpenBrowser
-}).listen(sysConfig.dev.port, sysConfig.dev.host, function (err) {
- if (err) {
- console.log(err);
- } else {
- console.log('dev server on http://localhost:' + sysConfig.dev.port + '\n');
- }
-});
-
-const viewPath = path.join(__dirname, sysConfig.dev.tplPath);
-rm('-rf', viewPath);
-// // 在源码有更新时,更新模板
-compiler.plugin('emit', function (compilation, cb) {
- // console.log('compilation.assets = ', compilation.assets);
- for (const filename in compilation.assets) {
- if (filename.endsWith('.html')) {
- let filepath = path.resolve(viewPath, filename);
- let dirname = path.dirname(filepath);
- if (!fs.existsSync(dirname)) {
- mkdir('-p', dirname);
- }
- // console.log('compilation.assets[filename].source() = ', compilation.assets[filename].source());
- fs.writeFile(filepath, compilation.assets[filename].source(), (err) => {
- if (err) throw err;
- });
- }
- }
- cb();
-});
-
-// 当页面模板有改变时,强制刷新页面
-compiler.plugin('compilation', function (compilation) {
- compilation.plugin('html-webpack-plugin-after-emit', function (data, cb) {
- // todo 刷新浏览器
- /**
- * 实际项目中,应该使用webpack-dev-middleware和webpack-hot-middleware中间件,
- * 结合node库express/koa等使用。
- */
- cb();
- });
-});
diff --git a/src/imgs/favicon.ico b/src/imgs/favicon.ico
deleted file mode 100644
index 482b987..0000000
Binary files a/src/imgs/favicon.ico and /dev/null differ
diff --git a/src/scripts/components/dialog/css/dialog.css b/src/scripts/components/dialog/css/dialog.css
index f8578c9..c544a3e 100644
--- a/src/scripts/components/dialog/css/dialog.css
+++ b/src/scripts/components/dialog/css/dialog.css
@@ -1,8 +1,11 @@
.v-dialog{
+ behavior: url(/static/PIE.htc);
position: fixed;
display: none;
left: 0;top:0;right:0;bottom:0;
- background-color: rgba(0,0,0,.5);
+ background: rgba(0,0,0,.5);
+ -pie-background: rgba(249, 86, 48, 0.5);
+ user-select: none;
}
.v-dialog .close{
position: absolute;
@@ -15,8 +18,10 @@
line-height: 40px;
font-size: 40px;
color:#666;
- background-color: rgba(255,255,255,.8);
+ background: rgba(255,255,255,.8);
+ -pie-background: rgba(61, 87, 255, 0.8);
cursor: pointer;
+ behavior: url(/static/PIE.htc);
}
.v-dialog .img{
position: absolute;
@@ -24,4 +29,4 @@
top:0;right: 0;bottom:0;left: 0;
max-width: 90%;
max-height: 90%;
-}
\ No newline at end of file
+}
diff --git a/src/scripts/components/dialog/index.js b/src/scripts/components/dialog/index.js
index 199f541..a8fb671 100644
--- a/src/scripts/components/dialog/index.js
+++ b/src/scripts/components/dialog/index.js
@@ -13,4 +13,5 @@ module.exports = function () {
});
$('body').append($dialog);
$dialog.fadeIn();
+ console.log('123124');
};
diff --git a/src/scripts/page/about.js b/src/scripts/page/about.js
index 3796877..cc155b4 100644
--- a/src/scripts/page/about.js
+++ b/src/scripts/page/about.js
@@ -1,8 +1,4 @@
// 引入css
-require('../../styles/lib/reset.css');
-require('../../styles/common/global.css');
-require('../../styles/common/grid.css');
-require('../../styles/common/common.less');
-
+require('../../styles/base/index.less');
/* eslint-disable no-undef */
$('.g-bd').append('这是一段js生成的文字');
diff --git a/src/scripts/page/index.js b/src/scripts/page/index.js
index 32dabc8..0bc6c7e 100644
--- a/src/scripts/page/index.js
+++ b/src/scripts/page/index.js
@@ -1,13 +1,11 @@
+// todo 首屏加载优化,先渲染主框架
// 引入css
-require('../../styles/lib/reset.css');
-require('../../styles/common/global.css');
-require('../../styles/common/grid.css');
-require('../../styles/common/common.less');
+require('../../styles/base/index.less');
require('../../styles/page/index.less');
var oP = document.createElement('p');
oP.className = 'text';
-oP.innerHTML = '这是由js生成的一句话。';
+oP.innerHTML = '这是由js生成的一句话。123123';
document.querySelector('.g-bd').appendChild(oP);
/* eslint-disable no-undef */
@@ -22,6 +20,7 @@ $('#http').click(function () {
// ajax('https://api.douban.com/v2/music/search?q=周杰伦');
});
getTest();
+
function getTest() {
$.ajax({
type: "post",
@@ -35,27 +34,5 @@ function getTest() {
console.log('error = ', err);
}
});
- // ---------------------
- // 作者:wopelo
- // 来源:CSDN
- // 原文:https://blog.csdn.net/wopelo/article/details/79802585
- // 版权声明:本文为博主原创文章,转载请附上博文链接!
}
-function github_test() {
- var native = new XMLHttpRequest();
- native.open("GET", "https://api.github.com/");
- native.send();
- native.onreadystatechange = function () {
- if (native.readyState == 4 && native.status == 200) {
- console.log(native.response);
- } else {
- console.log(native.status);
- }
- };
- // ---------------------
- // 作者:wopelo
- // 来源:CSDN
- // 原文:https://blog.csdn.net/wopelo/article/details/79802585
- // 版权声明:本文为博主原创文章,转载请附上博文链接!
-}
diff --git a/src/scripts/page/login.js b/src/scripts/page/login.js
new file mode 100644
index 0000000..3ed3d9f
--- /dev/null
+++ b/src/scripts/page/login.js
@@ -0,0 +1,952 @@
+// 引入css
+require('../../styles/base/index.less');
+require('../../styles/page/login.less');
+// require('../../styles/lib/layui/css/layui.css');
+// layui.extend({
+// djcpsAlert: 'static/lib/components/modules/djcpsAlert/djcpsAlert'
+// });
+/* eslint-disable no-undef */
+// $(function () {
+ // (function (layui) {
+ require('../../utils/layui_extend');
+ // var $ = layui.jquery;
+ // layui.extend({
+ // djcpsAlert: 'static/lib/components/modules/djcpsAlert/djcpsAlert'
+ // });
+ layui.use('djcpsAlert', function () {
+ var djcpsAlert = layui.djcpsAlert;
+ $('.alert').click(function () {
+ djcpsAlert.init('当前信息已过期,请重新登录', undefined, function (index, layero) {
+ console.log(index, layero);
+ });
+ });
+ });
+ layui.use(['djcpsDate'], function () {
+ var djcpsDate = layui.djcpsDate;
+ djcpsDate.init({
+ container: $('#date'),
+ id: 'date1',
+ type: 'date',
+ placeholder: '请选择日期'
+ });
+ djcpsDate.init({
+ container: $('#year'),
+ id: 'year1',
+ type: 'year',
+ placeholder: '请选择年份'
+ });
+ djcpsDate.init({
+ container: $('#month'),
+ id: 'month1',
+ type: 'month',
+ placeholder: '请选择年月'
+ });
+ djcpsDate.init({
+ container: $('#time'),
+ id: 'time1',
+ type: 'time',
+ placeholder: '请选择时间'
+ });
+ djcpsDate.init({
+ container: $('#datetime'),
+ id: 'datetime1',
+ type: 'datetime',
+ placeholder: '请选择日期时间'
+ });
+ djcpsDate.init({
+ container: $('#dateRange'),
+ id: 'dateRange1',
+ type: 'date',
+ range: true,
+ placeholder: '请选择日期区间'
+ });
+ djcpsDate.init({
+ container: $('#yearRange'),
+ id: 'yearRange1',
+ type: 'year',
+ range: true,
+ placeholder: '请选择年份区间'
+ });
+ djcpsDate.init({
+ container: $('#monthRange'),
+ id: 'monthRange1',
+ type: 'month',
+ range: true,
+ placeholder: '请选择年月区间'
+ });
+ djcpsDate.init({
+ container: $('#timeRange'),
+ id: 'timeRange1',
+ type: 'time',
+ range: true,
+ placeholder: '请选择时间区间'
+ });
+ djcpsDate.init({
+ container: $('#datetimeRange'),
+ id: 'datetimeRange1',
+ type: 'datetime',
+ range: true,
+ placeholder: '请选择日期时间区间',
+ theme: 'default'
+ });
+ djcpsDate.init({
+ container: $('#datetimeRangeMolv'),
+ id: 'datetimeRangeMolv1',
+ type: 'datetime',
+ range: true,
+ placeholder: '请选择日期时间区间',
+ theme: 'molv'
+ });
+ djcpsDate.init({
+ container: $('#datetimeRangeCustom'),
+ id: 'datetimeRangeCustom1',
+ type: 'datetime',
+ range: true,
+ placeholder: '请选择日期时间区间',
+ theme: '#393D49'
+ });
+ djcpsDate.init({
+ container: $('#datetimeRangeGrid'),
+ id: 'datetimeRangeGrid1',
+ type: 'datetime',
+ range: true,
+ placeholder: '请选择日期时间区间',
+ theme: 'grid'
+ });
+ djcpsDate.init({
+ container: $('#datetimeRangeConcise'),
+ id: 'datetimeRangeConcise1',
+ type: 'datetime',
+ range: true,
+ placeholder: '请选择日期时间区间',
+ theme: 'concise'
+ });
+ });
+ layui.use('djcpsConfirm', function () {
+ var djcpsConfirm = layui.djcpsConfirm;
+ $('.confirm').click(function () {
+ djcpsConfirm.init('是否删除此项数据?', undefined, function (index, layero) {
+ console.log('success', layero);
+ }, function (index, layero) {
+ console.log('cancel', layero);
+ });
+ });
+ });
+ layui.use('djcpsMsg', function () {
+ var djcpsMsg = layui.djcpsMsg;
+ $('.msg').click(function () {
+ djcpsMsg.init('当前信息已过期,请重新登录', undefined, function () {
+ console.log('end');
+ });
+ });
+ });
+ layui.use(['djcpsUpload', 'laytpl', 'layer'], function () {
+ var djcpsUpload = layui.djcpsUpload;
+ var laytpl = layui.laytpl;
+ var layer = layui.layer;
+ // todo `` 压缩出错
+ var uploadListTpl = '{{# layui.each(d,function(index, item) { }} ' +
+ '
' +
+ '{{item.file.name}} | ' +
+ ' | ' +
+ '{{(item.file.size/1024).toFixed(1)}}kb | ' +
+ '等待上传 | ' +
+ ' ' +
+ ' ' +
+ ' ' +
+ ' ' +
+ ' | ' +
+ '
' +
+ '{{# }); }}';
+ var loading;
+ var fileArr = [];
+ var upload1 = djcpsUpload.init({
+ elem: '#upload1',
+ url: '/api/upload',
+ data: {id: 111111, name: 'hahaha'},
+ accept: 'images',
+ acceptMime: 'image/jpg, image/png, image/jpeg',
+ exts: 'jpg|png|jpeg',
+ auto: false,
+ bindAction: $('#uploadBtn'),
+ field: 'file',
+ size: 100,
+ multiple: true,
+ number: 0,
+ drag: false,
+ choose: function (obj) {
+ upload1.filePreview(obj).then(function (fileArr) {
+ laytpl(uploadListTpl).render(fileArr, function (html) {
+ $('#uploadBody').html(html);
+ $('.delete').unbind().bind('click', function () {
+ var index = $(this).parents('tr').data('index');
+ var itemIndex = (function () {
+ for (var i = 0; i < fileArr.length; i++) {
+ if (fileArr[i].index === index) {
+ return i;
+ }
+ }
+ })();
+ upload1.deleteFile(fileArr[itemIndex].index, $(this).parents('tr'));
+ fileArr.splice(itemIndex, 1);
+ });
+ $('.reupload').unbind().bind('click', function () {
+ var index = $(this).parents('tr').data('index');
+ var itemIndex = (function () {
+ for (var i = 0; i < fileArr.length; i++) {
+ if (fileArr[i].index === index) {
+ return i;
+ }
+ }
+ })();
+ upload1.reupload(obj, fileArr[itemIndex].file, fileArr[itemIndex].index);
+ });
+ });
+ });
+ },
+ before: function (obj) {
+ var fileArr = upload1.filePreview(obj);
+ console.log(fileArr);
+ loading = layer.load();
+ },
+ done: function (res, index, upload) {
+ console.log(res, index, upload);
+ },
+ error: function (index, upload) {
+ console.log(index, upload);
+ },
+ allDone: function (obj) {
+ console.log(obj);
+ layer.close(loading);
+ }
+ });
+ $('#reupload').click(function () {
+ upload1.reupload();
+ });
+ });
+ layui.use('djcpsTips', function () {
+ var djcpsTips = layui.djcpsTips;
+ $('.tips').click(function () {
+ djcpsTips.init('这是一段文字', $('.tips'), {});
+ });
+ });
+ layui.use('djcpsProgress', function () {
+ var djcpsProgress = layui.djcpsProgress;
+ var progress = djcpsProgress.init({
+ filter: 'progress',
+ bigProgress: true,
+ showPercent: true,
+ percent: '20%'
+ });
+ setTimeout(function () {
+ progress.setProgress('progress', '50%');
+ }, 3000);
+ });
+ layui.use(['djcpsPanel'], function () {
+ var djcpsPanel = layui.djcpsPanel;
+ djcpsPanel.init({
+ data: [
+ {
+ 'title': '为什么JS社区大量采用未发布或者未广泛支持的语言特性?',
+ 'content': '有不少其他答案说是因为JS太差。我下面的答案已经说了,这不是根本性的原因。但除此之外,我还要纠正一些对JS具体问题的误解。JS当初是被作为脚本语言设计的,所以某些问题并不是JS设计得差或者是JS设计者的失误。比如var的作用域问题,并不是“错误”,而是当时绝大部分脚本语言都是这样的,如perl/php/sh等。模块的问题也是,脚本语言几乎都没有模块/命名空间功能。弱类型、for-in之类的问题也是,只不过现在用那些老的脚本语言的人比较少,所以很多人都误以为是JS才有的坑。另外有人说JS是半残语言,满足不了开发需求,1999年就该死。半残这个嘛,就夸张了。JS虽然有很多问题,但是设计总体还是优秀的。——来自知乎@贺师俊
'
+ },
+ {
+ 'title': '为什么JS社区大量采用未发布或者未广泛支持的语言特性1?',
+ 'content': '有不少其他答案说是因为JS太差。我下面的答案已经说了,这不是根本性的原因。但除此之外,我还要纠正一些对JS具体问题的误解。JS当初是被作为脚本语言设计的,所以某些问题并不是JS设计得差或者是JS设计者的失误。比如var的作用域问题,并不是“错误”,而是当时绝大部分脚本语言都是这样的,如perl/php/sh等。模块的问题也是,脚本语言几乎都没有模块/命名空间功能。弱类型、for-in之类的问题也是,只不过现在用那些老的脚本语言的人比较少,所以很多人都误以为是JS才有的坑。另外有人说JS是半残语言,满足不了开发需求,1999年就该死。半残这个嘛,就夸张了。JS虽然有很多问题,但是设计总体还是优秀的。——来自知乎@贺师俊
'
+ }
+ ]
+ });
+ });
+ layui.use('djcpsPage', function () {
+ var djcpsPage = layui.djcpsPage;
+ getList(1, 10);
+
+ /**
+ * 获取列表数据
+ * @param {*} currpage 当前页码
+ * @param {*} pagesize 每页显示数据数
+ */
+ function getList(currpage, pagesize) {
+ $.get('./static/data.json', function (res) {
+ var data = res.data.slice((currpage - 1) * pagesize, currpage * pagesize);
+ var html = data.map(function (item) {
+ return '' + item.text + '';
+ });
+ $('.list').html(html);
+ djcpsPage.init({
+ elem: $('#page'),
+ count: res.count, //数据总数
+ curr: currpage,
+ limit: pagesize,
+ theme: 'cps',
+ layout: ['count', 'prev', 'page', 'next', 'skip'],
+ jump: function (obj, first) {
+ if (!first) {
+ getList(obj.curr, obj.limit);
+ }
+ }
+ });
+ djcpsPage.init({
+ elem: $('#pageDefault'),
+ count: res.count, //数据总数
+ curr: currpage,
+ limit: pagesize,
+ theme: 'default',
+ prev: 'prev',
+ next: 'next',
+ first: '1',
+ last: Math.ceil(res.count / pagesize),
+ layout: ['count', 'prev', 'page', 'next', 'limit', 'refresh', 'skip'],
+ jump: function (obj, first) {
+ if (!first) {
+ getList(obj.curr, obj.limit);
+ }
+ }
+ });
+ // laytpl(getTpl).render(data, function (html) {
+ //
+ // });
+ });
+ }
+ });
+ layui.use(['djcpsCarousel', 'laytpl'], function () {
+ var djcpsCarousel = layui.djcpsCarousel;
+ var laytpl = layui.laytpl;
+ var tpl = '{{# layui.each(d, function(index, item) { }} {{item.firstTxt}}
{{item.secondTxt}}

{{# }) }}';
+ var data = [
+ {
+ firstTxt: '01',
+ secondTxt: '11',
+ img: 'static/images/1.jpg'
+ }, {
+ firstTxt: '02',
+ secondTxt: '12',
+ img: 'static/images/2.jpg'
+ }, {
+ firstTxt: '03',
+ secondTxt: '13',
+ img: 'static/images/3.jpg'
+ }, {
+ firstTxt: '04',
+ secondTxt: '14',
+ img: 'static/images/4.jpg'
+ }, {
+ firstTxt: '05',
+ secondTxt: '15',
+ img: 'static/images/5.jpg'
+ }, {
+ firstTxt: '06',
+ secondTxt: '16',
+ img: 'static/images/6.jpg'
+ }];
+ laytpl(tpl).render(data, function (html) {
+ djcpsCarousel.init({
+ container: $('#carouselInner'),
+ interval: 5000,
+ options: {
+ type: 'custom',
+ prop: '',
+ customHtml: html,
+ errorSrc: 'static/images/error.png'
+ },
+ filter: 'test',
+ change: function (obj) {
+ // console.log('test', obj);
+ }
+ });
+ });
+ var carousel = djcpsCarousel.init({
+ interval: 5000,
+ speed: 0.3,
+ options: {
+ type: 'img',
+ prop: 'img',
+ errorSrc: 'static/images/error.png'
+ },
+ data: [{
+ img: 'static/images/1.jpg',
+ alt: '111',
+ text: '111'
+ }, {
+ img: 'static/images/2.jpg',
+ alt: '222',
+ text: '222'
+ }, {
+ img: 'static/images/3.jpg',
+ alt: '333',
+ text: '333'
+ }, {
+ img: 'static/images/4.jpg',
+ alt: '444',
+ text: '444'
+ }, {
+ img: 'static/images/5.jpg',
+ alt: '555',
+ text: '555'
+ }, {
+ img: 'static/images/6.jpg',
+ alt: '666',
+ text: '666'
+ }],
+ change: function (obj) {
+ // console.log('default', obj);
+ }
+ });
+ });
+ layui.use('djcpsModal', function () {
+ var djcpsModal = layui.djcpsModal;
+ $('.dom').click(function () {
+ var modal = djcpsModal.init({
+ content: $('#modal'),
+ maxmin: true
+ });
+ modal.success(function (layero, index) {
+ modal.changeTitle('标题改了', index);
+ var body = modal.getChildFrame('body');
+ console.log(body);
+ // modal.setMaxMin(1, index);
+ setTimeout(function () {
+ console.log('success');
+ console.log(layero);
+ console.log(index);
+ // modal.closeAll('dialog');
+ modal.changeStyle({'font-size': '30px', 'color': 'red'}, index);
+ modal.changeTitle('标题又改了', index);
+ modal.setMaxMin(3, index);
+ }, 2000);
+ });
+ modal.cancel(function (index, layero) {
+ setTimeout(function () {
+ console.log('cancel');
+ console.log(layero);
+ console.log(index);
+ modal.close(index);
+ }, 2000);
+ return false;
+ });
+ modal.end(function () {
+ setTimeout(function () {
+ console.log('end');
+ }, 2000);
+ });
+ modal.full(function (layero) {
+ console.log(layero);
+ });
+ modal.min(function (layero) {
+ console.log(layero);
+ });
+ modal.restore(function (layero) {
+ console.log(layero);
+ });
+ });
+ $('.iframe').click(function () {
+ var iframeModal = djcpsModal.init({
+ type: 2,
+ content: '/about'
+ });
+ iframeModal.success(function (layero, index) {
+ var body = iframeModal.getChildFrame('body', index);
+ console.log(body);
+ });
+ });
+ });
+ layui.use('djcpsLoad', function () {
+ var djcpsLoad = layui.djcpsLoad;
+ $('.load1').click(function () {
+ var load = djcpsLoad.init(1);
+ setTimeout(function () {
+ load.close();
+ }, 3000);
+ });
+ $('.load2').click(function () {
+ var load = djcpsLoad.init(2);
+ setTimeout(function () {
+ load.close();
+ }, 3000);
+ });
+ $('.load3').click(function () {
+ var load = djcpsLoad.init(0);
+ setTimeout(function () {
+ load.close();
+ }, 3000);
+ });
+ });
+ layui.use(['djcpsFlow'], function () {
+ var djcpsFlow = layui.djcpsFlow;
+ var flow = djcpsFlow.init({
+ scrollElem: '#layflow',
+ end: '没有了~~',
+ done: function (page, next) {
+ setTimeout(function () {
+ var lis = [];
+ for (var i = 0; i < 10; i++) {
+ lis.push('' + ((page - 1) * 10 + i + 1) + '');
+ }
+ next(lis.join(''), page < 10); //假设总页数为 10
+ }, 500);
+ }
+ });
+ var flows = djcpsFlow.init({
+ elem: '#layflowlazy',
+ scrollElem: '#layflowlazy',
+ isLazyimg: true,
+ isAuto: false,
+ mb: '300',
+ done: function (page, next) {
+ setTimeout(function () {
+ var lis = [];
+ for (var i = 0; i < 51; i++) {
+ lis.push('略略略
');
+ }
+ next(lis.join(''), page < 1);
+ }, 500);
+ }
+ });
+ });
+ layui.use(['layer', 'djcpsTree'], function () {
+ var layer = layui.layer,
+ djcpsTree = layui.djcpsTree;
+
+ var data = [
+ {
+ // 节点名称
+ name: '研发中心',
+ // 是否展开状态(默认false)
+ spread: true,
+ // 节点链接(可选),未设则不会跳转
+ href: null,
+ // 可以自定义参数
+ id: null,
+ children: [
+ {
+ name: '温州部'
+ },
+ {
+ name: '杭州部'
+ }
+ ]
+ },
+ {
+ name: '人资中心',
+ spread: true,
+ children: [
+ {
+ name: '招聘组',
+ spread: true,
+ children: [
+ {
+ name: '小组'
+ }
+ ]
+ }
+ ]
+ }
+ ];
+
+ // 简洁风格
+ var tree = djcpsTree.init({
+ nodes: data,
+ click: function (node) {
+ layer.msg(node['name']);
+ }
+ });
+ // 默认风格
+ djcpsTree.init({
+ // 绑定元素
+ elem: '#defaultTree',
+ // 默认风格
+ skin: '',
+ nodes: data,
+ click: function (node) {
+ layer.msg(node['name']);
+ }
+ });
+ });
+ layui.use(['djcpsForm'], function () {
+ var djcpsForm = layui.djcpsForm;
+ var forms = djcpsForm.init({
+ layFilter: 'example', // form lay-filter命名
+ layVerType: 'tips',
+ isEdit: false,
+ pane: false,
+ data: [
+ {
+ type: 'upload',
+ 'label': '文件上传', //表单描述
+ 'name': 'upload',
+ 'layVerify': {
+ name: 'ccc',
+ rules: function (value) {
+ if (!value) {
+ return "文件未上传";
+ }
+ }
+ },
+ customHtml: $('#uploadPic').html(),
+ options: {
+ elem: '#test1',
+ url: '/upload/',
+ auto: false,
+ choose: function (obj, modal) {
+ console.log(obj);
+ modal.filePreview().then(function (fileArr) {
+ // modal.deleteAllFile();
+ $('#demo1').attr('src', fileArr[fileArr.length - 1].url);
+ $('.upload .layui-input-block').find('.uploadContent').val(fileArr[fileArr.length - 1].url);
+ });
+ }
+ }
+ },
+ {
+ 'type': 'select', // 表单类型 password (密码) text(单行文本)select(选择框)checkbox(复选框)radio(单选框)textarea(文本域)
+ 'label': '下拉选择框', // 表单描述
+ 'name': 'select', // 规定 input 元素的名称
+ 'layVerify': {
+ name: 'select',
+ rules: function (value) {
+ if (value === '-1') {
+ return "必填项";
+ }
+ }
+ },
+ 'options': {
+ 'disabled': false, // 是否禁用
+ laySearch: true, // 是否允许搜索
+ data: [{
+ 'title': '请选择', // 自定义文本
+ 'value': '-1', // 规定 input 元素的值
+ 'disabled': false // 是否禁用
+ },
+ {
+ 'title': '111', //自定义文本
+ 'value': '0',
+ 'disabled': true//是否禁用
+ },
+ {
+ 'title': '222', //自定义文本
+ 'value': '1',
+ 'disabled': false, //是否禁用
+ 'checked': true
+ }]
+ }
+ },
+ {
+ 'type': 'select', // 表单类型 password (密码) text(单行文本)select(选择框)checkbox(复选框)radio(单选框)textarea(文本域)
+ 'label': '分组下拉框', // 表单描述
+ 'name': 'groupSelect', // 规定 input 元素的名称
+ 'layVerify': {
+ name: 'groupSelect',
+ rules: function (value) {
+ if (value === '-1') {
+ return "必填项";
+ }
+ }
+ },
+ 'options': {
+ 'disabled': false, // 是否禁用
+ laySearch: true, // 是否允许搜索
+ hasGroup: true,
+ data: [{
+ 'title': '请选择', // 自定义文本
+ 'value': '-1', // 规定 input 元素的值
+ 'disabled': false // 是否禁用
+ },
+ {
+ 'groupLabel': '数字',
+ 'title': '111', //自定义文本
+ 'value': '0',
+ 'disabled': true//是否禁用
+ },
+ {
+ 'groupLabel': '数字',
+ 'title': '222', //自定义文本
+ 'value': '1',
+ 'disabled': false, //是否禁用
+ 'checked': true
+ },
+ {
+ 'groupLabel': '数字',
+ 'title': '333', //自定义文本
+ 'value': '3',
+ 'disabled': false, //是否禁用
+ 'checked': false
+ },
+ {
+ 'groupLabel': '字母',
+ 'title': 'aaa', //自定义文本
+ 'value': 'a',
+ 'disabled': false//是否禁用
+ },
+ {
+ 'groupLabel': '字母',
+ 'title': 'bbb', //自定义文本
+ 'value': 'b',
+ 'disabled': false//是否禁用
+ },
+ {
+ 'groupLabel': '字母',
+ 'title': 'ccc', //自定义文本
+ 'value': 'c',
+ 'disabled': false//是否禁用
+ }]
+ }
+ },
+ {
+ 'type': 'text', //表单类型
+ 'label': '单行文本框', //表单描述
+ 'name': 'text',
+ 'layVerify': {
+ name: 'text',
+ rules: function (value) {
+ if (!value) {
+ return "必填项";
+ }
+ }
+ }, //表单验证
+ options: {
+ 'placeholder': '请输入文字', //表单描述
+ 'autocomplete': false, //规定输入字段是否应该启用自动完成功能
+ 'disabled': false, //是否禁用
+ 'readonly': false //是否只读
+ }
+ },
+ {
+ 'type': 'radio', //表单类型
+ 'label': '单选框', //表单描述
+ 'name': 'radio',
+ 'options': {
+ data: [ //单选框,复选框,选择框需要的参数
+ {
+ 'title': '男', //自定义文本
+ 'value': 'a',
+ 'disabled': false, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'title': '女', //自定义文本
+ 'value': 'b', //规定 input 元素的值
+ 'disabled': true, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'title': '不明', //自定义文本
+ 'value': 'c', //规定 input 元素的值
+ 'disabled': true, //是否禁用
+ 'checked': true //是否选中
+ },
+ {
+ 'title': '秀吉', //自定义文本
+ 'value': 'd', //规定 input 元素的值
+ 'disabled': false, //是否禁用
+ 'checked': false //是否选中
+ }
+ ]
+ }
+ },
+ {
+ 'type': 'checkbox', //表单类型
+ 'label': '原始复选框', //表单描述
+ 'name': 'checkbox',
+ 'options': {
+ data: [
+ {
+ 'title': '写', //自定义文本
+ 'value': '1', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': 'primary', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': false, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'title': '读', //自定义文本
+ 'value': '2', //规定 input 元素的值
+ 'laySkin': 'primary', //switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本
+ 'disabled': true, //是否禁用
+ 'checked': true //是否选中
+ },
+ {
+ 'title': '听', //自定义文本
+ 'value': '4', //规定 input 元素的值
+ 'laySkin': 'primary', //switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本
+ 'disabled': true, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'title': '看', //自定义文本
+ 'value': '3', //规定 input 元素的值
+ 'laySkin': 'primary', //switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本
+ 'disabled': false, //是否禁用
+ 'checked': true //是否选中
+ }
+ ]
+ }
+ },
+ {
+ 'type': 'checkbox', //表单类型
+ 'label': '开关复选框', //表单描述
+ 'name': 'switch',
+ 'options': {
+ data: [
+ {
+ 'value': '1', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': 'switch', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '原创|非原创', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': false, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'value': '2', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': 'switch', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '可行|不可行', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': true, //是否禁用
+ 'checked': true //是否选中
+ },
+ {
+ 'value': '4', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': 'switch', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '是|否', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': true, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'value': '3', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': 'switch', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '开|关', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': false, //是否禁用
+ 'checked': true //是否选中
+ }
+ ]
+ }
+ },
+ {
+ 'type': 'checkbox', //表单类型
+ 'label': '默认复选框', //表单描述
+ 'name': 'default',
+ 'options': {
+ data: [
+ {
+ 'title': '看书', //自定义文本
+ 'value': '1', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': '', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': false, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'title': '写作业', //自定义文本
+ 'value': '2', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': '', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': true, //是否禁用
+ 'checked': true //是否选中
+ },
+ {
+ 'title': '玩游戏', //自定义文本
+ 'value': '4', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': '', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': true, //是否禁用
+ 'checked': false //是否选中
+ },
+ {
+ 'title': '发呆', //自定义文本
+ 'value': '3', //规定 input 元素的值 checkbox 不需要填写
+ 'laySkin': '', //checkbox类型下可选择 switch(开关风格) primary(原始风格)
+ 'layText': '', //lay-text可自定义开关两种状态的文本 例如:开|关
+ 'disabled': false, //是否禁用
+ 'checked': true //是否选中
+ }
+ ]
+ }
+ },
+ {
+ 'type': 'textarea', //表单类型
+ 'label': '文本域', //表单描述
+ 'name': 'textarea',
+ 'layVerify': {
+ name: 'required',
+ rules: function (value) {
+ var msg;
+ $.ajax({
+ async: false, //改为同步请求
+ url: './data.json',
+ dataType: 'json',
+ type: 'get',
+ success: function (result) {
+ if (!value) {
+ msg = result.msg;
+ }
+ }
+ });
+ return msg;
+ }
+ }, //表单验证 required(必填项)phone(手机号)email(邮箱)url(网址)number(数字)date(日期)identity(身份证)
+ options: {
+ 'placeholder': '', //表单描述
+ 'disabled': false, //是否禁用
+ 'readonly': false //是否只读
+ }
+ },
+ {
+ type: 'custom',
+ name: 'psd',
+ customHtml: $('#item').html(),
+ 'layVerify': {
+ name: 'aaa',
+ rules: function (value) {
+ if (!value) {
+ return "必填项";
+ }
+ }
+ }
+ },
+ {
+ type: 'date',
+ 'label': '日期', //表单描述
+ 'name': 'date',
+ 'layVerify': {
+ name: 'bbb',
+ rules: function (value) {
+ if (!value) {
+ return "日期必填项";
+ }
+ }
+ },
+ options: {
+ id: 'ddd',
+ disabled: false,
+ placeholder: '请选择时间',
+ // value: '1999-01-10',
+ done: function (val) {
+ console.log(val);
+ }
+ }
+ },
+ {
+ type: 'custom',
+ name: 'formbtn',
+ customHtml: $('#formBtn').html()
+ }
+ ]
+ });
+ forms.on('submit(submit)', function (obj) {
+ console.log(obj);
+ });
+ forms.on('select', function (obj) {
+ console.log(obj);
+ });
+ forms.on('checkbox', function (obj) {
+ console.log(obj);
+ });
+ forms.on('switch', function (obj) {
+ console.log(obj);
+ });
+ forms.on('radio', function (obj) {
+ console.log(obj);
+ });
+ });
+ // })(window.layui);
+// });
diff --git a/src/styles/common/common.less b/src/styles/base/common.less
similarity index 100%
rename from src/styles/common/common.less
rename to src/styles/base/common.less
diff --git a/src/styles/common/global.css b/src/styles/base/global.css
similarity index 100%
rename from src/styles/common/global.css
rename to src/styles/base/global.css
diff --git a/src/styles/common/grid.css b/src/styles/base/grid.css
similarity index 100%
rename from src/styles/common/grid.css
rename to src/styles/base/grid.css
diff --git a/src/styles/base/index.less b/src/styles/base/index.less
new file mode 100644
index 0000000..573d50b
--- /dev/null
+++ b/src/styles/base/index.less
@@ -0,0 +1,7 @@
+@import "./common";
+@import "./global.css";
+@import "./grid.css";
+@import "./main.css";
+@import "./normalize.css";
+
+//todo layui中的一些css属性在ie8上显示效果与chrome不同 例:.layui-carousel-arrow{border-radius:50%}
diff --git a/src/styles/base/main.css b/src/styles/base/main.css
new file mode 100644
index 0000000..ebd0ebd
--- /dev/null
+++ b/src/styles/base/main.css
@@ -0,0 +1,282 @@
+/*! HTML5 Boilerplate v5.3.0 | MIT License | https://html5boilerplate.com/ */
+
+/*
+ * What follows is the result of much research on cross-browser styling.
+ * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
+ * Kroc Camen, and the H5BP dev community and team.
+ */
+
+/* ==========================================================================
+ Base styles: opinionated defaults
+ ========================================================================== */
+
+html {
+ color: #222;
+ font-size: 1em;
+ line-height: 1.4;
+}
+
+/*
+ * Remove text-shadow in selection highlight:
+ * https://twitter.com/miketaylr/status/12228805301
+ *
+ * These selection rule sets have to be separate.
+ * Customize the background color to match your design.
+ */
+
+::-moz-selection {
+ background: #b3d4fc;
+ text-shadow: none;
+}
+
+::selection {
+ background: #b3d4fc;
+ text-shadow: none;
+}
+
+/*
+ * A better looking default horizontal rule
+ */
+
+hr {
+ display: block;
+ height: 1px;
+ border: 0;
+ border-top: 1px solid #ccc;
+ margin: 1em 0;
+ padding: 0;
+}
+
+/*
+ * Remove the gap between audio, canvas, iframes,
+ * images, videos and the bottom of their containers:
+ * https://github.com/h5bp/html5-boilerplate/issues/440
+ */
+
+audio,
+canvas,
+iframe,
+img,
+svg,
+video {
+ vertical-align: middle;
+}
+
+/*
+ * Remove default fieldset styles.
+ */
+
+fieldset {
+ border: 0;
+ margin: 0;
+ padding: 0;
+}
+
+/*
+ * Allow only vertical resizing of textareas.
+ */
+
+textarea {
+ resize: vertical;
+}
+
+/* ==========================================================================
+ Browser Upgrade Prompt
+ ========================================================================== */
+
+.browserupgrade {
+ margin: 0.2em 0;
+ background: #ccc;
+ color: #000;
+ padding: 0.2em 0;
+}
+
+/* ==========================================================================
+ Author's custom styles
+ ========================================================================== */
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+/* ==========================================================================
+ Helper classes
+ ========================================================================== */
+
+/*
+ * Hide visually and from screen readers
+ */
+
+.hidden {
+ display: none !important;
+}
+
+/*
+ * Hide only visually, but have it available for screen readers:
+ * http://snook.ca/archives/html_and_css/hiding-content-for-accessibility
+ */
+
+.visuallyhidden {
+ border: 0;
+ clip: rect(0 0 0 0);
+ height: 1px;
+ margin: -1px;
+ overflow: hidden;
+ padding: 0;
+ position: absolute;
+ width: 1px;
+}
+
+/*
+ * Extends the .visuallyhidden class to allow the element
+ * to be focusable when navigated to via the keyboard:
+ * https://www.drupal.org/node/897638
+ */
+
+.visuallyhidden.focusable:active,
+.visuallyhidden.focusable:focus {
+ clip: auto;
+ height: auto;
+ margin: 0;
+ overflow: visible;
+ position: static;
+ width: auto;
+}
+
+/*
+ * Hide visually and from screen readers, but maintain layout
+ */
+
+.invisible {
+ visibility: hidden;
+}
+
+/*
+ * Clearfix: contain floats
+ *
+ * For modern browsers
+ * 1. The space content is one way to avoid an Opera bug when the
+ * `contenteditable` attribute is included anywhere else in the document.
+ * Otherwise it causes space to appear at the top and bottom of elements
+ * that receive the `clearfix` class.
+ * 2. The use of `table` rather than `block` is only necessary if using
+ * `:before` to contain the top-margins of child elements.
+ */
+
+.clearfix:before,
+.clearfix:after {
+ content: " "; /* 1 */
+ display: table; /* 2 */
+}
+
+.clearfix:after {
+ clear: both;
+}
+
+/* ==========================================================================
+ EXAMPLE Media Queries for Responsive Design.
+ These examples override the primary ('mobile first') styles.
+ Modify as content requires.
+ ========================================================================== */
+
+@media only screen and (min-width: 35em) {
+ /* Style adjustments for viewports that meet the condition */
+}
+
+@media print,
+ (-webkit-min-device-pixel-ratio: 1.25),
+ (min-resolution: 1.25dppx),
+ (min-resolution: 120dpi) {
+ /* Style adjustments for high resolution devices */
+}
+
+/* ==========================================================================
+ Print styles.
+ Inlined to avoid the additional HTTP request:
+ http://www.phpied.com/delay-loading-your-print-css/
+ ========================================================================== */
+
+@media print {
+ *,
+ *:before,
+ *:after,
+ *:first-letter,
+ *:first-line {
+ background: transparent !important;
+ color: #000 !important; /* Black prints faster:
+ http://www.sanbeiji.com/archives/953 */
+ box-shadow: none !important;
+ text-shadow: none !important;
+ }
+
+ a,
+ a:visited {
+ text-decoration: underline;
+ }
+
+ a[href]:after {
+ content: " (" attr(href) ")";
+ }
+
+ abbr[title]:after {
+ content: " (" attr(title) ")";
+ }
+
+ /*
+ * Don't show links that are fragment identifiers,
+ * or use the `javascript:` pseudo protocol
+ */
+
+ a[href^="#"]:after,
+ a[href^="javascript:"]:after {
+ content: "";
+ }
+
+ pre,
+ blockquote {
+ border: 1px solid #999;
+ page-break-inside: avoid;
+ }
+
+ /*
+ * Printing Tables:
+ * http://css-discuss.incutio.com/wiki/Printing_Tables
+ */
+
+ thead {
+ display: table-header-group;
+ }
+
+ tr,
+ img {
+ page-break-inside: avoid;
+ }
+
+ img {
+ max-width: 100% !important;
+ }
+
+ p,
+ h2,
+ h3 {
+ orphans: 3;
+ widows: 3;
+ }
+
+ h2,
+ h3 {
+ page-break-after: avoid;
+ }
+}
diff --git a/src/styles/base/normalize.css b/src/styles/base/normalize.css
new file mode 100644
index 0000000..5e5e3c8
--- /dev/null
+++ b/src/styles/base/normalize.css
@@ -0,0 +1,424 @@
+/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */
+
+/**
+ * 1. Set default font family to sans-serif.
+ * 2. Prevent iOS and IE text size adjust after device orientation change,
+ * without disabling user zoom.
+ */
+
+html {
+ font-family: sans-serif; /* 1 */
+ -ms-text-size-adjust: 100%; /* 2 */
+ -webkit-text-size-adjust: 100%; /* 2 */
+}
+
+/**
+ * Remove default margin.
+ */
+
+body {
+ margin: 0;
+}
+
+/* HTML5 display definitions
+ ========================================================================== */
+
+/**
+ * Correct `block` display not defined for any HTML5 element in IE 8/9.
+ * Correct `block` display not defined for `details` or `summary` in IE 10/11
+ * and Firefox.
+ * Correct `block` display not defined for `main` in IE 11.
+ */
+
+article,
+aside,
+details,
+figcaption,
+figure,
+footer,
+header,
+hgroup,
+main,
+menu,
+nav,
+section,
+summary {
+ display: block;
+}
+
+/**
+ * 1. Correct `inline-block` display not defined in IE 8/9.
+ * 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
+ */
+
+audio,
+canvas,
+progress,
+video {
+ display: inline-block; /* 1 */
+ vertical-align: baseline; /* 2 */
+}
+
+/**
+ * Prevent modern browsers from displaying `audio` without controls.
+ * Remove excess height in iOS 5 devices.
+ */
+
+audio:not([controls]) {
+ display: none;
+ height: 0;
+}
+
+/**
+ * Address `[hidden]` styling not present in IE 8/9/10.
+ * Hide the `template` element in IE 8/9/10/11, Safari, and Firefox < 22.
+ */
+
+[hidden],
+template {
+ display: none;
+}
+
+/* Links
+ ========================================================================== */
+
+/**
+ * Remove the gray background color from active links in IE 10.
+ */
+
+a {
+ background-color: transparent;
+}
+
+/**
+ * Improve readability of focused elements when they are also in an
+ * active/hover state.
+ */
+
+a:active,
+a:hover {
+ outline: 0;
+}
+
+/* Text-level semantics
+ ========================================================================== */
+
+/**
+ * Address styling not present in IE 8/9/10/11, Safari, and Chrome.
+ */
+
+abbr[title] {
+ border-bottom: 1px dotted;
+}
+
+/**
+ * Address style set to `bolder` in Firefox 4+, Safari, and Chrome.
+ */
+
+b,
+strong {
+ font-weight: bold;
+}
+
+/**
+ * Address styling not present in Safari and Chrome.
+ */
+
+dfn {
+ font-style: italic;
+}
+
+/**
+ * Address variable `h1` font-size and margin within `section` and `article`
+ * contexts in Firefox 4+, Safari, and Chrome.
+ */
+
+h1 {
+ font-size: 2em;
+ margin: 0.67em 0;
+}
+
+/**
+ * Address styling not present in IE 8/9.
+ */
+
+mark {
+ background: #ff0;
+ color: #000;
+}
+
+/**
+ * Address inconsistent and variable font size in all browsers.
+ */
+
+small {
+ font-size: 80%;
+}
+
+/**
+ * Prevent `sub` and `sup` affecting `line-height` in all browsers.
+ */
+
+sub,
+sup {
+ font-size: 75%;
+ line-height: 0;
+ position: relative;
+ vertical-align: baseline;
+}
+
+sup {
+ top: -0.5em;
+}
+
+sub {
+ bottom: -0.25em;
+}
+
+/* Embedded content
+ ========================================================================== */
+
+/**
+ * Remove border when inside `a` element in IE 8/9/10.
+ */
+
+img {
+ border: 0;
+}
+
+/**
+ * Correct overflow not hidden in IE 9/10/11.
+ */
+
+svg:not(:root) {
+ overflow: hidden;
+}
+
+/* Grouping content
+ ========================================================================== */
+
+/**
+ * Address margin not present in IE 8/9 and Safari.
+ */
+
+figure {
+ margin: 1em 40px;
+}
+
+/**
+ * Address differences between Firefox and other browsers.
+ */
+
+hr {
+ box-sizing: content-box;
+ height: 0;
+}
+
+/**
+ * Contain overflow in all browsers.
+ */
+
+pre {
+ overflow: auto;
+}
+
+/**
+ * Address odd `em`-unit font size rendering in all browsers.
+ */
+
+code,
+kbd,
+pre,
+samp {
+ font-family: monospace, monospace;
+ font-size: 1em;
+}
+
+/* Forms
+ ========================================================================== */
+
+/**
+ * Known limitation: by default, Chrome and Safari on OS X allow very limited
+ * styling of `select`, unless a `border` property is set.
+ */
+
+/**
+ * 1. Correct color not being inherited.
+ * Known issue: affects color of disabled elements.
+ * 2. Correct font properties not being inherited.
+ * 3. Address margins set differently in Firefox 4+, Safari, and Chrome.
+ */
+
+button,
+input,
+optgroup,
+select,
+textarea {
+ color: inherit; /* 1 */
+ font: inherit; /* 2 */
+ margin: 0; /* 3 */
+}
+
+/**
+ * Address `overflow` set to `hidden` in IE 8/9/10/11.
+ */
+
+button {
+ overflow: visible;
+}
+
+/**
+ * Address inconsistent `text-transform` inheritance for `button` and `select`.
+ * All other form control elements do not inherit `text-transform` values.
+ * Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera.
+ * Correct `select` style inheritance in Firefox.
+ */
+
+button,
+select {
+ text-transform: none;
+}
+
+/**
+ * 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
+ * and `video` controls.
+ * 2. Correct inability to style clickable `input` types in iOS.
+ * 3. Improve usability and consistency of cursor style between image-type
+ * `input` and others.
+ */
+
+button,
+html input[type="button"], /* 1 */
+input[type="reset"],
+input[type="submit"] {
+ -webkit-appearance: button; /* 2 */
+ cursor: pointer; /* 3 */
+}
+
+/**
+ * Re-set default cursor for disabled elements.
+ */
+
+button[disabled],
+html input[disabled] {
+ cursor: default;
+}
+
+/**
+ * Remove inner padding and border in Firefox 4+.
+ */
+
+button::-moz-focus-inner,
+input::-moz-focus-inner {
+ border: 0;
+ padding: 0;
+}
+
+/**
+ * Address Firefox 4+ setting `line-height` on `input` using `!important` in
+ * the UA stylesheet.
+ */
+
+input {
+ line-height: normal;
+}
+
+/**
+ * It's recommended that you don't attempt to style these elements.
+ * Firefox's implementation doesn't respect box-sizing, padding, or width.
+ *
+ * 1. Address box sizing set to `content-box` in IE 8/9/10.
+ * 2. Remove excess padding in IE 8/9/10.
+ */
+
+input[type="checkbox"],
+input[type="radio"] {
+ box-sizing: border-box; /* 1 */
+ padding: 0; /* 2 */
+}
+
+/**
+ * Fix the cursor style for Chrome's increment/decrement buttons. For certain
+ * `font-size` values of the `input`, it causes the cursor style of the
+ * decrement button to change from `default` to `text`.
+ */
+
+input[type="number"]::-webkit-inner-spin-button,
+input[type="number"]::-webkit-outer-spin-button {
+ height: auto;
+}
+
+/**
+ * 1. Address `appearance` set to `searchfield` in Safari and Chrome.
+ * 2. Address `box-sizing` set to `border-box` in Safari and Chrome.
+ */
+
+input[type="search"] {
+ -webkit-appearance: textfield; /* 1 */
+ box-sizing: content-box; /* 2 */
+}
+
+/**
+ * Remove inner padding and search cancel button in Safari and Chrome on OS X.
+ * Safari (but not Chrome) clips the cancel button when the search input has
+ * padding (and `textfield` appearance).
+ */
+
+input[type="search"]::-webkit-search-cancel-button,
+input[type="search"]::-webkit-search-decoration {
+ -webkit-appearance: none;
+}
+
+/**
+ * Define consistent border, margin, and padding.
+ */
+
+fieldset {
+ border: 1px solid #c0c0c0;
+ margin: 0 2px;
+ padding: 0.35em 0.625em 0.75em;
+}
+
+/**
+ * 1. Correct `color` not being inherited in IE 8/9/10/11.
+ * 2. Remove padding so people aren't caught out if they zero out fieldsets.
+ */
+
+legend {
+ border: 0; /* 1 */
+ padding: 0; /* 2 */
+}
+
+/**
+ * Remove default vertical scrollbar in IE 8/9/10/11.
+ */
+
+textarea {
+ overflow: auto;
+}
+
+/**
+ * Don't inherit the `font-weight` (applied by a rule above).
+ * NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
+ */
+
+optgroup {
+ font-weight: bold;
+}
+
+/* Tables
+ ========================================================================== */
+
+/**
+ * Remove most spacing between table cells.
+ */
+
+table {
+ border-collapse: collapse;
+ border-spacing: 0;
+}
+
+td,
+th {
+ padding: 0;
+}
diff --git a/src/styles/lib/reset.css b/src/styles/base/normalize.css.bat
similarity index 100%
rename from src/styles/lib/reset.css
rename to src/styles/base/normalize.css.bat
diff --git a/src/styles/lib/layui/css/layui.css b/src/styles/lib/layui/css/layui.css
new file mode 100644
index 0000000..f297bf6
--- /dev/null
+++ b/src/styles/lib/layui/css/layui.css
@@ -0,0 +1,2 @@
+/** layui-v2.4.5 MIT License By https://www.layui.com */
+ .layui-inline,img{display:inline-block;vertical-align:middle}h1,h2,h3,h4,h5,h6{font-weight:400}.layui-edge,.layui-header,.layui-inline,.layui-main{position:relative}.layui-elip,.layui-form-checkbox span,.layui-form-pane .layui-form-label{text-overflow:ellipsis;white-space:nowrap}.layui-btn,.layui-edge,.layui-inline,img{vertical-align:middle}.layui-btn,.layui-disabled,.layui-icon,.layui-unselect{-webkit-user-select:none;-ms-user-select:none;-moz-user-select:none}blockquote,body,button,dd,div,dl,dt,form,h1,h2,h3,h4,h5,h6,input,li,ol,p,pre,td,textarea,th,ul{margin:0;padding:0;-webkit-tap-highlight-color:rgba(0,0,0,0)}a:active,a:hover{outline:0}img{border:none}li{list-style:none}table{border-collapse:collapse;border-spacing:0}h4,h5,h6{font-size:100%}button,input,optgroup,option,select,textarea{font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;outline:0}pre{white-space:pre-wrap;white-space:-moz-pre-wrap;white-space:-pre-wrap;white-space:-o-pre-wrap;word-wrap:break-word}body{line-height:24px;font:14px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif}hr{height:1px;margin:10px 0;border:0;clear:both}a{color:#333;text-decoration:none}a:hover{color:#777}a cite{font-style:normal;*cursor:pointer}.layui-border-box,.layui-border-box *{box-sizing:border-box}.layui-box,.layui-box *{box-sizing:content-box}.layui-clear{clear:both;*zoom:1}.layui-clear:after{content:'\20';clear:both;*zoom:1;display:block;height:0}.layui-inline{*display:inline;*zoom:1}.layui-edge{display:inline-block;width:0;height:0;border-width:6px;border-style:dashed;border-color:transparent;overflow:hidden}.layui-edge-top{top:-4px;border-bottom-color:#999;border-bottom-style:solid}.layui-edge-right{border-left-color:#999;border-left-style:solid}.layui-edge-bottom{top:2px;border-top-color:#999;border-top-style:solid}.layui-edge-left{border-right-color:#999;border-right-style:solid}.layui-elip{overflow:hidden}.layui-disabled,.layui-disabled:hover{color:#d2d2d2!important;cursor:not-allowed!important}.layui-circle{border-radius:100%}.layui-show{display:block!important}.layui-hide{display:none!important}@font-face{font-family:layui-icon;src:url(../font/iconfont.eot?v=240);src:url(../font/iconfont.eot?v=240#iefix) format('embedded-opentype'),url(../font/iconfont.svg?v=240#iconfont) format('svg'),url(../font/iconfont.woff?v=240) format('woff'),url(../font/iconfont.ttf?v=240) format('truetype')}.layui-icon{font-family:layui-icon!important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.layui-icon-reply-fill:before{content:"\e611"}.layui-icon-set-fill:before{content:"\e614"}.layui-icon-menu-fill:before{content:"\e60f"}.layui-icon-search:before{content:"\e615"}.layui-icon-share:before{content:"\e641"}.layui-icon-set-sm:before{content:"\e620"}.layui-icon-engine:before{content:"\e628"}.layui-icon-close:before{content:"\1006"}.layui-icon-close-fill:before{content:"\1007"}.layui-icon-chart-screen:before{content:"\e629"}.layui-icon-star:before{content:"\e600"}.layui-icon-circle-dot:before{content:"\e617"}.layui-icon-chat:before{content:"\e606"}.layui-icon-release:before{content:"\e609"}.layui-icon-list:before{content:"\e60a"}.layui-icon-chart:before{content:"\e62c"}.layui-icon-ok-circle:before{content:"\1005"}.layui-icon-layim-theme:before{content:"\e61b"}.layui-icon-table:before{content:"\e62d"}.layui-icon-right:before{content:"\e602"}.layui-icon-left:before{content:"\e603"}.layui-icon-cart-simple:before{content:"\e698"}.layui-icon-face-cry:before{content:"\e69c"}.layui-icon-face-smile:before{content:"\e6af"}.layui-icon-survey:before{content:"\e6b2"}.layui-icon-tree:before{content:"\e62e"}.layui-icon-upload-circle:before{content:"\e62f"}.layui-icon-add-circle:before{content:"\e61f"}.layui-icon-download-circle:before{content:"\e601"}.layui-icon-templeate-1:before{content:"\e630"}.layui-icon-util:before{content:"\e631"}.layui-icon-face-surprised:before{content:"\e664"}.layui-icon-edit:before{content:"\e642"}.layui-icon-speaker:before{content:"\e645"}.layui-icon-down:before{content:"\e61a"}.layui-icon-file:before{content:"\e621"}.layui-icon-layouts:before{content:"\e632"}.layui-icon-rate-half:before{content:"\e6c9"}.layui-icon-add-circle-fine:before{content:"\e608"}.layui-icon-prev-circle:before{content:"\e633"}.layui-icon-read:before{content:"\e705"}.layui-icon-404:before{content:"\e61c"}.layui-icon-carousel:before{content:"\e634"}.layui-icon-help:before{content:"\e607"}.layui-icon-code-circle:before{content:"\e635"}.layui-icon-water:before{content:"\e636"}.layui-icon-username:before{content:"\e66f"}.layui-icon-find-fill:before{content:"\e670"}.layui-icon-about:before{content:"\e60b"}.layui-icon-location:before{content:"\e715"}.layui-icon-up:before{content:"\e619"}.layui-icon-pause:before{content:"\e651"}.layui-icon-date:before{content:"\e637"}.layui-icon-layim-uploadfile:before{content:"\e61d"}.layui-icon-delete:before{content:"\e640"}.layui-icon-play:before{content:"\e652"}.layui-icon-top:before{content:"\e604"}.layui-icon-friends:before{content:"\e612"}.layui-icon-refresh-3:before{content:"\e9aa"}.layui-icon-ok:before{content:"\e605"}.layui-icon-layer:before{content:"\e638"}.layui-icon-face-smile-fine:before{content:"\e60c"}.layui-icon-dollar:before{content:"\e659"}.layui-icon-group:before{content:"\e613"}.layui-icon-layim-download:before{content:"\e61e"}.layui-icon-picture-fine:before{content:"\e60d"}.layui-icon-link:before{content:"\e64c"}.layui-icon-diamond:before{content:"\e735"}.layui-icon-log:before{content:"\e60e"}.layui-icon-rate-solid:before{content:"\e67a"}.layui-icon-fonts-del:before{content:"\e64f"}.layui-icon-unlink:before{content:"\e64d"}.layui-icon-fonts-clear:before{content:"\e639"}.layui-icon-triangle-r:before{content:"\e623"}.layui-icon-circle:before{content:"\e63f"}.layui-icon-radio:before{content:"\e643"}.layui-icon-align-center:before{content:"\e647"}.layui-icon-align-right:before{content:"\e648"}.layui-icon-align-left:before{content:"\e649"}.layui-icon-loading-1:before{content:"\e63e"}.layui-icon-return:before{content:"\e65c"}.layui-icon-fonts-strong:before{content:"\e62b"}.layui-icon-upload:before{content:"\e67c"}.layui-icon-dialogue:before{content:"\e63a"}.layui-icon-video:before{content:"\e6ed"}.layui-icon-headset:before{content:"\e6fc"}.layui-icon-cellphone-fine:before{content:"\e63b"}.layui-icon-add-1:before{content:"\e654"}.layui-icon-face-smile-b:before{content:"\e650"}.layui-icon-fonts-html:before{content:"\e64b"}.layui-icon-form:before{content:"\e63c"}.layui-icon-cart:before{content:"\e657"}.layui-icon-camera-fill:before{content:"\e65d"}.layui-icon-tabs:before{content:"\e62a"}.layui-icon-fonts-code:before{content:"\e64e"}.layui-icon-fire:before{content:"\e756"}.layui-icon-set:before{content:"\e716"}.layui-icon-fonts-u:before{content:"\e646"}.layui-icon-triangle-d:before{content:"\e625"}.layui-icon-tips:before{content:"\e702"}.layui-icon-picture:before{content:"\e64a"}.layui-icon-more-vertical:before{content:"\e671"}.layui-icon-flag:before{content:"\e66c"}.layui-icon-loading:before{content:"\e63d"}.layui-icon-fonts-i:before{content:"\e644"}.layui-icon-refresh-1:before{content:"\e666"}.layui-icon-rmb:before{content:"\e65e"}.layui-icon-home:before{content:"\e68e"}.layui-icon-user:before{content:"\e770"}.layui-icon-notice:before{content:"\e667"}.layui-icon-login-weibo:before{content:"\e675"}.layui-icon-voice:before{content:"\e688"}.layui-icon-upload-drag:before{content:"\e681"}.layui-icon-login-qq:before{content:"\e676"}.layui-icon-snowflake:before{content:"\e6b1"}.layui-icon-file-b:before{content:"\e655"}.layui-icon-template:before{content:"\e663"}.layui-icon-auz:before{content:"\e672"}.layui-icon-console:before{content:"\e665"}.layui-icon-app:before{content:"\e653"}.layui-icon-prev:before{content:"\e65a"}.layui-icon-website:before{content:"\e7ae"}.layui-icon-next:before{content:"\e65b"}.layui-icon-component:before{content:"\e857"}.layui-icon-more:before{content:"\e65f"}.layui-icon-login-wechat:before{content:"\e677"}.layui-icon-shrink-right:before{content:"\e668"}.layui-icon-spread-left:before{content:"\e66b"}.layui-icon-camera:before{content:"\e660"}.layui-icon-note:before{content:"\e66e"}.layui-icon-refresh:before{content:"\e669"}.layui-icon-female:before{content:"\e661"}.layui-icon-male:before{content:"\e662"}.layui-icon-password:before{content:"\e673"}.layui-icon-senior:before{content:"\e674"}.layui-icon-theme:before{content:"\e66a"}.layui-icon-tread:before{content:"\e6c5"}.layui-icon-praise:before{content:"\e6c6"}.layui-icon-star-fill:before{content:"\e658"}.layui-icon-rate:before{content:"\e67b"}.layui-icon-template-1:before{content:"\e656"}.layui-icon-vercode:before{content:"\e679"}.layui-icon-cellphone:before{content:"\e678"}.layui-icon-screen-full:before{content:"\e622"}.layui-icon-screen-restore:before{content:"\e758"}.layui-icon-cols:before{content:"\e610"}.layui-icon-export:before{content:"\e67d"}.layui-icon-print:before{content:"\e66d"}.layui-icon-slider:before{content:"\e714"}.layui-main{width:1140px;margin:0 auto}.layui-header{z-index:1000;height:60px}.layui-header a:hover{transition:all .5s;-webkit-transition:all .5s}.layui-side{position:fixed;left:0;top:0;bottom:0;z-index:999;width:200px;overflow-x:hidden}.layui-side-scroll{position:relative;width:220px;height:100%;overflow-x:hidden}.layui-body{position:absolute;left:200px;right:0;top:0;bottom:0;z-index:998;width:auto;overflow:hidden;overflow-y:auto;box-sizing:border-box}.layui-layout-body{overflow:hidden}.layui-layout-admin .layui-header{background-color:#23262E}.layui-layout-admin .layui-side{top:60px;width:200px;overflow-x:hidden}.layui-layout-admin .layui-body{top:60px;bottom:44px}.layui-layout-admin .layui-main{width:auto;margin:0 15px}.layui-layout-admin .layui-footer{position:fixed;left:200px;right:0;bottom:0;height:44px;line-height:44px;padding:0 15px;background-color:#eee}.layui-layout-admin .layui-logo{position:absolute;left:0;top:0;width:200px;height:100%;line-height:60px;text-align:center;color:#009688;font-size:16px}.layui-layout-admin .layui-header .layui-nav{background:0 0}.layui-layout-left{position:absolute!important;left:200px;top:0}.layui-layout-right{position:absolute!important;right:0;top:0}.layui-container{position:relative;margin:0 auto;padding:0 15px;box-sizing:border-box}.layui-fluid{position:relative;margin:0 auto;padding:0 15px}.layui-row:after,.layui-row:before{content:'';display:block;clear:both}.layui-col-lg1,.layui-col-lg10,.layui-col-lg11,.layui-col-lg12,.layui-col-lg2,.layui-col-lg3,.layui-col-lg4,.layui-col-lg5,.layui-col-lg6,.layui-col-lg7,.layui-col-lg8,.layui-col-lg9,.layui-col-md1,.layui-col-md10,.layui-col-md11,.layui-col-md12,.layui-col-md2,.layui-col-md3,.layui-col-md4,.layui-col-md5,.layui-col-md6,.layui-col-md7,.layui-col-md8,.layui-col-md9,.layui-col-sm1,.layui-col-sm10,.layui-col-sm11,.layui-col-sm12,.layui-col-sm2,.layui-col-sm3,.layui-col-sm4,.layui-col-sm5,.layui-col-sm6,.layui-col-sm7,.layui-col-sm8,.layui-col-sm9,.layui-col-xs1,.layui-col-xs10,.layui-col-xs11,.layui-col-xs12,.layui-col-xs2,.layui-col-xs3,.layui-col-xs4,.layui-col-xs5,.layui-col-xs6,.layui-col-xs7,.layui-col-xs8,.layui-col-xs9{position:relative;display:block;box-sizing:border-box}.layui-col-xs1,.layui-col-xs10,.layui-col-xs11,.layui-col-xs12,.layui-col-xs2,.layui-col-xs3,.layui-col-xs4,.layui-col-xs5,.layui-col-xs6,.layui-col-xs7,.layui-col-xs8,.layui-col-xs9{float:left}.layui-col-xs1{width:8.33333333%}.layui-col-xs2{width:16.66666667%}.layui-col-xs3{width:25%}.layui-col-xs4{width:33.33333333%}.layui-col-xs5{width:41.66666667%}.layui-col-xs6{width:50%}.layui-col-xs7{width:58.33333333%}.layui-col-xs8{width:66.66666667%}.layui-col-xs9{width:75%}.layui-col-xs10{width:83.33333333%}.layui-col-xs11{width:91.66666667%}.layui-col-xs12{width:100%}.layui-col-xs-offset1{margin-left:8.33333333%}.layui-col-xs-offset2{margin-left:16.66666667%}.layui-col-xs-offset3{margin-left:25%}.layui-col-xs-offset4{margin-left:33.33333333%}.layui-col-xs-offset5{margin-left:41.66666667%}.layui-col-xs-offset6{margin-left:50%}.layui-col-xs-offset7{margin-left:58.33333333%}.layui-col-xs-offset8{margin-left:66.66666667%}.layui-col-xs-offset9{margin-left:75%}.layui-col-xs-offset10{margin-left:83.33333333%}.layui-col-xs-offset11{margin-left:91.66666667%}.layui-col-xs-offset12{margin-left:100%}@media screen and (max-width:768px){.layui-hide-xs{display:none!important}.layui-show-xs-block{display:block!important}.layui-show-xs-inline{display:inline!important}.layui-show-xs-inline-block{display:inline-block!important}}@media screen and (min-width:768px){.layui-container{width:750px}.layui-hide-sm{display:none!important}.layui-show-sm-block{display:block!important}.layui-show-sm-inline{display:inline!important}.layui-show-sm-inline-block{display:inline-block!important}.layui-col-sm1,.layui-col-sm10,.layui-col-sm11,.layui-col-sm12,.layui-col-sm2,.layui-col-sm3,.layui-col-sm4,.layui-col-sm5,.layui-col-sm6,.layui-col-sm7,.layui-col-sm8,.layui-col-sm9{float:left}.layui-col-sm1{width:8.33333333%}.layui-col-sm2{width:16.66666667%}.layui-col-sm3{width:25%}.layui-col-sm4{width:33.33333333%}.layui-col-sm5{width:41.66666667%}.layui-col-sm6{width:50%}.layui-col-sm7{width:58.33333333%}.layui-col-sm8{width:66.66666667%}.layui-col-sm9{width:75%}.layui-col-sm10{width:83.33333333%}.layui-col-sm11{width:91.66666667%}.layui-col-sm12{width:100%}.layui-col-sm-offset1{margin-left:8.33333333%}.layui-col-sm-offset2{margin-left:16.66666667%}.layui-col-sm-offset3{margin-left:25%}.layui-col-sm-offset4{margin-left:33.33333333%}.layui-col-sm-offset5{margin-left:41.66666667%}.layui-col-sm-offset6{margin-left:50%}.layui-col-sm-offset7{margin-left:58.33333333%}.layui-col-sm-offset8{margin-left:66.66666667%}.layui-col-sm-offset9{margin-left:75%}.layui-col-sm-offset10{margin-left:83.33333333%}.layui-col-sm-offset11{margin-left:91.66666667%}.layui-col-sm-offset12{margin-left:100%}}@media screen and (min-width:992px){.layui-container{width:970px}.layui-hide-md{display:none!important}.layui-show-md-block{display:block!important}.layui-show-md-inline{display:inline!important}.layui-show-md-inline-block{display:inline-block!important}.layui-col-md1,.layui-col-md10,.layui-col-md11,.layui-col-md12,.layui-col-md2,.layui-col-md3,.layui-col-md4,.layui-col-md5,.layui-col-md6,.layui-col-md7,.layui-col-md8,.layui-col-md9{float:left}.layui-col-md1{width:8.33333333%}.layui-col-md2{width:16.66666667%}.layui-col-md3{width:25%}.layui-col-md4{width:33.33333333%}.layui-col-md5{width:41.66666667%}.layui-col-md6{width:50%}.layui-col-md7{width:58.33333333%}.layui-col-md8{width:66.66666667%}.layui-col-md9{width:75%}.layui-col-md10{width:83.33333333%}.layui-col-md11{width:91.66666667%}.layui-col-md12{width:100%}.layui-col-md-offset1{margin-left:8.33333333%}.layui-col-md-offset2{margin-left:16.66666667%}.layui-col-md-offset3{margin-left:25%}.layui-col-md-offset4{margin-left:33.33333333%}.layui-col-md-offset5{margin-left:41.66666667%}.layui-col-md-offset6{margin-left:50%}.layui-col-md-offset7{margin-left:58.33333333%}.layui-col-md-offset8{margin-left:66.66666667%}.layui-col-md-offset9{margin-left:75%}.layui-col-md-offset10{margin-left:83.33333333%}.layui-col-md-offset11{margin-left:91.66666667%}.layui-col-md-offset12{margin-left:100%}}@media screen and (min-width:1200px){.layui-container{width:1170px}.layui-hide-lg{display:none!important}.layui-show-lg-block{display:block!important}.layui-show-lg-inline{display:inline!important}.layui-show-lg-inline-block{display:inline-block!important}.layui-col-lg1,.layui-col-lg10,.layui-col-lg11,.layui-col-lg12,.layui-col-lg2,.layui-col-lg3,.layui-col-lg4,.layui-col-lg5,.layui-col-lg6,.layui-col-lg7,.layui-col-lg8,.layui-col-lg9{float:left}.layui-col-lg1{width:8.33333333%}.layui-col-lg2{width:16.66666667%}.layui-col-lg3{width:25%}.layui-col-lg4{width:33.33333333%}.layui-col-lg5{width:41.66666667%}.layui-col-lg6{width:50%}.layui-col-lg7{width:58.33333333%}.layui-col-lg8{width:66.66666667%}.layui-col-lg9{width:75%}.layui-col-lg10{width:83.33333333%}.layui-col-lg11{width:91.66666667%}.layui-col-lg12{width:100%}.layui-col-lg-offset1{margin-left:8.33333333%}.layui-col-lg-offset2{margin-left:16.66666667%}.layui-col-lg-offset3{margin-left:25%}.layui-col-lg-offset4{margin-left:33.33333333%}.layui-col-lg-offset5{margin-left:41.66666667%}.layui-col-lg-offset6{margin-left:50%}.layui-col-lg-offset7{margin-left:58.33333333%}.layui-col-lg-offset8{margin-left:66.66666667%}.layui-col-lg-offset9{margin-left:75%}.layui-col-lg-offset10{margin-left:83.33333333%}.layui-col-lg-offset11{margin-left:91.66666667%}.layui-col-lg-offset12{margin-left:100%}}.layui-col-space1{margin:-.5px}.layui-col-space1>*{padding:.5px}.layui-col-space3{margin:-1.5px}.layui-col-space3>*{padding:1.5px}.layui-col-space5{margin:-2.5px}.layui-col-space5>*{padding:2.5px}.layui-col-space8{margin:-3.5px}.layui-col-space8>*{padding:3.5px}.layui-col-space10{margin:-5px}.layui-col-space10>*{padding:5px}.layui-col-space12{margin:-6px}.layui-col-space12>*{padding:6px}.layui-col-space15{margin:-7.5px}.layui-col-space15>*{padding:7.5px}.layui-col-space18{margin:-9px}.layui-col-space18>*{padding:9px}.layui-col-space20{margin:-10px}.layui-col-space20>*{padding:10px}.layui-col-space22{margin:-11px}.layui-col-space22>*{padding:11px}.layui-col-space25{margin:-12.5px}.layui-col-space25>*{padding:12.5px}.layui-col-space30{margin:-15px}.layui-col-space30>*{padding:15px}.layui-btn,.layui-input,.layui-select,.layui-textarea,.layui-upload-button{outline:0;-webkit-appearance:none;transition:all .3s;-webkit-transition:all .3s;box-sizing:border-box}.layui-elem-quote{margin-bottom:10px;padding:15px;line-height:22px;border-left:5px solid #009688;border-radius:0 2px 2px 0;background-color:#f2f2f2}.layui-quote-nm{border-style:solid;border-width:1px 1px 1px 5px;background:0 0}.layui-elem-field{margin-bottom:10px;padding:0;border-width:1px;border-style:solid}.layui-elem-field legend{margin-left:20px;padding:0 10px;font-size:20px;font-weight:300}.layui-field-title{margin:10px 0 20px;border-width:1px 0 0}.layui-field-box{padding:10px 15px}.layui-field-title .layui-field-box{padding:10px 0}.layui-progress{position:relative;height:6px;border-radius:20px;background-color:#e2e2e2}.layui-progress-bar{position:absolute;left:0;top:0;width:0;max-width:100%;height:6px;border-radius:20px;text-align:right;background-color:#5FB878;transition:all .3s;-webkit-transition:all .3s}.layui-progress-big,.layui-progress-big .layui-progress-bar{height:18px;line-height:18px}.layui-progress-text{position:relative;top:-20px;line-height:18px;font-size:12px;color:#666}.layui-progress-big .layui-progress-text{position:static;padding:0 10px;color:#fff}.layui-collapse{border-width:1px;border-style:solid;border-radius:2px}.layui-colla-content,.layui-colla-item{border-top-width:1px;border-top-style:solid}.layui-colla-item:first-child{border-top:none}.layui-colla-title{position:relative;height:42px;line-height:42px;padding:0 15px 0 35px;color:#333;background-color:#f2f2f2;cursor:pointer;font-size:14px;overflow:hidden}.layui-colla-content{display:none;padding:10px 15px;line-height:22px;color:#666}.layui-colla-icon{position:absolute;left:15px;top:0;font-size:14px}.layui-card{margin-bottom:15px;border-radius:2px;background-color:#fff;box-shadow:0 1px 2px 0 rgba(0,0,0,.05)}.layui-card:last-child{margin-bottom:0}.layui-card-header{position:relative;height:42px;line-height:42px;padding:0 15px;border-bottom:1px solid #f6f6f6;color:#333;border-radius:2px 2px 0 0;font-size:14px}.layui-bg-black,.layui-bg-blue,.layui-bg-cyan,.layui-bg-green,.layui-bg-orange,.layui-bg-red{color:#fff!important}.layui-card-body{position:relative;padding:10px 15px;line-height:24px}.layui-card-body[pad15]{padding:15px}.layui-card-body[pad20]{padding:20px}.layui-card-body .layui-table{margin:5px 0}.layui-card .layui-tab{margin:0}.layui-panel-window{position:relative;padding:15px;border-radius:0;border-top:5px solid #E6E6E6;background-color:#fff}.layui-auxiliar-moving{position:fixed;left:0;right:0;top:0;bottom:0;width:100%;height:100%;background:0 0;z-index:9999999999}.layui-form-label,.layui-form-mid,.layui-form-select,.layui-input-block,.layui-input-inline,.layui-textarea{position:relative}.layui-bg-red{background-color:#FF5722!important}.layui-bg-orange{background-color:#FFB800!important}.layui-bg-green{background-color:#009688!important}.layui-bg-cyan{background-color:#2F4056!important}.layui-bg-blue{background-color:#1E9FFF!important}.layui-bg-black{background-color:#393D49!important}.layui-bg-gray{background-color:#eee!important;color:#666!important}.layui-badge-rim,.layui-colla-content,.layui-colla-item,.layui-collapse,.layui-elem-field,.layui-form-pane .layui-form-item[pane],.layui-form-pane .layui-form-label,.layui-input,.layui-layedit,.layui-layedit-tool,.layui-quote-nm,.layui-select,.layui-tab-bar,.layui-tab-card,.layui-tab-title,.layui-tab-title .layui-this:after,.layui-textarea{border-color:#e6e6e6}.layui-timeline-item:before,hr{background-color:#e6e6e6}.layui-text{line-height:22px;font-size:14px;color:#666}.layui-text h1,.layui-text h2,.layui-text h3{font-weight:500;color:#333}.layui-text h1{font-size:30px}.layui-text h2{font-size:24px}.layui-text h3{font-size:18px}.layui-text a:not(.layui-btn){color:#01AAED}.layui-text a:not(.layui-btn):hover{text-decoration:underline}.layui-text ul{padding:5px 0 5px 15px}.layui-text ul li{margin-top:5px;list-style-type:disc}.layui-text em,.layui-word-aux{color:#999!important;padding:0 5px!important}.layui-btn{display:inline-block;height:38px;line-height:38px;padding:0 18px;background-color:#009688;color:#fff;white-space:nowrap;text-align:center;font-size:14px;border:none;border-radius:2px;cursor:pointer}.layui-btn:hover{opacity:.8;filter:alpha(opacity=80);color:#fff}.layui-btn:active{opacity:1;filter:alpha(opacity=100)}.layui-btn+.layui-btn{margin-left:10px}.layui-btn-container{font-size:0}.layui-btn-container .layui-btn{margin-right:10px;margin-bottom:10px}.layui-btn-container .layui-btn+.layui-btn{margin-left:0}.layui-table .layui-btn-container .layui-btn{margin-bottom:9px}.layui-btn-radius{border-radius:100px}.layui-btn .layui-icon{margin-right:3px;font-size:18px;vertical-align:bottom;vertical-align:middle\9}.layui-btn-primary{border:1px solid #C9C9C9;background-color:#fff;color:#555}.layui-btn-primary:hover{border-color:#009688;color:#333}.layui-btn-normal{background-color:#1E9FFF}.layui-btn-warm{background-color:#FFB800}.layui-btn-danger{background-color:#FF5722}.layui-btn-disabled,.layui-btn-disabled:active,.layui-btn-disabled:hover{border:1px solid #e6e6e6;background-color:#FBFBFB;color:#C9C9C9;cursor:not-allowed;opacity:1}.layui-btn-lg{height:44px;line-height:44px;padding:0 25px;font-size:16px}.layui-btn-sm{height:30px;line-height:30px;padding:0 10px;font-size:12px}.layui-btn-sm i{font-size:16px!important}.layui-btn-xs{height:22px;line-height:22px;padding:0 5px;font-size:12px}.layui-btn-xs i{font-size:14px!important}.layui-btn-group{display:inline-block;vertical-align:middle;font-size:0}.layui-btn-group .layui-btn{margin-left:0!important;margin-right:0!important;border-left:1px solid rgba(255,255,255,.5);border-radius:0}.layui-btn-group .layui-btn-primary{border-left:none}.layui-btn-group .layui-btn-primary:hover{border-color:#C9C9C9;color:#009688}.layui-btn-group .layui-btn:first-child{border-left:none;border-radius:2px 0 0 2px}.layui-btn-group .layui-btn-primary:first-child{border-left:1px solid #c9c9c9}.layui-btn-group .layui-btn:last-child{border-radius:0 2px 2px 0}.layui-btn-group .layui-btn+.layui-btn{margin-left:0}.layui-btn-group+.layui-btn-group{margin-left:10px}.layui-btn-fluid{width:100%}.layui-input,.layui-select,.layui-textarea{height:38px;line-height:1.3;line-height:38px\9;border-width:1px;border-style:solid;background-color:#fff;border-radius:2px}.layui-input::-webkit-input-placeholder,.layui-select::-webkit-input-placeholder,.layui-textarea::-webkit-input-placeholder{line-height:1.3}.layui-input,.layui-textarea{display:block;width:100%;padding-left:10px}.layui-input:hover,.layui-textarea:hover{border-color:#D2D2D2!important}.layui-input:focus,.layui-textarea:focus{border-color:#C9C9C9!important}.layui-textarea{min-height:100px;height:auto;line-height:20px;padding:6px 10px;resize:vertical}.layui-select{padding:0 10px}.layui-form input[type=checkbox],.layui-form input[type=radio],.layui-form select{display:none}.layui-form [lay-ignore]{display:initial}.layui-form-item{margin-bottom:15px;clear:both;*zoom:1}.layui-form-item:after{content:'\20';clear:both;*zoom:1;display:block;height:0}.layui-form-label{float:left;display:block;padding:9px 15px;width:80px;font-weight:400;line-height:20px;text-align:right}.layui-form-label-col{display:block;float:none;padding:9px 0;line-height:20px;text-align:left}.layui-form-item .layui-inline{margin-bottom:5px;margin-right:10px}.layui-input-block{margin-left:110px;min-height:36px}.layui-input-inline{display:inline-block;vertical-align:middle}.layui-form-item .layui-input-inline{float:left;width:190px;margin-right:10px}.layui-form-text .layui-input-inline{width:auto}.layui-form-mid{float:left;display:block;padding:9px 0!important;line-height:20px;margin-right:10px}.layui-form-danger+.layui-form-select .layui-input,.layui-form-danger:focus{border-color:#FF5722!important}.layui-form-select .layui-input{padding-right:30px;cursor:pointer}.layui-form-select .layui-edge{position:absolute;right:10px;top:50%;margin-top:-3px;cursor:pointer;border-width:6px;border-top-color:#c2c2c2;border-top-style:solid;transition:all .3s;-webkit-transition:all .3s}.layui-form-select dl{display:none;position:absolute;left:0;top:42px;padding:5px 0;z-index:899;min-width:100%;border:1px solid #d2d2d2;max-height:300px;overflow-y:auto;background-color:#fff;border-radius:2px;box-shadow:0 2px 4px rgba(0,0,0,.12);box-sizing:border-box}.layui-form-select dl dd,.layui-form-select dl dt{padding:0 10px;line-height:36px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.layui-form-select dl dt{font-size:12px;color:#999}.layui-form-select dl dd{cursor:pointer}.layui-form-select dl dd:hover{background-color:#f2f2f2;-webkit-transition:.5s all;transition:.5s all}.layui-form-select .layui-select-group dd{padding-left:20px}.layui-form-select dl dd.layui-select-tips{padding-left:10px!important;color:#999}.layui-form-select dl dd.layui-this{background-color:#5FB878;color:#fff}.layui-form-checkbox,.layui-form-select dl dd.layui-disabled{background-color:#fff}.layui-form-selected dl{display:block}.layui-form-checkbox,.layui-form-checkbox *,.layui-form-switch{display:inline-block;vertical-align:middle}.layui-form-selected .layui-edge{margin-top:-9px;-webkit-transform:rotate(180deg);transform:rotate(180deg);margin-top:-3px\9}:root .layui-form-selected .layui-edge{margin-top:-9px\0/IE9}.layui-form-selectup dl{top:auto;bottom:42px}.layui-select-none{margin:5px 0;text-align:center;color:#999}.layui-select-disabled .layui-disabled{border-color:#eee!important}.layui-select-disabled .layui-edge{border-top-color:#d2d2d2}.layui-form-checkbox{position:relative;height:30px;line-height:30px;margin-right:10px;padding-right:30px;cursor:pointer;font-size:0;-webkit-transition:.1s linear;transition:.1s linear;box-sizing:border-box}.layui-form-checkbox span{padding:0 10px;height:100%;font-size:14px;border-radius:2px 0 0 2px;background-color:#d2d2d2;color:#fff;overflow:hidden}.layui-form-checkbox:hover span{background-color:#c2c2c2}.layui-form-checkbox i{position:absolute;right:0;top:0;width:30px;height:28px;border:1px solid #d2d2d2;border-left:none;border-radius:0 2px 2px 0;color:#fff;font-size:20px;text-align:center}.layui-form-checkbox:hover i{border-color:#c2c2c2;color:#c2c2c2}.layui-form-checked,.layui-form-checked:hover{border-color:#5FB878}.layui-form-checked span,.layui-form-checked:hover span{background-color:#5FB878}.layui-form-checked i,.layui-form-checked:hover i{color:#5FB878}.layui-form-item .layui-form-checkbox{margin-top:4px}.layui-form-checkbox[lay-skin=primary]{height:auto!important;line-height:normal!important;min-width:18px;min-height:18px;border:none!important;margin-right:0;padding-left:28px;padding-right:0;background:0 0}.layui-form-checkbox[lay-skin=primary] span{padding-left:0;padding-right:15px;line-height:18px;background:0 0;color:#666}.layui-form-checkbox[lay-skin=primary] i{right:auto;left:0;width:16px;height:16px;line-height:16px;border:1px solid #d2d2d2;font-size:12px;border-radius:2px;background-color:#fff;-webkit-transition:.1s linear;transition:.1s linear}.layui-form-checkbox[lay-skin=primary]:hover i{border-color:#5FB878;color:#fff}.layui-form-checked[lay-skin=primary] i{border-color:#5FB878;background-color:#5FB878;color:#fff}.layui-checkbox-disbaled[lay-skin=primary] span{background:0 0!important;color:#c2c2c2}.layui-checkbox-disbaled[lay-skin=primary]:hover i{border-color:#d2d2d2}.layui-form-item .layui-form-checkbox[lay-skin=primary]{margin-top:10px}.layui-form-switch{position:relative;height:22px;line-height:22px;min-width:35px;padding:0 5px;margin-top:8px;border:1px solid #d2d2d2;border-radius:20px;cursor:pointer;background-color:#fff;-webkit-transition:.1s linear;transition:.1s linear}.layui-form-switch i{position:absolute;left:5px;top:3px;width:16px;height:16px;border-radius:20px;background-color:#d2d2d2;-webkit-transition:.1s linear;transition:.1s linear}.layui-form-switch em{position:relative;top:0;width:25px;margin-left:21px;padding:0!important;text-align:center!important;color:#999!important;font-style:normal!important;font-size:12px}.layui-form-onswitch{border-color:#5FB878;background-color:#5FB878}.layui-checkbox-disbaled,.layui-checkbox-disbaled i{border-color:#e2e2e2!important}.layui-form-onswitch i{left:100%;margin-left:-21px;background-color:#fff}.layui-form-onswitch em{margin-left:5px;margin-right:21px;color:#fff!important}.layui-checkbox-disbaled span{background-color:#e2e2e2!important}.layui-checkbox-disbaled:hover i{color:#fff!important}[lay-radio]{display:none}.layui-form-radio,.layui-form-radio *{display:inline-block;vertical-align:middle}.layui-form-radio{line-height:28px;margin:6px 10px 0 0;padding-right:10px;cursor:pointer;font-size:0}.layui-form-radio *{font-size:14px}.layui-form-radio>i{margin-right:8px;font-size:22px;color:#c2c2c2}.layui-form-radio>i:hover,.layui-form-radioed>i{color:#5FB878}.layui-radio-disbaled>i{color:#e2e2e2!important}.layui-form-pane .layui-form-label{width:110px;padding:8px 15px;height:38px;line-height:20px;border-width:1px;border-style:solid;border-radius:2px 0 0 2px;text-align:center;background-color:#FBFBFB;overflow:hidden;box-sizing:border-box}.layui-form-pane .layui-input-inline{margin-left:-1px}.layui-form-pane .layui-input-block{margin-left:110px;left:-1px}.layui-form-pane .layui-input{border-radius:0 2px 2px 0}.layui-form-pane .layui-form-text .layui-form-label{float:none;width:100%;border-radius:2px;box-sizing:border-box;text-align:left}.layui-form-pane .layui-form-text .layui-input-inline{display:block;margin:0;top:-1px;clear:both}.layui-form-pane .layui-form-text .layui-input-block{margin:0;left:0;top:-1px}.layui-form-pane .layui-form-text .layui-textarea{min-height:100px;border-radius:0 0 2px 2px}.layui-form-pane .layui-form-checkbox{margin:4px 0 4px 10px}.layui-form-pane .layui-form-radio,.layui-form-pane .layui-form-switch{margin-top:6px;margin-left:10px}.layui-form-pane .layui-form-item[pane]{position:relative;border-width:1px;border-style:solid}.layui-form-pane .layui-form-item[pane] .layui-form-label{position:absolute;left:0;top:0;height:100%;border-width:0 1px 0 0}.layui-form-pane .layui-form-item[pane] .layui-input-inline{margin-left:110px}@media screen and (max-width:450px){.layui-form-item .layui-form-label{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layui-form-item .layui-inline{display:block;margin-right:0;margin-bottom:20px;clear:both}.layui-form-item .layui-inline:after{content:'\20';clear:both;display:block;height:0}.layui-form-item .layui-input-inline{display:block;float:none;left:-3px;width:auto;margin:0 0 10px 112px}.layui-form-item .layui-input-inline+.layui-form-mid{margin-left:110px;top:-5px;padding:0}.layui-form-item .layui-form-checkbox{margin-right:5px;margin-bottom:5px}}.layui-layedit{border-width:1px;border-style:solid;border-radius:2px}.layui-layedit-tool{padding:3px 5px;border-bottom-width:1px;border-bottom-style:solid;font-size:0}.layedit-tool-fixed{position:fixed;top:0;border-top:1px solid #e2e2e2}.layui-layedit-tool .layedit-tool-mid,.layui-layedit-tool .layui-icon{display:inline-block;vertical-align:middle;text-align:center;font-size:14px}.layui-layedit-tool .layui-icon{position:relative;width:32px;height:30px;line-height:30px;margin:3px 5px;color:#777;cursor:pointer;border-radius:2px}.layui-layedit-tool .layui-icon:hover{color:#393D49}.layui-layedit-tool .layui-icon:active{color:#000}.layui-layedit-tool .layedit-tool-active{background-color:#e2e2e2;color:#000}.layui-layedit-tool .layui-disabled,.layui-layedit-tool .layui-disabled:hover{color:#d2d2d2;cursor:not-allowed}.layui-layedit-tool .layedit-tool-mid{width:1px;height:18px;margin:0 10px;background-color:#d2d2d2}.layedit-tool-html{width:50px!important;font-size:30px!important}.layedit-tool-b,.layedit-tool-code,.layedit-tool-help{font-size:16px!important}.layedit-tool-d,.layedit-tool-face,.layedit-tool-image,.layedit-tool-unlink{font-size:18px!important}.layedit-tool-image input{position:absolute;font-size:0;left:0;top:0;width:100%;height:100%;opacity:.01;filter:Alpha(opacity=1);cursor:pointer}.layui-layedit-iframe iframe{display:block;width:100%}#LAY_layedit_code{overflow:hidden}.layui-laypage{display:inline-block;*display:inline;*zoom:1;vertical-align:middle;margin:10px 0;font-size:0}.layui-laypage>a:first-child,.layui-laypage>a:first-child em{border-radius:2px 0 0 2px}.layui-laypage>a:last-child,.layui-laypage>a:last-child em{border-radius:0 2px 2px 0}.layui-laypage>:first-child{margin-left:0!important}.layui-laypage>:last-child{margin-right:0!important}.layui-laypage a,.layui-laypage button,.layui-laypage input,.layui-laypage select,.layui-laypage span{border:1px solid #e2e2e2}.layui-laypage a,.layui-laypage span{display:inline-block;*display:inline;*zoom:1;vertical-align:middle;padding:0 15px;height:28px;line-height:28px;margin:0 -1px 5px 0;background-color:#fff;color:#333;font-size:12px}.layui-flow-more a *,.layui-laypage input,.layui-table-view select[lay-ignore]{display:inline-block}.layui-laypage a:hover{color:#009688}.layui-laypage em{font-style:normal}.layui-laypage .layui-laypage-spr{color:#999;font-weight:700}.layui-laypage a{text-decoration:none}.layui-laypage .layui-laypage-curr{position:relative}.layui-laypage .layui-laypage-curr em{position:relative;color:#fff}.layui-laypage .layui-laypage-curr .layui-laypage-em{position:absolute;left:-1px;top:-1px;padding:1px;width:100%;height:100%;background-color:#009688}.layui-laypage-em{border-radius:2px}.layui-laypage-next em,.layui-laypage-prev em{font-family:Sim sun;font-size:16px}.layui-laypage .layui-laypage-count,.layui-laypage .layui-laypage-limits,.layui-laypage .layui-laypage-refresh,.layui-laypage .layui-laypage-skip{margin-left:10px;margin-right:10px;padding:0;border:none}.layui-laypage .layui-laypage-limits,.layui-laypage .layui-laypage-refresh{vertical-align:top}.layui-laypage .layui-laypage-refresh i{font-size:18px;cursor:pointer}.layui-laypage select{height:22px;padding:3px;border-radius:2px;cursor:pointer}.layui-laypage .layui-laypage-skip{height:30px;line-height:30px;color:#999}.layui-laypage button,.layui-laypage input{height:30px;line-height:30px;border-radius:2px;vertical-align:top;background-color:#fff;box-sizing:border-box}.layui-laypage input{width:40px;margin:0 10px;padding:0 3px;text-align:center}.layui-laypage input:focus,.layui-laypage select:focus{border-color:#009688!important}.layui-laypage button{margin-left:10px;padding:0 10px;cursor:pointer}.layui-table,.layui-table-view{margin:10px 0}.layui-flow-more{margin:10px 0;text-align:center;color:#999;font-size:14px}.layui-flow-more a{height:32px;line-height:32px}.layui-flow-more a *{vertical-align:top}.layui-flow-more a cite{padding:0 20px;border-radius:3px;background-color:#eee;color:#333;font-style:normal}.layui-flow-more a cite:hover{opacity:.8}.layui-flow-more a i{font-size:30px;color:#737383}.layui-table{width:100%;background-color:#fff;color:#666}.layui-table tr{transition:all .3s;-webkit-transition:all .3s}.layui-table th{text-align:left;font-weight:400}.layui-table tbody tr:hover,.layui-table thead tr,.layui-table-click,.layui-table-header,.layui-table-hover,.layui-table-mend,.layui-table-patch,.layui-table-tool,.layui-table-total,.layui-table-total tr,.layui-table[lay-even] tr:nth-child(even){background-color:#f2f2f2}.layui-table td,.layui-table th,.layui-table-col-set,.layui-table-fixed-r,.layui-table-grid-down,.layui-table-header,.layui-table-page,.layui-table-tips-main,.layui-table-tool,.layui-table-total,.layui-table-view,.layui-table[lay-skin=line],.layui-table[lay-skin=row]{border-width:1px;border-style:solid;border-color:#e6e6e6}.layui-table td,.layui-table th{position:relative;padding:9px 15px;min-height:20px;line-height:20px;font-size:14px}.layui-table[lay-skin=line] td,.layui-table[lay-skin=line] th{border-width:0 0 1px}.layui-table[lay-skin=row] td,.layui-table[lay-skin=row] th{border-width:0 1px 0 0}.layui-table[lay-skin=nob] td,.layui-table[lay-skin=nob] th{border:none}.layui-table img{max-width:100px}.layui-table[lay-size=lg] td,.layui-table[lay-size=lg] th{padding:15px 30px}.layui-table-view .layui-table[lay-size=lg] .layui-table-cell{height:40px;line-height:40px}.layui-table[lay-size=sm] td,.layui-table[lay-size=sm] th{font-size:12px;padding:5px 10px}.layui-table-view .layui-table[lay-size=sm] .layui-table-cell{height:20px;line-height:20px}.layui-table[lay-data]{display:none}.layui-table-box{position:relative;overflow:hidden}.layui-table-view .layui-table{position:relative;width:auto;margin:0}.layui-table-view .layui-table[lay-skin=line]{border-width:0 1px 0 0}.layui-table-view .layui-table[lay-skin=row]{border-width:0 0 1px}.layui-table-view .layui-table td,.layui-table-view .layui-table th{padding:5px 0;border-top:none;border-left:none}.layui-table-view .layui-table th.layui-unselect .layui-table-cell span{cursor:pointer}.layui-table-view .layui-table td{cursor:default}.layui-table-view .layui-form-checkbox[lay-skin=primary] i{width:18px;height:18px}.layui-table-view .layui-form-radio{line-height:0;padding:0}.layui-table-view .layui-form-radio>i{margin:0;font-size:20px}.layui-table-init{position:absolute;left:0;top:0;width:100%;height:100%;text-align:center;z-index:110}.layui-table-init .layui-icon{position:absolute;left:50%;top:50%;margin:-15px 0 0 -15px;font-size:30px;color:#c2c2c2}.layui-table-header{border-width:0 0 1px;overflow:hidden}.layui-table-header .layui-table{margin-bottom:-1px}.layui-table-tool .layui-inline[lay-event]{position:relative;width:26px;height:26px;padding:5px;line-height:16px;margin-right:10px;text-align:center;color:#333;border:1px solid #ccc;cursor:pointer;-webkit-transition:.5s all;transition:.5s all}.layui-table-tool .layui-inline[lay-event]:hover{border:1px solid #999}.layui-table-tool-temp{padding-right:120px}.layui-table-tool-self{position:absolute;right:17px;top:10px}.layui-table-tool .layui-table-tool-self .layui-inline[lay-event]{margin:0 0 0 10px}.layui-table-tool-panel{position:absolute;top:29px;left:-1px;padding:5px 0;min-width:150px;min-height:40px;border:1px solid #d2d2d2;text-align:left;overflow-y:auto;background-color:#fff;box-shadow:0 2px 4px rgba(0,0,0,.12)}.layui-table-cell,.layui-table-tool-panel li{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.layui-table-tool-panel li{padding:0 10px;line-height:30px;-webkit-transition:.5s all;transition:.5s all}.layui-table-tool-panel li .layui-form-checkbox[lay-skin=primary]{width:100%;padding-left:28px}.layui-table-tool-panel li:hover{background-color:#f2f2f2}.layui-table-tool-panel li .layui-form-checkbox[lay-skin=primary] i{position:absolute;left:0;top:0}.layui-table-tool-panel li .layui-form-checkbox[lay-skin=primary] span{padding:0}.layui-table-tool .layui-table-tool-self .layui-table-tool-panel{left:auto;right:-1px}.layui-table-col-set{position:absolute;right:0;top:0;width:20px;height:100%;border-width:0 0 0 1px;background-color:#fff}.layui-table-sort{width:10px;height:20px;margin-left:5px;cursor:pointer!important}.layui-table-sort .layui-edge{position:absolute;left:5px;border-width:5px}.layui-table-sort .layui-table-sort-asc{top:3px;border-top:none;border-bottom-style:solid;border-bottom-color:#b2b2b2}.layui-table-sort .layui-table-sort-asc:hover{border-bottom-color:#666}.layui-table-sort .layui-table-sort-desc{bottom:5px;border-bottom:none;border-top-style:solid;border-top-color:#b2b2b2}.layui-table-sort .layui-table-sort-desc:hover{border-top-color:#666}.layui-table-sort[lay-sort=asc] .layui-table-sort-asc{border-bottom-color:#000}.layui-table-sort[lay-sort=desc] .layui-table-sort-desc{border-top-color:#000}.layui-table-cell{height:28px;line-height:28px;padding:0 15px;position:relative;box-sizing:border-box}.layui-table-cell .layui-form-checkbox[lay-skin=primary]{top:-1px;padding:0}.layui-table-cell .layui-table-link{color:#01AAED}.laytable-cell-checkbox,.laytable-cell-numbers,.laytable-cell-radio,.laytable-cell-space{padding:0;text-align:center}.layui-table-body{position:relative;overflow:auto;margin-right:-1px;margin-bottom:-1px}.layui-table-body .layui-none{line-height:26px;padding:15px;text-align:center;color:#999}.layui-table-fixed{position:absolute;left:0;top:0;z-index:101}.layui-table-fixed .layui-table-body{overflow:hidden}.layui-table-fixed-l{box-shadow:0 -1px 8px rgba(0,0,0,.08)}.layui-table-fixed-r{left:auto;right:-1px;border-width:0 0 0 1px;box-shadow:-1px 0 8px rgba(0,0,0,.08)}.layui-table-fixed-r .layui-table-header{position:relative;overflow:visible}.layui-table-mend{position:absolute;right:-49px;top:0;height:100%;width:50px}.layui-table-tool{position:relative;z-index:890;width:100%;min-height:50px;line-height:30px;padding:10px 15px;border-width:0 0 1px}.layui-table-tool .layui-btn-container{margin-bottom:-10px}.layui-table-page,.layui-table-total{border-width:1px 0 0;margin-bottom:-1px;overflow:hidden}.layui-table-page{position:relative;width:100%;padding:7px 7px 0;height:41px;font-size:12px;white-space:nowrap}.layui-table-page>div{height:26px}.layui-table-page .layui-laypage{margin:0}.layui-table-page .layui-laypage a,.layui-table-page .layui-laypage span{height:26px;line-height:26px;margin-bottom:10px;border:none;background:0 0}.layui-table-page .layui-laypage a,.layui-table-page .layui-laypage span.layui-laypage-curr{padding:0 12px}.layui-table-page .layui-laypage span{margin-left:0;padding:0}.layui-table-page .layui-laypage .layui-laypage-prev{margin-left:-7px!important}.layui-table-page .layui-laypage .layui-laypage-curr .layui-laypage-em{left:0;top:0;padding:0}.layui-table-page .layui-laypage button,.layui-table-page .layui-laypage input{height:26px;line-height:26px}.layui-table-page .layui-laypage input{width:40px}.layui-table-page .layui-laypage button{padding:0 10px}.layui-table-page select{height:18px}.layui-table-patch .layui-table-cell{padding:0;width:30px}.layui-table-edit{position:absolute;left:0;top:0;width:100%;height:100%;padding:0 14px 1px;border-radius:0;box-shadow:1px 1px 20px rgba(0,0,0,.15)}.layui-table-edit:focus{border-color:#5FB878!important}select.layui-table-edit{padding:0 0 0 10px;border-color:#C9C9C9}.layui-table-view .layui-form-checkbox,.layui-table-view .layui-form-radio,.layui-table-view .layui-form-switch{top:0;margin:0;box-sizing:content-box}.layui-table-view .layui-form-checkbox{top:-1px;height:26px;line-height:26px}.layui-table-view .layui-form-checkbox i{height:26px}.layui-table-grid .layui-table-cell{overflow:visible}.layui-table-grid-down{position:absolute;top:0;right:0;width:26px;height:100%;padding:5px 0;border-width:0 0 0 1px;text-align:center;background-color:#fff;color:#999;cursor:pointer}.layui-table-grid-down .layui-icon{position:absolute;top:50%;left:50%;margin:-8px 0 0 -8px}.layui-table-grid-down:hover{background-color:#fbfbfb}body .layui-table-tips .layui-layer-content{background:0 0;padding:0;box-shadow:0 1px 6px rgba(0,0,0,.12)}.layui-table-tips-main{margin:-44px 0 0 -1px;max-height:150px;padding:8px 15px;font-size:14px;overflow-y:scroll;background-color:#fff;color:#666}.layui-table-tips-c{position:absolute;right:-3px;top:-13px;width:20px;height:20px;padding:3px;cursor:pointer;background-color:#666;border-radius:50%;color:#fff}.layui-table-tips-c:hover{background-color:#777}.layui-table-tips-c:before{position:relative;right:-2px}.layui-upload-file{display:none!important;opacity:.01;filter:Alpha(opacity=1)}.layui-upload-drag,.layui-upload-form,.layui-upload-wrap{display:inline-block}.layui-upload-list{margin:10px 0}.layui-upload-choose{padding:0 10px;color:#999}.layui-upload-drag{position:relative;padding:30px;border:1px dashed #e2e2e2;background-color:#fff;text-align:center;cursor:pointer;color:#999}.layui-upload-drag .layui-icon{font-size:50px;color:#009688}.layui-upload-drag[lay-over]{border-color:#009688}.layui-upload-iframe{position:absolute;width:0;height:0;border:0;visibility:hidden}.layui-upload-wrap{position:relative;vertical-align:middle}.layui-upload-wrap .layui-upload-file{display:block!important;position:absolute;left:0;top:0;z-index:10;font-size:100px;width:100%;height:100%;opacity:.01;filter:Alpha(opacity=1);cursor:pointer}.layui-tree{line-height:26px}.layui-tree li{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layui-tree li .layui-tree-spread,.layui-tree li a{display:inline-block;vertical-align:top;height:26px;*display:inline;*zoom:1;cursor:pointer}.layui-tree li a{font-size:0}.layui-tree li a i{font-size:16px}.layui-tree li a cite{padding:0 6px;font-size:14px;font-style:normal}.layui-tree li i{padding-left:6px;color:#333;-moz-user-select:none}.layui-tree li .layui-tree-check{font-size:13px}.layui-tree li .layui-tree-check:hover{color:#009E94}.layui-tree li ul{display:none;margin-left:20px}.layui-tree li .layui-tree-enter{line-height:24px;border:1px dotted #000}.layui-tree-drag{display:none;position:absolute;left:-666px;top:-666px;background-color:#f2f2f2;padding:5px 10px;border:1px dotted #000;white-space:nowrap}.layui-tree-drag i{padding-right:5px}.layui-nav{position:relative;padding:0 20px;background-color:#393D49;color:#fff;border-radius:2px;font-size:0;box-sizing:border-box}.layui-nav *{font-size:14px}.layui-nav .layui-nav-item{position:relative;display:inline-block;*display:inline;*zoom:1;vertical-align:middle;line-height:60px}.layui-nav .layui-nav-item a{display:block;padding:0 20px;color:#fff;color:rgba(255,255,255,.7);transition:all .3s;-webkit-transition:all .3s}.layui-nav .layui-this:after,.layui-nav-bar,.layui-nav-tree .layui-nav-itemed:after{position:absolute;left:0;top:0;width:0;height:5px;background-color:#5FB878;transition:all .2s;-webkit-transition:all .2s}.layui-nav-bar{z-index:1000}.layui-nav .layui-nav-item a:hover,.layui-nav .layui-this a{color:#fff}.layui-nav .layui-this:after{content:'';top:auto;bottom:0;width:100%}.layui-nav-img{width:30px;height:30px;margin-right:10px;border-radius:50%}.layui-nav .layui-nav-more{content:'';width:0;height:0;border-style:solid dashed dashed;border-color:#fff transparent transparent;overflow:hidden;cursor:pointer;transition:all .2s;-webkit-transition:all .2s;position:absolute;top:50%;right:3px;margin-top:-3px;border-width:6px;border-top-color:rgba(255,255,255,.7)}.layui-nav .layui-nav-mored,.layui-nav-itemed>a .layui-nav-more{margin-top:-9px;border-style:dashed dashed solid;border-color:transparent transparent #fff}.layui-nav-child{display:none;position:absolute;left:0;top:65px;min-width:100%;line-height:36px;padding:5px 0;box-shadow:0 2px 4px rgba(0,0,0,.12);border:1px solid #d2d2d2;background-color:#fff;z-index:100;border-radius:2px;white-space:nowrap}.layui-nav .layui-nav-child a{color:#333}.layui-nav .layui-nav-child a:hover{background-color:#f2f2f2;color:#000}.layui-nav-child dd{position:relative}.layui-nav .layui-nav-child dd.layui-this a,.layui-nav-child dd.layui-this{background-color:#5FB878;color:#fff}.layui-nav-child dd.layui-this:after{display:none}.layui-nav-tree{width:200px;padding:0}.layui-nav-tree .layui-nav-item{display:block;width:100%;line-height:45px}.layui-nav-tree .layui-nav-item a{position:relative;height:45px;line-height:45px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layui-nav-tree .layui-nav-item a:hover{background-color:#4E5465}.layui-nav-tree .layui-nav-bar{width:5px;height:0;background-color:#009688}.layui-nav-tree .layui-nav-child dd.layui-this,.layui-nav-tree .layui-nav-child dd.layui-this a,.layui-nav-tree .layui-this,.layui-nav-tree .layui-this>a,.layui-nav-tree .layui-this>a:hover{background-color:#009688;color:#fff}.layui-nav-tree .layui-this:after{display:none}.layui-nav-itemed>a,.layui-nav-tree .layui-nav-title a,.layui-nav-tree .layui-nav-title a:hover{color:#fff!important}.layui-nav-tree .layui-nav-child{position:relative;z-index:0;top:0;border:none;box-shadow:none}.layui-nav-tree .layui-nav-child a{height:40px;line-height:40px;color:#fff;color:rgba(255,255,255,.7)}.layui-nav-tree .layui-nav-child,.layui-nav-tree .layui-nav-child a:hover{background:0 0;color:#fff}.layui-nav-tree .layui-nav-more{right:10px}.layui-nav-itemed>.layui-nav-child{display:block;padding:0;background-color:rgba(0,0,0,.3)!important}.layui-nav-itemed>.layui-nav-child>.layui-this>.layui-nav-child{display:block}.layui-nav-side{position:fixed;top:0;bottom:0;left:0;overflow-x:hidden;z-index:999}.layui-bg-blue .layui-nav-bar,.layui-bg-blue .layui-nav-itemed:after,.layui-bg-blue .layui-this:after{background-color:#93D1FF}.layui-bg-blue .layui-nav-child dd.layui-this{background-color:#1E9FFF}.layui-bg-blue .layui-nav-itemed>a,.layui-nav-tree.layui-bg-blue .layui-nav-title a,.layui-nav-tree.layui-bg-blue .layui-nav-title a:hover{background-color:#007DDB!important}.layui-breadcrumb{visibility:hidden;font-size:0}.layui-breadcrumb>*{font-size:14px}.layui-breadcrumb a{color:#999!important}.layui-breadcrumb a:hover{color:#5FB878!important}.layui-breadcrumb a cite{color:#666;font-style:normal}.layui-breadcrumb span[lay-separator]{margin:0 10px;color:#999}.layui-tab{margin:10px 0;text-align:left!important}.layui-tab[overflow]>.layui-tab-title{overflow:hidden}.layui-tab-title{position:relative;left:0;height:40px;white-space:nowrap;font-size:0;border-bottom-width:1px;border-bottom-style:solid;transition:all .2s;-webkit-transition:all .2s}.layui-tab-title li{display:inline-block;*display:inline;*zoom:1;vertical-align:middle;font-size:14px;transition:all .2s;-webkit-transition:all .2s;position:relative;line-height:40px;min-width:65px;padding:0 15px;text-align:center;cursor:pointer}.layui-tab-title li a{display:block}.layui-tab-title .layui-this{color:#000}.layui-tab-title .layui-this:after{position:absolute;left:0;top:0;content:'';width:100%;height:41px;border-width:1px;border-style:solid;border-bottom-color:#fff;border-radius:2px 2px 0 0;box-sizing:border-box;pointer-events:none}.layui-tab-bar{position:absolute;right:0;top:0;z-index:10;width:30px;height:39px;line-height:39px;border-width:1px;border-style:solid;border-radius:2px;text-align:center;background-color:#fff;cursor:pointer}.layui-tab-bar .layui-icon{position:relative;display:inline-block;top:3px;transition:all .3s;-webkit-transition:all .3s}.layui-tab-item{display:none}.layui-tab-more{padding-right:30px;height:auto!important;white-space:normal!important}.layui-tab-more li.layui-this:after{border-bottom-color:#e2e2e2;border-radius:2px}.layui-tab-more .layui-tab-bar .layui-icon{top:-2px;top:3px\9;-webkit-transform:rotate(180deg);transform:rotate(180deg)}:root .layui-tab-more .layui-tab-bar .layui-icon{top:-2px\0/IE9}.layui-tab-content{padding:10px}.layui-tab-title li .layui-tab-close{position:relative;display:inline-block;width:18px;height:18px;line-height:20px;margin-left:8px;top:1px;text-align:center;font-size:14px;color:#c2c2c2;transition:all .2s;-webkit-transition:all .2s}.layui-tab-title li .layui-tab-close:hover{border-radius:2px;background-color:#FF5722;color:#fff}.layui-tab-brief>.layui-tab-title .layui-this{color:#009688}.layui-tab-brief>.layui-tab-more li.layui-this:after,.layui-tab-brief>.layui-tab-title .layui-this:after{border:none;border-radius:0;border-bottom:2px solid #5FB878}.layui-tab-brief[overflow]>.layui-tab-title .layui-this:after{top:-1px}.layui-tab-card{border-width:1px;border-style:solid;border-radius:2px;box-shadow:0 2px 5px 0 rgba(0,0,0,.1)}.layui-tab-card>.layui-tab-title{background-color:#f2f2f2}.layui-tab-card>.layui-tab-title li{margin-right:-1px;margin-left:-1px}.layui-tab-card>.layui-tab-title .layui-this{background-color:#fff}.layui-tab-card>.layui-tab-title .layui-this:after{border-top:none;border-width:1px;border-bottom-color:#fff}.layui-tab-card>.layui-tab-title .layui-tab-bar{height:40px;line-height:40px;border-radius:0;border-top:none;border-right:none}.layui-tab-card>.layui-tab-more .layui-this{background:0 0;color:#5FB878}.layui-tab-card>.layui-tab-more .layui-this:after{border:none}.layui-timeline{padding-left:5px}.layui-timeline-item{position:relative;padding-bottom:20px}.layui-timeline-axis{position:absolute;left:-5px;top:0;z-index:10;width:20px;height:20px;line-height:20px;background-color:#fff;color:#5FB878;border-radius:50%;text-align:center;cursor:pointer}.layui-timeline-axis:hover{color:#FF5722}.layui-timeline-item:before{content:'';position:absolute;left:5px;top:0;z-index:0;width:1px;height:100%}.layui-timeline-item:last-child:before{display:none}.layui-timeline-item:first-child:before{display:block}.layui-timeline-content{padding-left:25px}.layui-timeline-title{position:relative;margin-bottom:10px}.layui-badge,.layui-badge-dot,.layui-badge-rim{position:relative;display:inline-block;padding:0 6px;font-size:12px;text-align:center;background-color:#FF5722;color:#fff;border-radius:2px}.layui-badge{height:18px;line-height:18px}.layui-badge-dot{width:8px;height:8px;padding:0;border-radius:50%}.layui-badge-rim{height:18px;line-height:18px;border-width:1px;border-style:solid;background-color:#fff;color:#666}.layui-btn .layui-badge,.layui-btn .layui-badge-dot{margin-left:5px}.layui-nav .layui-badge,.layui-nav .layui-badge-dot{position:absolute;top:50%;margin:-8px 6px 0}.layui-tab-title .layui-badge,.layui-tab-title .layui-badge-dot{left:5px;top:-2px}.layui-carousel{position:relative;left:0;top:0;background-color:#f8f8f8}.layui-carousel>[carousel-item]{position:relative;width:100%;height:100%;overflow:hidden}.layui-carousel>[carousel-item]:before{position:absolute;content:'\e63d';left:50%;top:50%;width:100px;line-height:20px;margin:-10px 0 0 -50px;text-align:center;color:#c2c2c2;font-family:layui-icon!important;font-size:30px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.layui-carousel>[carousel-item]>*{display:none;position:absolute;left:0;top:0;width:100%;height:100%;background-color:#f8f8f8;transition-duration:.3s;-webkit-transition-duration:.3s}.layui-carousel-updown>*{-webkit-transition:.3s ease-in-out up;transition:.3s ease-in-out up}.layui-carousel-arrow{display:none\9;opacity:0;position:absolute;left:10px;top:50%;margin-top:-18px;width:36px;height:36px;line-height:36px;text-align:center;font-size:20px;border:0;border-radius:50%;background-color:rgba(0,0,0,.2);color:#fff;-webkit-transition-duration:.3s;transition-duration:.3s;cursor:pointer}.layui-carousel-arrow[lay-type=add]{left:auto!important;right:10px}.layui-carousel:hover .layui-carousel-arrow[lay-type=add],.layui-carousel[lay-arrow=always] .layui-carousel-arrow[lay-type=add]{right:20px}.layui-carousel[lay-arrow=always] .layui-carousel-arrow{opacity:1;left:20px}.layui-carousel[lay-arrow=none] .layui-carousel-arrow{display:none}.layui-carousel-arrow:hover,.layui-carousel-ind ul:hover{background-color:rgba(0,0,0,.35)}.layui-carousel:hover .layui-carousel-arrow{display:block\9;opacity:1;left:20px}.layui-carousel-ind{position:relative;top:-35px;width:100%;line-height:0!important;text-align:center;font-size:0}.layui-carousel[lay-indicator=outside]{margin-bottom:30px}.layui-carousel[lay-indicator=outside] .layui-carousel-ind{top:10px}.layui-carousel[lay-indicator=outside] .layui-carousel-ind ul{background-color:rgba(0,0,0,.5)}.layui-carousel[lay-indicator=none] .layui-carousel-ind{display:none}.layui-carousel-ind ul{display:inline-block;padding:5px;background-color:rgba(0,0,0,.2);border-radius:10px;-webkit-transition-duration:.3s;transition-duration:.3s}.layui-carousel-ind li{display:inline-block;width:10px;height:10px;margin:0 3px;font-size:14px;background-color:#e2e2e2;background-color:rgba(255,255,255,.5);border-radius:50%;cursor:pointer;-webkit-transition-duration:.3s;transition-duration:.3s}.layui-carousel-ind li:hover{background-color:rgba(255,255,255,.7)}.layui-carousel-ind li.layui-this{background-color:#fff}.layui-carousel>[carousel-item]>.layui-carousel-next,.layui-carousel>[carousel-item]>.layui-carousel-prev,.layui-carousel>[carousel-item]>.layui-this{display:block}.layui-carousel>[carousel-item]>.layui-this{left:0}.layui-carousel>[carousel-item]>.layui-carousel-prev{left:-100%}.layui-carousel>[carousel-item]>.layui-carousel-next{left:100%}.layui-carousel>[carousel-item]>.layui-carousel-next.layui-carousel-left,.layui-carousel>[carousel-item]>.layui-carousel-prev.layui-carousel-right{left:0}.layui-carousel>[carousel-item]>.layui-this.layui-carousel-left{left:-100%}.layui-carousel>[carousel-item]>.layui-this.layui-carousel-right{left:100%}.layui-carousel[lay-anim=updown] .layui-carousel-arrow{left:50%!important;top:20px;margin:0 0 0 -18px}.layui-carousel[lay-anim=updown]>[carousel-item]>*,.layui-carousel[lay-anim=fade]>[carousel-item]>*{left:0!important}.layui-carousel[lay-anim=updown] .layui-carousel-arrow[lay-type=add]{top:auto!important;bottom:20px}.layui-carousel[lay-anim=updown] .layui-carousel-ind{position:absolute;top:50%;right:20px;width:auto;height:auto}.layui-carousel[lay-anim=updown] .layui-carousel-ind ul{padding:3px 5px}.layui-carousel[lay-anim=updown] .layui-carousel-ind li{display:block;margin:6px 0}.layui-carousel[lay-anim=updown]>[carousel-item]>.layui-this{top:0}.layui-carousel[lay-anim=updown]>[carousel-item]>.layui-carousel-prev{top:-100%}.layui-carousel[lay-anim=updown]>[carousel-item]>.layui-carousel-next{top:100%}.layui-carousel[lay-anim=updown]>[carousel-item]>.layui-carousel-next.layui-carousel-left,.layui-carousel[lay-anim=updown]>[carousel-item]>.layui-carousel-prev.layui-carousel-right{top:0}.layui-carousel[lay-anim=updown]>[carousel-item]>.layui-this.layui-carousel-left{top:-100%}.layui-carousel[lay-anim=updown]>[carousel-item]>.layui-this.layui-carousel-right{top:100%}.layui-carousel[lay-anim=fade]>[carousel-item]>.layui-carousel-next,.layui-carousel[lay-anim=fade]>[carousel-item]>.layui-carousel-prev{opacity:0}.layui-carousel[lay-anim=fade]>[carousel-item]>.layui-carousel-next.layui-carousel-left,.layui-carousel[lay-anim=fade]>[carousel-item]>.layui-carousel-prev.layui-carousel-right{opacity:1}.layui-carousel[lay-anim=fade]>[carousel-item]>.layui-this.layui-carousel-left,.layui-carousel[lay-anim=fade]>[carousel-item]>.layui-this.layui-carousel-right{opacity:0}.layui-fixbar{position:fixed;right:15px;bottom:15px;z-index:999999}.layui-fixbar li{width:50px;height:50px;line-height:50px;margin-bottom:1px;text-align:center;cursor:pointer;font-size:30px;background-color:#9F9F9F;color:#fff;border-radius:2px;opacity:.95}.layui-fixbar li:hover{opacity:.85}.layui-fixbar li:active{opacity:1}.layui-fixbar .layui-fixbar-top{display:none;font-size:40px}body .layui-util-face{border:none;background:0 0}body .layui-util-face .layui-layer-content{padding:0;background-color:#fff;color:#666;box-shadow:none}.layui-util-face .layui-layer-TipsG{display:none}.layui-util-face ul{position:relative;width:372px;padding:10px;border:1px solid #D9D9D9;background-color:#fff;box-shadow:0 0 20px rgba(0,0,0,.2)}.layui-util-face ul li{cursor:pointer;float:left;border:1px solid #e8e8e8;height:22px;width:26px;overflow:hidden;margin:-1px 0 0 -1px;padding:4px 2px;text-align:center}.layui-util-face ul li:hover{position:relative;z-index:2;border:1px solid #eb7350;background:#fff9ec}.layui-code{position:relative;margin:10px 0;padding:15px;line-height:20px;border:1px solid #ddd;border-left-width:6px;background-color:#F2F2F2;color:#333;font-family:Courier New;font-size:12px}.layui-rate,.layui-rate *{display:inline-block;vertical-align:middle}.layui-rate{padding:10px 5px 10px 0;font-size:0}.layui-rate li i.layui-icon{font-size:20px;color:#FFB800;margin-right:5px;transition:all .3s;-webkit-transition:all .3s}.layui-rate li i:hover{cursor:pointer;transform:scale(1.12);-webkit-transform:scale(1.12)}.layui-rate[readonly] li i:hover{cursor:default;transform:scale(1)}.layui-colorpicker{width:26px;height:26px;border:1px solid #e6e6e6;padding:5px;border-radius:2px;line-height:24px;display:inline-block;cursor:pointer;transition:all .3s;-webkit-transition:all .3s}.layui-colorpicker:hover{border-color:#d2d2d2}.layui-colorpicker.layui-colorpicker-lg{width:34px;height:34px;line-height:32px}.layui-colorpicker.layui-colorpicker-sm{width:24px;height:24px;line-height:22px}.layui-colorpicker.layui-colorpicker-xs{width:22px;height:22px;line-height:20px}.layui-colorpicker-trigger-bgcolor{display:block;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==);border-radius:2px}.layui-colorpicker-trigger-span{display:block;height:100%;box-sizing:border-box;border:1px solid rgba(0,0,0,.15);border-radius:2px;text-align:center}.layui-colorpicker-trigger-i{display:inline-block;color:#FFF;font-size:12px}.layui-colorpicker-trigger-i.layui-icon-close{color:#999}.layui-colorpicker-main{position:absolute;z-index:66666666;width:280px;padding:7px;background:#FFF;border:1px solid #d2d2d2;border-radius:2px;box-shadow:0 2px 4px rgba(0,0,0,.12)}.layui-colorpicker-main-wrapper{height:180px;position:relative}.layui-colorpicker-basis{width:260px;height:100%;position:relative}.layui-colorpicker-basis-white{width:100%;height:100%;position:absolute;top:0;left:0;background:linear-gradient(90deg,#FFF,hsla(0,0%,100%,0))}.layui-colorpicker-basis-black{width:100%;height:100%;position:absolute;top:0;left:0;background:linear-gradient(0deg,#000,transparent)}.layui-colorpicker-basis-cursor{width:10px;height:10px;border:1px solid #FFF;border-radius:50%;position:absolute;top:-3px;right:-3px;cursor:pointer}.layui-colorpicker-side{position:absolute;top:0;right:0;width:12px;height:100%;background:linear-gradient(red,#FF0,#0F0,#0FF,#00F,#F0F,red)}.layui-colorpicker-side-slider{width:100%;height:5px;box-shadow:0 0 1px #888;box-sizing:border-box;background:#FFF;border-radius:1px;border:1px solid #f0f0f0;cursor:pointer;position:absolute;left:0}.layui-colorpicker-main-alpha{display:none;height:12px;margin-top:7px;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==)}.layui-colorpicker-alpha-bgcolor{height:100%;position:relative}.layui-colorpicker-alpha-slider{width:5px;height:100%;box-shadow:0 0 1px #888;box-sizing:border-box;background:#FFF;border-radius:1px;border:1px solid #f0f0f0;cursor:pointer;position:absolute;top:0}.layui-colorpicker-main-pre{padding-top:7px;font-size:0}.layui-colorpicker-pre{width:20px;height:20px;border-radius:2px;display:inline-block;margin-left:6px;margin-bottom:7px;cursor:pointer}.layui-colorpicker-pre:nth-child(11n+1){margin-left:0}.layui-colorpicker-pre-isalpha{background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==)}.layui-colorpicker-pre.layui-this{box-shadow:0 0 3px 2px rgba(0,0,0,.15)}.layui-colorpicker-pre>div{height:100%;border-radius:2px}.layui-colorpicker-main-input{text-align:right;padding-top:7px}.layui-colorpicker-main-input .layui-btn-container .layui-btn{margin:0 0 0 10px}.layui-colorpicker-main-input div.layui-inline{float:left;margin-right:10px;font-size:14px}.layui-colorpicker-main-input input.layui-input{width:150px;height:30px;color:#666}.layui-slider{height:4px;background:#e2e2e2;border-radius:3px;position:relative;cursor:pointer}.layui-slider-bar{border-radius:3px;position:absolute;height:100%}.layui-slider-step{position:absolute;top:0;width:4px;height:4px;border-radius:50%;background:#FFF;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.layui-slider-wrap{width:36px;height:36px;position:absolute;top:-16px;-webkit-transform:translateX(-50%);transform:translateX(-50%);z-index:10;text-align:center}.layui-slider-wrap-btn{width:12px;height:12px;border-radius:50%;background:#FFF;display:inline-block;vertical-align:middle;cursor:pointer;transition:.3s}.layui-slider-wrap:after{content:"";height:100%;display:inline-block;vertical-align:middle}.layui-slider-wrap-btn.layui-slider-hover,.layui-slider-wrap-btn:hover{transform:scale(1.2)}.layui-slider-wrap-btn.layui-disabled:hover{transform:scale(1)!important}.layui-slider-tips{position:absolute;top:-42px;z-index:66666666;white-space:nowrap;display:none;-webkit-transform:translateX(-50%);transform:translateX(-50%);color:#FFF;background:#000;border-radius:3px;height:25px;line-height:25px;padding:0 10px}.layui-slider-tips:after{content:'';position:absolute;bottom:-12px;left:50%;margin-left:-6px;width:0;height:0;border-width:6px;border-style:solid;border-color:#000 transparent transparent}.layui-slider-input{width:70px;height:32px;border:1px solid #e6e6e6;border-radius:3px;font-size:16px;line-height:32px;position:absolute;right:0;top:-15px}.layui-slider-input-btn{display:none;position:absolute;top:0;right:0;width:20px;height:100%;border-left:1px solid #d2d2d2}.layui-slider-input-btn i{cursor:pointer;position:absolute;right:0;bottom:0;width:20px;height:50%;font-size:12px;line-height:16px;text-align:center;color:#999}.layui-slider-input-btn i:first-child{top:0;border-bottom:1px solid #d2d2d2}.layui-slider-input-txt{height:100%;font-size:14px}.layui-slider-input-txt input{height:100%;border:none}.layui-slider-input-btn i:hover{color:#009688}.layui-slider-vertical{width:4px;margin-left:34px}.layui-slider-vertical .layui-slider-bar{width:4px}.layui-slider-vertical .layui-slider-step{top:auto;left:0;-webkit-transform:translateY(50%);transform:translateY(50%)}.layui-slider-vertical .layui-slider-wrap{top:auto;left:-16px;-webkit-transform:translateY(50%);transform:translateY(50%)}.layui-slider-vertical .layui-slider-tips{top:auto;left:2px}@media \0screen{.layui-slider-wrap-btn{margin-left:-20px}.layui-slider-vertical .layui-slider-wrap-btn{margin-left:0;margin-bottom:-20px}.layui-slider-vertical .layui-slider-tips{margin-left:-8px}.layui-slider>span{margin-left:8px}}.layui-anim{-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-fill-mode:both;animation-fill-mode:both}.layui-anim.layui-icon{display:inline-block}.layui-anim-loop{-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.layui-trans,.layui-trans a{transition:all .3s;-webkit-transition:all .3s}@-webkit-keyframes layui-rotate{from{-webkit-transform:rotate(0)}to{-webkit-transform:rotate(360deg)}}@keyframes layui-rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}.layui-anim-rotate{-webkit-animation-name:layui-rotate;animation-name:layui-rotate;-webkit-animation-duration:1s;animation-duration:1s;-webkit-animation-timing-function:linear;animation-timing-function:linear}@-webkit-keyframes layui-up{from{-webkit-transform:translate3d(0,100%,0);opacity:.3}to{-webkit-transform:translate3d(0,0,0);opacity:1}}@keyframes layui-up{from{transform:translate3d(0,100%,0);opacity:.3}to{transform:translate3d(0,0,0);opacity:1}}.layui-anim-up{-webkit-animation-name:layui-up;animation-name:layui-up}@-webkit-keyframes layui-upbit{from{-webkit-transform:translate3d(0,30px,0);opacity:.3}to{-webkit-transform:translate3d(0,0,0);opacity:1}}@keyframes layui-upbit{from{transform:translate3d(0,30px,0);opacity:.3}to{transform:translate3d(0,0,0);opacity:1}}.layui-anim-upbit{-webkit-animation-name:layui-upbit;animation-name:layui-upbit}@-webkit-keyframes layui-scale{0%{opacity:.3;-webkit-transform:scale(.5)}100%{opacity:1;-webkit-transform:scale(1)}}@keyframes layui-scale{0%{opacity:.3;-ms-transform:scale(.5);transform:scale(.5)}100%{opacity:1;-ms-transform:scale(1);transform:scale(1)}}.layui-anim-scale{-webkit-animation-name:layui-scale;animation-name:layui-scale}@-webkit-keyframes layui-scale-spring{0%{opacity:.5;-webkit-transform:scale(.5)}80%{opacity:.8;-webkit-transform:scale(1.1)}100%{opacity:1;-webkit-transform:scale(1)}}@keyframes layui-scale-spring{0%{opacity:.5;transform:scale(.5)}80%{opacity:.8;transform:scale(1.1)}100%{opacity:1;transform:scale(1)}}.layui-anim-scaleSpring{-webkit-animation-name:layui-scale-spring;animation-name:layui-scale-spring}@-webkit-keyframes layui-fadein{0%{opacity:0}100%{opacity:1}}@keyframes layui-fadein{0%{opacity:0}100%{opacity:1}}.layui-anim-fadein{-webkit-animation-name:layui-fadein;animation-name:layui-fadein}@-webkit-keyframes layui-fadeout{0%{opacity:1}100%{opacity:0}}@keyframes layui-fadeout{0%{opacity:1}100%{opacity:0}}.layui-anim-fadeout{-webkit-animation-name:layui-fadeout;animation-name:layui-fadeout}
\ No newline at end of file
diff --git a/src/styles/lib/layui/css/layui.mobile.css b/src/styles/lib/layui/css/layui.mobile.css
new file mode 100644
index 0000000..6f7f0a1
--- /dev/null
+++ b/src/styles/lib/layui/css/layui.mobile.css
@@ -0,0 +1,2 @@
+/** layui-v2.4.5 MIT License By https://www.layui.com */
+ blockquote,body,button,dd,div,dl,dt,form,h1,h2,h3,h4,h5,h6,input,legend,li,ol,p,td,textarea,th,ul{margin:0;padding:0;-webkit-tap-highlight-color:rgba(0,0,0,0)}html{font:12px 'Helvetica Neue','PingFang SC',STHeitiSC-Light,Helvetica,Arial,sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}a,button,input{-webkit-tap-highlight-color:rgba(255,0,0,0)}a{text-decoration:none;background:0 0}a:active,a:hover{outline:0}table{border-collapse:collapse;border-spacing:0}li{list-style:none}b,strong{font-weight:700}h1,h2,h3,h4,h5,h6{font-weight:500}address,cite,dfn,em,var{font-style:normal}dfn{font-style:italic}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}img{border:0;vertical-align:bottom}.layui-inline,input,label{vertical-align:middle}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0;outline:0}button,select{text-transform:none}select{-webkit-appearance:none;border:none}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}@font-face{font-family:layui-icon;src:url(../font/iconfont.eot?v=1.0.7);src:url(../font/iconfont.eot?v=1.0.7#iefix) format('embedded-opentype'),url(../font/iconfont.woff?v=1.0.7) format('woff'),url(../font/iconfont.ttf?v=1.0.7) format('truetype'),url(../font/iconfont.svg?v=1.0.7#iconfont) format('svg')}.layui-icon{font-family:layui-icon!important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.layui-box,.layui-box *{-webkit-box-sizing:content-box!important;-moz-box-sizing:content-box!important;box-sizing:content-box!important}.layui-border-box,.layui-border-box *{-webkit-box-sizing:border-box!important;-moz-box-sizing:border-box!important;box-sizing:border-box!important}.layui-inline{position:relative;display:inline-block;*display:inline;*zoom:1}.layui-edge,.layui-upload-iframe{position:absolute;width:0;height:0}.layui-edge{border-style:dashed;border-color:transparent;overflow:hidden}.layui-elip{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layui-unselect{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none}.layui-disabled,.layui-disabled:active{background-color:#d2d2d2!important;color:#fff!important;cursor:not-allowed!important}.layui-circle{border-radius:100%}.layui-show{display:block!important}.layui-hide{display:none!important}.layui-upload-iframe{border:0;visibility:hidden}.layui-upload-enter{border:1px solid #009E94;background-color:#009E94;color:#fff;-webkit-transform:scale(1.1);transform:scale(1.1)}@-webkit-keyframes layui-m-anim-scale{0%{opacity:0;-webkit-transform:scale(.5);transform:scale(.5)}100%{opacity:1;-webkit-transform:scale(1);transform:scale(1)}}@keyframes layui-m-anim-scale{0%{opacity:0;-webkit-transform:scale(.5);transform:scale(.5)}100%{opacity:1;-webkit-transform:scale(1);transform:scale(1)}}.layui-m-anim-scale{animation-name:layui-m-anim-scale;-webkit-animation-name:layui-m-anim-scale}@-webkit-keyframes layui-m-anim-up{0%{opacity:0;-webkit-transform:translateY(800px);transform:translateY(800px)}100%{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes layui-m-anim-up{0%{opacity:0;-webkit-transform:translateY(800px);transform:translateY(800px)}100%{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}.layui-m-anim-up{-webkit-animation-name:layui-m-anim-up;animation-name:layui-m-anim-up}@-webkit-keyframes layui-m-anim-left{0%{-webkit-transform:translateX(100%);transform:translateX(100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}@keyframes layui-m-anim-left{0%{-webkit-transform:translateX(100%);transform:translateX(100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}.layui-m-anim-left{-webkit-animation-name:layui-m-anim-left;animation-name:layui-m-anim-left}@-webkit-keyframes layui-m-anim-right{0%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}@keyframes layui-m-anim-right{0%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}.layui-m-anim-right{-webkit-animation-name:layui-m-anim-right;animation-name:layui-m-anim-right}@-webkit-keyframes layui-m-anim-lout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@keyframes layui-m-anim-lout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}.layui-m-anim-lout{-webkit-animation-name:layui-m-anim-lout;animation-name:layui-m-anim-lout}@-webkit-keyframes layui-m-anim-rout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(100%);transform:translateX(100%)}}@keyframes layui-m-anim-rout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(100%);transform:translateX(100%)}}.layui-m-anim-rout{-webkit-animation-name:layui-m-anim-rout;animation-name:layui-m-anim-rout}.layui-m-layer{position:relative;z-index:19891014}.layui-m-layer *{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.layui-m-layermain,.layui-m-layershade{position:fixed;left:0;top:0;width:100%;height:100%}.layui-m-layershade{background-color:rgba(0,0,0,.7);pointer-events:auto}.layui-m-layermain{display:table;font-family:Helvetica,arial,sans-serif;pointer-events:none}.layui-m-layermain .layui-m-layersection{display:table-cell;vertical-align:middle;text-align:center}.layui-m-layerchild{position:relative;display:inline-block;text-align:left;background-color:#fff;font-size:14px;border-radius:5px;box-shadow:0 0 8px rgba(0,0,0,.1);pointer-events:auto;-webkit-overflow-scrolling:touch;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:.2s;animation-duration:.2s}.layui-m-layer0 .layui-m-layerchild{width:90%;max-width:640px}.layui-m-layer1 .layui-m-layerchild{border:none;border-radius:0}.layui-m-layer2 .layui-m-layerchild{width:auto;max-width:260px;min-width:40px;border:none;background:0 0;box-shadow:none;color:#fff}.layui-m-layerchild h3{padding:0 10px;height:60px;line-height:60px;font-size:16px;font-weight:400;border-radius:5px 5px 0 0;text-align:center}.layui-m-layerbtn span,.layui-m-layerchild h3{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layui-m-layercont{padding:50px 30px;line-height:22px;text-align:center}.layui-m-layer1 .layui-m-layercont{padding:0;text-align:left}.layui-m-layer2 .layui-m-layercont{text-align:center;padding:0;line-height:0}.layui-m-layer2 .layui-m-layercont i{width:25px;height:25px;margin-left:8px;display:inline-block;background-color:#fff;border-radius:100%;-webkit-animation:layui-m-anim-loading 1.4s infinite ease-in-out;animation:layui-m-anim-loading 1.4s infinite ease-in-out;-webkit-animation-fill-mode:both;animation-fill-mode:both}.layui-m-layerbtn,.layui-m-layerbtn span{position:relative;text-align:center;border-radius:0 0 5px 5px}.layui-m-layer2 .layui-m-layercont p{margin-top:20px}@-webkit-keyframes layui-m-anim-loading{0%,100%,80%{transform:scale(0);-webkit-transform:scale(0)}40%{transform:scale(1);-webkit-transform:scale(1)}}@keyframes layui-m-anim-loading{0%,100%,80%{transform:scale(0);-webkit-transform:scale(0)}40%{transform:scale(1);-webkit-transform:scale(1)}}.layui-m-layer2 .layui-m-layercont i:first-child{margin-left:0;-webkit-animation-delay:-.32s;animation-delay:-.32s}.layui-m-layer2 .layui-m-layercont i.layui-m-layerload{-webkit-animation-delay:-.16s;animation-delay:-.16s}.layui-m-layer2 .layui-m-layercont>div{line-height:22px;padding-top:7px;margin-bottom:20px;font-size:14px}.layui-m-layerbtn{display:box;display:-moz-box;display:-webkit-box;width:100%;height:50px;line-height:50px;font-size:0;border-top:1px solid #D0D0D0;background-color:#F2F2F2}.layui-m-layerbtn span{display:block;-moz-box-flex:1;box-flex:1;-webkit-box-flex:1;font-size:14px;cursor:pointer}.layui-m-layerbtn span[yes]{color:#40AFFE}.layui-m-layerbtn span[no]{border-right:1px solid #D0D0D0;border-radius:0 0 0 5px}.layui-m-layerbtn span:active{background-color:#F6F6F6}.layui-m-layerend{position:absolute;right:7px;top:10px;width:30px;height:30px;border:0;font-weight:400;background:0 0;cursor:pointer;-webkit-appearance:none;font-size:30px}.layui-m-layerend::after,.layui-m-layerend::before{position:absolute;left:5px;top:15px;content:'';width:18px;height:1px;background-color:#999;transform:rotate(45deg);-webkit-transform:rotate(45deg);border-radius:3px}.layui-m-layerend::after{transform:rotate(-45deg);-webkit-transform:rotate(-45deg)}body .layui-m-layer .layui-m-layer-footer{position:fixed;width:95%;max-width:100%;margin:0 auto;left:0;right:0;bottom:10px;background:0 0}.layui-m-layer-footer .layui-m-layercont{padding:20px;border-radius:5px 5px 0 0;background-color:rgba(255,255,255,.8)}.layui-m-layer-footer .layui-m-layerbtn{display:block;height:auto;background:0 0;border-top:none}.layui-m-layer-footer .layui-m-layerbtn span{background-color:rgba(255,255,255,.8)}.layui-m-layer-footer .layui-m-layerbtn span[no]{color:#FD482C;border-top:1px solid #c2c2c2;border-radius:0 0 5px 5px}.layui-m-layer-footer .layui-m-layerbtn span[yes]{margin-top:10px;border-radius:5px}body .layui-m-layer .layui-m-layer-msg{width:auto;max-width:90%;margin:0 auto;bottom:-150px;background-color:rgba(0,0,0,.7);color:#fff}.layui-m-layer-msg .layui-m-layercont{padding:10px 20px}
\ No newline at end of file
diff --git a/src/styles/lib/layui/css/modules/code.css b/src/styles/lib/layui/css/modules/code.css
new file mode 100644
index 0000000..d0d3822
--- /dev/null
+++ b/src/styles/lib/layui/css/modules/code.css
@@ -0,0 +1,2 @@
+/** layui-v2.4.5 MIT License By https://www.layui.com */
+ html #layuicss-skincodecss{display:none;position:absolute;width:1989px}.layui-code-h3,.layui-code-view{position:relative;font-size:12px}.layui-code-view{display:block;margin:10px 0;padding:0;border:1px solid #e2e2e2;border-left-width:6px;background-color:#F2F2F2;color:#333;font-family:Courier New}.layui-code-h3{padding:0 10px;height:32px;line-height:32px;border-bottom:1px solid #e2e2e2}.layui-code-h3 a{position:absolute;right:10px;top:0;color:#999}.layui-code-view .layui-code-ol{position:relative;overflow:auto}.layui-code-view .layui-code-ol li{position:relative;margin-left:45px;line-height:20px;padding:0 5px;border-left:1px solid #e2e2e2;list-style-type:decimal-leading-zero;*list-style-type:decimal;background-color:#fff}.layui-code-view pre{margin:0}.layui-code-notepad{border:1px solid #0C0C0C;border-left-color:#3F3F3F;background-color:#0C0C0C;color:#C2BE9E}.layui-code-notepad .layui-code-h3{border-bottom:none}.layui-code-notepad .layui-code-ol li{background-color:#3F3F3F;border-left:none}
\ No newline at end of file
diff --git a/src/styles/lib/layui/css/modules/laydate/default/laydate.css b/src/styles/lib/layui/css/modules/laydate/default/laydate.css
new file mode 100644
index 0000000..f7e690e
--- /dev/null
+++ b/src/styles/lib/layui/css/modules/laydate/default/laydate.css
@@ -0,0 +1,2 @@
+/** layui-v2.4.5 MIT License By https://www.layui.com */
+ .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}
\ No newline at end of file
diff --git a/src/styles/lib/layui/css/modules/layer/default/icon-ext.png b/src/styles/lib/layui/css/modules/layer/default/icon-ext.png
new file mode 100644
index 0000000..bbbb669
Binary files /dev/null and b/src/styles/lib/layui/css/modules/layer/default/icon-ext.png differ
diff --git a/src/styles/lib/layui/css/modules/layer/default/icon.png b/src/styles/lib/layui/css/modules/layer/default/icon.png
new file mode 100644
index 0000000..3e17da8
Binary files /dev/null and b/src/styles/lib/layui/css/modules/layer/default/icon.png differ
diff --git a/src/styles/lib/layui/css/modules/layer/default/layer.css b/src/styles/lib/layui/css/modules/layer/default/layer.css
new file mode 100644
index 0000000..157d537
--- /dev/null
+++ b/src/styles/lib/layui/css/modules/layer/default/layer.css
@@ -0,0 +1,2 @@
+/** layui-v2.4.5 MIT License By https://www.layui.com */
+ .layui-layer-imgbar,.layui-layer-imgtit a,.layui-layer-tab .layui-layer-title span,.layui-layer-title{text-overflow:ellipsis;white-space:nowrap}html #layuicss-layer{display:none;position:absolute;width:1989px}.layui-layer,.layui-layer-shade{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;top:150px;left:0;margin:0;padding:0;background-color:#fff;-webkit-background-clip:content;border-radius:2px;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,.1);box-shadow:1px 1px 5px rgba(0,0,0,.2)}.layui-layer-load{background:url(loading-1.gif) center center no-repeat #eee}.layui-layer-ico{background:url(icon.png) no-repeat}.layui-layer-btn a,.layui-layer-dialog .layui-layer-ico,.layui-layer-setwin a{display:inline-block;*display:inline;*zoom:1;vertical-align:top}.layui-layer-move{display:none;position:fixed;*position:absolute;left:0;top:0;width:100%;height:100%;cursor:move;opacity:0;filter:alpha(opacity=0);background-color:#fff;z-index:2147483647}.layui-layer-resize{position:absolute;width:15px;height:15px;right:0;bottom:0;cursor:se-resize}.layer-anim{-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:.3s;animation-duration:.3s}@-webkit-keyframes layer-bounceIn{0%{opacity:0;-webkit-transform:scale(.5);transform:scale(.5)}100%{opacity:1;-webkit-transform:scale(1);transform:scale(1)}}@keyframes layer-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-00{-webkit-animation-name:layer-bounceIn;animation-name:layer-bounceIn}@-webkit-keyframes layer-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 layer-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:layer-zoomInDown;animation-name:layer-zoomInDown}@-webkit-keyframes layer-fadeInUpBig{0%{opacity:0;-webkit-transform:translateY(2000px);transform:translateY(2000px)}100%{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes layer-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:layer-fadeInUpBig;animation-name:layer-fadeInUpBig}@-webkit-keyframes layer-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 layer-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:layer-zoomInLeft;animation-name:layer-zoomInLeft}@-webkit-keyframes layer-rollIn{0%{opacity:0;-webkit-transform:translateX(-100%) rotate(-120deg);transform:translateX(-100%) rotate(-120deg)}100%{opacity:1;-webkit-transform:translateX(0) rotate(0);transform:translateX(0) rotate(0)}}@keyframes layer-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(0) rotate(0);-ms-transform:translateX(0) rotate(0);transform:translateX(0) rotate(0)}}.layer-anim-04{-webkit-animation-name:layer-rollIn;animation-name:layer-rollIn}@keyframes layer-fadeIn{0%{opacity:0}100%{opacity:1}}.layer-anim-05{-webkit-animation-name:layer-fadeIn;animation-name:layer-fadeIn}@-webkit-keyframes layer-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 layer-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:layer-shake;animation-name:layer-shake}@-webkit-keyframes fadeIn{0%{opacity:0}100%{opacity:1}}.layui-layer-title{padding:0 80px 0 20px;height:42px;line-height:42px;border-bottom:1px solid #eee;font-size:14px;color:#333;overflow:hidden;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:1px -40px;cursor:pointer}.layui-layer-setwin .layui-layer-close1:hover{opacity:.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:0 15px 12px;pointer-events:auto;user-select:none;-webkit-user-select:none}.layui-layer-btn a{height:28px;line-height:28px;margin:5px 5px 0;padding:0 15px;border:1px solid #dedede;background-color:#fff;color:#333;border-radius:2px;font-weight:400;cursor:pointer;text-decoration:none}.layui-layer-btn a:hover{opacity:.9;text-decoration:none}.layui-layer-btn a:active{opacity:.8}.layui-layer-btn .layui-layer-btn0{border-color:#1E9FFF;background-color:#1E9FFF;color:#fff}.layui-layer-btn-l{text-align:left}.layui-layer-btn-c{text-align:center}.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,.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-iframe .layui-layer-btn,.layui-layer-page .layui-layer-btn{padding-top:10px}.layui-layer-nobg{background:0 0}.layui-layer-iframe iframe{display:block;width:100%}.layui-layer-loading{border-radius:100%;background:0 0;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-ico16,.layui-layer-loading .layui-layer-loading2{width:32px;height:32px;background:url(loading-2.gif) no-repeat}.layui-layer-tips{background:0 0;box-shadow:none;border:none}.layui-layer-tips .layui-layer-content{position:relative;line-height:22px;min-width:12px;padding:8px 15px;font-size:12px;_float:left;border-radius:2px;box-shadow:1px 1px 3px rgba(0,0,0,.2);background-color:#000;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-TipsB,.layui-layer-tips i.layui-layer-TipsT{left:5px;border-right-style:solid;border-right-color:#000}.layui-layer-tips i.layui-layer-TipsT{bottom:-8px}.layui-layer-tips i.layui-layer-TipsB{top:-8px}.layui-layer-tips i.layui-layer-TipsL,.layui-layer-tips i.layui-layer-TipsR{top:5px;border-bottom-style:solid;border-bottom-color:#000}.layui-layer-tips i.layui-layer-TipsR{left:-8px}.layui-layer-tips i.layui-layer-TipsL{right:-8px}.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:5px 10px 10px;text-align:right;border-top:1px solid #E9E7E7}.layui-layer-lan .layui-layer-btn a{background:#fff;border-color:#E9E7E7;color:#333}.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;border-color:#009f95}.layui-layer-molv .layui-layer-btn .layui-layer-btn1{background:#92B8B1}.layui-layer-iconext{background:url(icon-ext.png) no-repeat}.layui-layer-prompt .layui-layer-input{display:block;width:230px;height:36px;margin:0 auto;line-height:30px;padding-left:10px;border:1px solid #e6e6e6;color:#333}.layui-layer-prompt textarea.layui-layer-input{width:300px;height:100px;line-height:20px;padding:6px 10px}.layui-layer-prompt .layui-layer-content{padding:20px}.layui-layer-prompt .layui-layer-btn{padding-top:0}.layui-layer-tab{box-shadow:1px 1px 50px rgba(0,0,0,.4)}.layui-layer-tab .layui-layer-title{padding-left:0;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;overflow:hidden;cursor:pointer}.layui-layer-tab .layui-layer-title span.layui-this{height:43px;border-left:1px solid #eee;border-right:1px solid #eee;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.layui-this{display:block}.layui-layer-photos{-webkit-animation-duration:.8s;animation-duration:.8s}.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}@-webkit-keyframes layer-bounceOut{100%{opacity:0;-webkit-transform:scale(.7);transform:scale(.7)}30%{-webkit-transform:scale(1.05);transform:scale(1.05)}0%{-webkit-transform:scale(1);transform:scale(1)}}@keyframes layer-bounceOut{100%{opacity:0;-webkit-transform:scale(.7);-ms-transform:scale(.7);transform:scale(.7)}30%{-webkit-transform:scale(1.05);-ms-transform:scale(1.05);transform:scale(1.05)}0%{-webkit-transform:scale(1);-ms-transform:scale(1);transform:scale(1)}}.layer-anim-close{-webkit-animation-name:layer-bounceOut;animation-name:layer-bounceOut;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:.2s;animation-duration:.2s}@media screen and (max-width:1100px){.layui-layer-iframe{overflow-y:auto;-webkit-overflow-scrolling:touch}}
\ No newline at end of file
diff --git a/src/styles/lib/layui/css/modules/layer/default/loading-0.gif b/src/styles/lib/layui/css/modules/layer/default/loading-0.gif
new file mode 100644
index 0000000..6f3c953
Binary files /dev/null and b/src/styles/lib/layui/css/modules/layer/default/loading-0.gif differ
diff --git a/src/styles/lib/layui/css/modules/layer/default/loading-1.gif b/src/styles/lib/layui/css/modules/layer/default/loading-1.gif
new file mode 100644
index 0000000..db3a483
Binary files /dev/null and b/src/styles/lib/layui/css/modules/layer/default/loading-1.gif differ
diff --git a/src/styles/lib/layui/css/modules/layer/default/loading-2.gif b/src/styles/lib/layui/css/modules/layer/default/loading-2.gif
new file mode 100644
index 0000000..5bb90fd
Binary files /dev/null and b/src/styles/lib/layui/css/modules/layer/default/loading-2.gif differ
diff --git a/src/styles/lib/layui/font/iconfont.eot b/src/styles/lib/layui/font/iconfont.eot
new file mode 100644
index 0000000..93b3d5a
Binary files /dev/null and b/src/styles/lib/layui/font/iconfont.eot differ
diff --git a/src/styles/lib/layui/font/iconfont.svg b/src/styles/lib/layui/font/iconfont.svg
new file mode 100644
index 0000000..1c7ffe9
--- /dev/null
+++ b/src/styles/lib/layui/font/iconfont.svg
@@ -0,0 +1,473 @@
+
+
+
+
diff --git a/src/styles/lib/layui/font/iconfont.ttf b/src/styles/lib/layui/font/iconfont.ttf
new file mode 100644
index 0000000..0c8b0a5
Binary files /dev/null and b/src/styles/lib/layui/font/iconfont.ttf differ
diff --git a/src/styles/lib/layui/font/iconfont.woff b/src/styles/lib/layui/font/iconfont.woff
new file mode 100644
index 0000000..786bb2a
Binary files /dev/null and b/src/styles/lib/layui/font/iconfont.woff differ
diff --git a/src/styles/page/index.less b/src/styles/page/index.less
index 9fa06de..cc0c9fd 100644
--- a/src/styles/page/index.less
+++ b/src/styles/page/index.less
@@ -1,14 +1,14 @@
.text{
padding: 20px 0;
font-size: 18px;
- color:#f63;
+ color: #e1ff17;
}
.btn{
width: 120px;
height: 36px;
line-height: 36px;
background-color: #677D7C;
- color:#fff;
+ color: #ffd80f;
text-align: center;
border:none;
box-shadow: 0 1px 3px #999;
@@ -17,4 +17,4 @@
}
.img{
margin-top: 20px;
-}
\ No newline at end of file
+}
diff --git a/src/styles/page/login.less b/src/styles/page/login.less
new file mode 100644
index 0000000..e1d66ce
--- /dev/null
+++ b/src/styles/page/login.less
@@ -0,0 +1,38 @@
+h1{
+ width: 40%;
+ //background-image: linear-gradient(160deg, #ffce00 20%,#ff8b00 80%);
+ //
+ //background-color:#9F9;
+ background:-webkit-linear-gradient(160deg, #ffce00 20%,#ff8b00 80%);
+ background:-moz-linear-gradient(160deg, #ffce00 20%,#ff8b00 80%);
+ -pie-background:linear-gradient(160deg, #ffce00 20%,#ff8b00 80%);
+ color: #fff;
+ margin: 15px 0;
+}
+#progress,
+.layui-progress {
+ margin: 20px;
+}
+.layui-progress-bar {
+ background-color:#FFB800;
+}
+#formBtn,#item,#datePart,#uploadPic {
+ display: none;
+}
+.upload img {
+ display: inline-block;
+ height: 38px;
+}
+#form {
+ width: 600px;
+ margin: 10px auto;
+}
+.formbtn {
+ text-align: center;
+}
+#carousel, #carouselInner {
+ width: 800px;
+ height: 400px;
+ margin: 10px;
+ display: inline-block;
+}
diff --git a/src/utils/fixIE.js b/src/utils/fixIE.js
new file mode 100644
index 0000000..fa4aa8d
--- /dev/null
+++ b/src/utils/fixIE.js
@@ -0,0 +1,5 @@
+require('es5-shim');
+require('console-polyfill');
+require('core-js/fn/object/assign');
+window.Promise = require('es6-promise').Promise;
+require('es5-shim/es5-sham');
diff --git a/src/utils/layui_extend.js b/src/utils/layui_extend.js
new file mode 100644
index 0000000..44e218e
--- /dev/null
+++ b/src/utils/layui_extend.js
@@ -0,0 +1,21 @@
+//设定模块名和模块路径
+layui.config({
+ base: 'static/components/modules/' //存放拓展模块的根目录
+}).extend({
+ djcpsAlert: 'djcpsAlert/djcpsAlert',
+ djcpsConfirm: 'djcpsConfirm/djcpsConfirm',
+ djcpsMsg: 'djcpsMsg/djcpsMsg',
+ djcpsLoad: 'djcpsLoad/djcpsLoad',
+ djcpsTips: 'djcpsTips/djcpsTips',
+ djcpsProgress: 'djcpsProgress/djcpsProgress',
+ djcpsCarousel: 'djcpsCarousel/djcpsCarousel',
+ djcpsModal: 'djcpsModal/djcpsModal',
+ djcpsTable: 'djcpsTable/djcpsTable',
+ djcpsPage: 'djcpsPage/djcpsPage',
+ djcpsUpload: 'djcpsUpload/djcpsUpload',
+ djcpsDate: 'djcpsDate/djcpsDate',
+ djcpsTree: 'djcpsTree/djcpsTree',
+ djcpsFlow: 'djcpsFlow/djcpsFlow',
+ djcpsPanel: 'djcpsPanel/djcpsPanel',
+ djcpsForm: 'djcpsForm/djcpsForm'
+});
diff --git a/src/views/common/_content.html b/src/views/common/_content.html
index da4d326..6074a03 100644
--- a/src/views/common/_content.html
+++ b/src/views/common/_content.html
@@ -1,3 +1,3 @@

-
\ No newline at end of file
+
diff --git a/src/views/common/footer.html b/src/views/common/footer.html
index d81df26..2b89b6a 100644
--- a/src/views/common/footer.html
+++ b/src/views/common/footer.html
@@ -1 +1,4 @@
+
+
+
diff --git a/src/views/common/header.html b/src/views/common/header.html
index dfaf7ab..935100d 100644
--- a/src/views/common/header.html
+++ b/src/views/common/header.html
@@ -4,7 +4,10 @@
首页
- 关于
+ 关于
+
+
+ 登录
diff --git a/src/views/common/meta.html b/src/views/common/meta.html
index 8482542..6dfdcd9 100644
--- a/src/views/common/meta.html
+++ b/src/views/common/meta.html
@@ -1,3 +1,24 @@
{{title}}
-
\ No newline at end of file
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/index.html b/src/views/index.html
index 943130d..01bead0 100644
--- a/src/views/index.html
+++ b/src/views/index.html
@@ -1,37 +1,17 @@
- {{include './common/meta'}}
+ {{include './common/meta'}}
-{{include './common/header'}}
-
-{{include './common/footer'}}
+ {{include './common/header'}}
+
+
+
+
+
+ {{include './common/_content'}}
+
+ {{include './common/footer'}}
-
diff --git a/src/views/login.html b/src/views/login.html
new file mode 100644
index 0000000..08d3f28
--- /dev/null
+++ b/src/views/login.html
@@ -0,0 +1,154 @@
+
+
+
+ {{include './common/meta'}}
+
+
+{{include './common/header'}}
+
+
djcpsAlert
+
+
djcpsConfirm
+
+
djcpsMsg
+
+
djcpsLoad
+
+
+
+
djcpsTips
+
+
djcpsProgress
+
+
+
djcpsCarousel
+
+
+
djcpsModal
+
+
+
+
djcpsPage()
+
+
+
+
+
+
djcpsUpload()
+
+
+
+
+
+
+
+ 文件名 |
+ 预览图 |
+ 大小 |
+ 状态 |
+ 操作 |
+
+
+
+
+
+
+
+
djcpsDate
+
+
+
时间点选择
+
date日期选择器
+
+
year年选择器
+
+
month年月选择器
+
+
time时间选择器
+
+
datetime日期时间选择器
+
+
+
时间段选择
+
date日期选择器
+
+
year年选择器
+
+
month年月选择器
+
+
time时间选择器
+
+
datetime日期时间选择器
+
+
+
其他风格
+
molv墨绿背景datetime日期时间选择器
+
+
custom自定义颜色#393D49-datetime日期时间选择器
+
+
grid格子主题datetime日期时间选择器
+
+
concise自定义样式datetime日期时间选择器
+
+
+
+
+
djcpsTree
+
+
+
简洁风格
+
+
--------------------------------------------------
+
默认风格
+
+
+
+
djcpsFlow
+
+
djcpsPanel
+
+
+
djcpsForm(图片上传会卡住页面)
+
+
+{{include './common/footer'}}
+
+
diff --git a/static/PIE.htc b/static/PIE.htc
new file mode 100644
index 0000000..dbcca42
--- /dev/null
+++ b/static/PIE.htc
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/static/components/index.js b/static/components/index.js
new file mode 100644
index 0000000..497f5e9
--- /dev/null
+++ b/static/components/index.js
@@ -0,0 +1,19 @@
+//设定模块名和模块路径
+layui.extend({
+ djcpsAlert: 'static/lib/components/modules/djcpsAlert/djcpsAlert',
+ djcpsConfirm: 'static/lib/components/modules/djcpsConfirm/djcpsConfirm',
+ djcpsMsg: 'static/lib/components/modules/djcpsMsg/djcpsMsg',
+ djcpsLoad: 'static/lib/components/modules/djcpsLoad/djcpsLoad',
+ djcpsTips: 'static/lib/components/modules/djcpsTips/djcpsTips',
+ djcpsProgress: 'static/lib/components/modules/djcpsProgress/djcpsProgress',
+ djcpsCarousel: 'static/lib/components/modules/djcpsCarousel/djcpsCarousel',
+ djcpsModal: 'static/lib/components/modules/djcpsModal/djcpsModal',
+ djcpsTable: 'static/lib/components/modules/djcpsTable/djcpsTable',
+ djcpsPage: 'static/lib/components/modules/djcpsPage/djcpsPage',
+ djcpsUpload: 'static/lib/components/modules/djcpsUpload/djcpsUpload',
+ djcpsDate: 'static/lib/components/modules/djcpsDate/djcpsDate',
+ djcpsTree: 'static/lib/components/modules/djcpsTree/djcpsTree',
+ djcpsFlow: 'static/lib/components/modules/djcpsFlow/djcpsFlow',
+ djcpsPanel: 'static/lib/components/modules/djcpsPanel/djcpsPanel',
+ djcpsForm: 'static/lib/components/modules/djcpsForm/djcpsForm'
+});
diff --git a/static/components/modules/djcpsAlert/djcpsAlert.css b/static/components/modules/djcpsAlert/djcpsAlert.css
new file mode 100644
index 0000000..fd7a33e
--- /dev/null
+++ b/static/components/modules/djcpsAlert/djcpsAlert.css
@@ -0,0 +1,3 @@
+.cps-layer-alert {
+
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsAlert/djcpsAlert.html b/static/components/modules/djcpsAlert/djcpsAlert.html
new file mode 100644
index 0000000..d01fb32
--- /dev/null
+++ b/static/components/modules/djcpsAlert/djcpsAlert.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsAlert/djcpsAlert.js b/static/components/modules/djcpsAlert/djcpsAlert.js
new file mode 100644
index 0000000..a437ca4
--- /dev/null
+++ b/static/components/modules/djcpsAlert/djcpsAlert.js
@@ -0,0 +1,93 @@
+/**
+ * 提示框alert组件
+ * layui-layer-alert二次封装
+ */
+// $ = layui.jquery;
+layui.define('layer', function (exports) {
+ "use strict";
+ var layer = layui.layer;
+ // 定义组件
+ var djcpsAlert = {
+ // 初始配置
+ config: {
+ //标题,也可以设置标题样式 ['文本', 'font-size:18px;'],传false则不显示标题栏
+ title: '提示',
+ //样式类名,会加载提示框元素的最外层
+ skin: 'cps-layer-alert',
+ //宽高,auto自适应,500px为宽度500高度仍自适应
+ area: "auto",
+ //坐标,auto垂直水平居中,100px为top坐标100水平仍居中,['100px', '50px']为top、left坐标
+ //快捷设置,t顶部居中,r右边缘居中,b底部居中,l左边缘居中,lt左上角,lb左下角,rt右上角,rb右下角
+ offset: 'auto',
+ //图标,显示在文字之前
+ icon: -1,
+ //关闭按钮,样式1或2,0为无关闭按钮
+ closeBtn: 0,
+ //遮罩,提示框外区域#000背景透明度,0为不遮罩,[0.8, '#393D49']可自定义遮罩颜色
+ shade: 0.3,
+ //是否通过点击遮罩来关闭提示框
+ shadeClose: false,
+ //是否固定在可视区域(鼠标滚动时)
+ fixed: true,
+ //是否允许浏览器出现滚动条
+ scrollbar: true,
+ //层叠顺序,一般用于解决和其他组件的层叠冲突
+ zIndex: 19891014,
+ //触发拖拽的元素,传元素选择器'.layui-layer-title',传false禁止拖拽
+ move: false
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} content 内容
+ * @param {*} options 配置项
+ * @param {*} callback 回调函数,携带两个参数,分别为当前层索引index、当前层DOM对象layero
+ */
+ var mainFn = function (content, options, callback) {
+ var that = this;
+ that.content = content === undefined ? '' : content;
+ that.config = $.extend({}, djcpsAlert.config, options);
+ that.callback = typeof callback === 'function' ? callback : undefined;
+ that.loadHtml().then(function () {
+ that.initAlert();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#alertCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsAlert/djcpsAlert.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化提示框功能
+ */
+ mainFn.prototype.initAlert = function () {
+ var that = this;
+ layer.alert(that.content, that.config, function (index, layero) {
+ if (typeof that.callback === "function") {
+ that.callback(index, layero);
+ }
+ layer.close(index);
+ });
+ };
+ //组件入口
+ djcpsAlert.init = function (content, options, callback) {
+ var inst = new mainFn(content, options, callback);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsAlert', djcpsAlert);
+});
diff --git a/static/components/modules/djcpsCarousel/djcpsCarousel.css b/static/components/modules/djcpsCarousel/djcpsCarousel.css
new file mode 100644
index 0000000..96e2336
--- /dev/null
+++ b/static/components/modules/djcpsCarousel/djcpsCarousel.css
@@ -0,0 +1,23 @@
+.layui-carousel img {
+ width: 100%;
+ height: 100%;
+}
+
+.layui-carousel .carouseText p {
+ text-align: center;
+ line-height: 400px;
+ font-size: 48px;
+}
+
+.layui-carousel .carouseAll {
+ position: relative;
+}
+
+.layui-carousel .carouseAll p {
+ position: absolute;
+ top: 20px;
+ left: 0;
+ font-size: 48px;
+ width: 100%;
+ text-align: center;
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsCarousel/djcpsCarousel.html b/static/components/modules/djcpsCarousel/djcpsCarousel.html
new file mode 100644
index 0000000..f9acf3b
--- /dev/null
+++ b/static/components/modules/djcpsCarousel/djcpsCarousel.html
@@ -0,0 +1,22 @@
+
+
diff --git a/static/components/modules/djcpsCarousel/djcpsCarousel.js b/static/components/modules/djcpsCarousel/djcpsCarousel.js
new file mode 100644
index 0000000..83243b8
--- /dev/null
+++ b/static/components/modules/djcpsCarousel/djcpsCarousel.js
@@ -0,0 +1,148 @@
+/**
+ * 轮播组件
+ * layui-carousel二次封装
+ */
+layui.define(['carousel', 'laytpl'], function (exports) {
+ "use strict";
+ var laytpl = layui.laytpl;
+ var carousel = layui.carousel;
+ // 定义组件
+ var djcpsCarousel = {
+ // 初始配置
+ config: {
+ //非layui原生配置,外部容器元素,传入jquery的dom对象
+ container: $('#carousel'),
+ //非layui原生配置,用于组件区分标识(过滤器)
+ filter: 'carousel',
+ //设置内部容器宽度
+ width: '100%',
+ //设置内部容器高度
+ height: '100%',
+ //是否全屏轮播
+ full: false,
+ //轮播切换方式,default左右切换,updown上下切换,fade渐隐渐显切换
+ anim: 'default',
+ //是否自动切换
+ autoplay: true,
+ //自动切换的时间间隔,单位ms,不能低于800
+ interval: 3000,
+ //非layui原生配置,滑动时间
+ speed: 0,
+ //初始开始的条目索引
+ index: 0,
+ //切换箭头显示状态,hover悬停显示,always始终显示,none始终不显示
+ arrow: 'hover',
+ //指示器位置,inside容器内部,outside容器外部,none不显示
+ indicator: 'inside',
+ //指示器的触发事件
+ trigger: 'click',
+ //非layui原生配置,轮播数据
+ data: [],
+ //非layui原生配置,轮播数据相关配置
+ options: {
+ //轮播类型,img图片轮播,text文字轮播,custom自定义html片段轮播
+ type: 'img',
+ //轮播字段,图片轮播为图片字段,文字轮播为文字字段
+ prop: 'src',
+ //自定义轮播的html模板
+ customHtml: '',
+ //替代图片,当图片无法显示的时候可以设置替代图片
+ errorSrc: ''
+ },
+ //非layui原生配置,切换内容时的回调函数
+ change: function (obj) { }
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} options 配置项
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsCarousel.config, options);
+ that.loadHtml().then(function () {
+ return that.renderHtml();
+ }).then(function () {
+ that.initCarousel();
+ //轮播切换时的监听事件
+ //obj包含index当前条目索引,prevIndex上一个条目索引,item当前条目的元素对象
+ carousel.on('change(' + that.config.filter + ')', function (obj) { //test1来源于对应HTML容器的 lay-filter="test1" 属性值
+ if (typeof that.config.change === 'function') {
+ that.config.change(obj);
+ }
+ });
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#carouselCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsCarousel/djcpsCarousel.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 渲染模板文件
+ */
+ mainFn.prototype.renderHtml = function () {
+ var that = this;
+ var defer = $.Deferred();
+ //整合模板数据
+ var data = {
+ filter: that.config.filter,
+ options: that.config.options,
+ data: that.config.data
+ };
+ var tpl = $('#carouselTpl').html();
+ laytpl(tpl).render(data, function (html) {
+ that.config.container.html(html);
+ //如果有图片轮播,且图片加载失败,则用备用替代图片
+ if (that.config.container.find('img').length && that.config.options.errorSrc) {
+ that.config.container.find('img').error(function () {
+ console.log('err');
+ $(this).attr('src', that.config.options.errorSrc);
+ });
+ }
+ defer.resolve();
+ $('.layui-carousel>[carousel-item]>*').css("transition-duration",that.config.speed+'s');
+ console.log('transition');
+ });
+ return defer.promise();
+ };
+ /**
+ * 初始化轮播功能
+ */
+ mainFn.prototype.initCarousel = function () {
+ var that = this;
+ that.config.elem = that.config.container.find('.carouselContent');
+ that.carousel = carousel.render(that.config);
+ };
+ /**
+ * 重置轮播功能
+ */
+ mainFn.prototype.reload = function () {
+ var that = this;
+ if (that.carousel) {
+ that.carousel.reload(that.config);
+ }
+ };
+ //组件入口
+ djcpsCarousel.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+
+ //输出组件
+ exports('djcpsCarousel', djcpsCarousel);
+});
diff --git a/static/components/modules/djcpsConfirm/djcpsConfirm.css b/static/components/modules/djcpsConfirm/djcpsConfirm.css
new file mode 100644
index 0000000..7c4ee22
--- /dev/null
+++ b/static/components/modules/djcpsConfirm/djcpsConfirm.css
@@ -0,0 +1,3 @@
+.cps-layer-confirm {
+
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsConfirm/djcpsConfirm.html b/static/components/modules/djcpsConfirm/djcpsConfirm.html
new file mode 100644
index 0000000..b24984b
--- /dev/null
+++ b/static/components/modules/djcpsConfirm/djcpsConfirm.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsConfirm/djcpsConfirm.js b/static/components/modules/djcpsConfirm/djcpsConfirm.js
new file mode 100644
index 0000000..6453217
--- /dev/null
+++ b/static/components/modules/djcpsConfirm/djcpsConfirm.js
@@ -0,0 +1,99 @@
+/**
+ * 确认框confirm组件
+ * layui-layer-confirm二次封装
+ */
+layui.define('layer', function (exports) {
+ "use strict";
+ var layer = layui.layer;
+ // 定义组件
+ var djcpsConfirm = {
+ // 初始配置
+ config: {
+ //标题,也可以设置标题样式 ['文本', 'font-size:18px;'],传false则不显示标题栏
+ title: '提示',
+ //样式类名,会加载提示元素的最外层
+ skin: 'cps-layer-confirm',
+ //宽高,auto自适应,500px为宽度500高度仍自适应
+ area: "auto",
+ //坐标,auto垂直水平居中,100px为top坐标100水平仍居中,['100px', '50px']为top、left坐标
+ //快捷设置,t顶部居中,r右边缘居中,b底部居中,l左边缘居中,lt左上角,lb左下角,rt右上角,rb右下角
+ offset: 'auto',
+ //图标,显示在文字之前
+ icon: -1,
+ //关闭按钮,样式1或2,0为无关闭按钮
+ closeBtn: 0,
+ //遮罩,确认框外区域#000背景透明度,0为不遮罩,[0.8, '#393D49']可自定义遮罩颜色
+ shade: 0.3,
+ //是否通过点击遮罩来关闭确认框
+ shadeClose: false,
+ //是否固定在可视区域(鼠标滚动时)
+ fixed: true,
+ //是否允许浏览器出现滚动条
+ scrollbar: true,
+ //层叠顺序,一般用于解决和其他组件的层叠冲突
+ zIndex: 19891014,
+ //触发拖拽的元素,传元素选择器'.layui-layer-title',传false禁止拖拽
+ move: false
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} content 内容
+ * @param {*} options 配置项
+ * @param {*} yes 确定回调函数,携带两个参数,分别为当前层索引index、当前层DOM对象layero
+ * @param {*} cancel 取消回调函数,携带两个参数,分别为当前层索引index、当前层DOM对象layero
+ */
+ var mainFn = function (content, options, yes, cancel) {
+ var that = this;
+ that.content = content === undefined ? '' : content;
+ that.config = $.extend({}, djcpsConfirm.config, options);
+ that.yes = typeof yes === 'function' ? yes : undefined;
+ that.cancel = typeof cancel === 'function' ? cancel : undefined;
+ that.loadHtml().then(function () {
+ that.initConfirm();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#confirmCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsConfirm/djcpsConfirm.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化确认框功能
+ */
+ mainFn.prototype.initConfirm = function () {
+ var that = this;
+ layer.confirm(that.content, that.config, function (index, layero) {
+ if (typeof that.yes === "function") {
+ that.yes(index, layero);
+ }
+ layer.close(index);
+ }, function(index, layero) {
+ if (typeof that.cancel === "function") {
+ that.cancel(index, layero);
+ }
+ layer.close(index);
+ });
+ };
+ //组件入口
+ djcpsConfirm.init = function (content, options, yes, cancel) {
+ var inst = new mainFn(content, options, yes, cancel);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsConfirm', djcpsConfirm);
+});
diff --git a/static/components/modules/djcpsDate/djcpsDate.css b/static/components/modules/djcpsDate/djcpsDate.css
new file mode 100644
index 0000000..5253906
--- /dev/null
+++ b/static/components/modules/djcpsDate/djcpsDate.css
@@ -0,0 +1,57 @@
+/* laydate日期与时间选择器样式,concise简洁的背景主题 */
+
+.laydate-theme-concise {
+ border: none;
+}
+
+.laydate-theme-concise .layui-laydate-header {
+ border-bottom: none;
+}
+
+.laydate-theme-concise .layui-laydate-header i:hover,
+.laydate-theme-concise .layui-laydate-header span:hover {
+ color: #1886E3;
+}
+
+.laydate-theme-concise .layui-laydate-content {
+ border: none;
+ border-top: none;
+ border-bottom: none;
+}
+
+.laydate-theme-concise .layui-laydate-content th {
+ color: #1886e3;
+}
+
+.laydate-theme-concise .laydate-main-list-1 .layui-laydate-content {
+ border-left: none;
+}
+
+.laydate-theme-concise .layui-laydate-footer {
+ border: none;
+}
+
+.laydate-theme-concise .layui-laydate-footer span:hover {
+ color: #1886E3
+}
+
+.laydate-theme-concise .laydate-footer-btns span {
+ border: none;
+}
+
+.laydate-theme-concise .layui-this {
+ background-color: #1886E3 !important;
+ color: #fff !important;
+}
+
+
+.laydate-theme-concise, .layui-laydate-hint {
+ border: 1px solid #DCDCDC;;
+ box-shadow: 1px 9px 30px rgba(42, 83, 168, 0.2);
+ background-color: #fff;
+ color: #666;
+}
+
+.laydate-theme-concise .layui-laydate-footer span[lay-type=date] {
+ color: #1886E3
+}
diff --git a/static/components/modules/djcpsDate/djcpsDate.html b/static/components/modules/djcpsDate/djcpsDate.html
new file mode 100644
index 0000000..92a6cc0
--- /dev/null
+++ b/static/components/modules/djcpsDate/djcpsDate.html
@@ -0,0 +1,5 @@
+
+
diff --git a/static/components/modules/djcpsDate/djcpsDate.js b/static/components/modules/djcpsDate/djcpsDate.js
new file mode 100644
index 0000000..33b0113
--- /dev/null
+++ b/static/components/modules/djcpsDate/djcpsDate.js
@@ -0,0 +1,127 @@
+// 日期与时间选择组件,基于layui-laydate二次封装
+layui.define(['laydate', 'laytpl'], function (exports) {
+ 'use strict';
+ // 引用layui的自带日期和时间选择
+ var laydate = layui.laydate;
+ var laytpl = layui.laytpl;
+ // 定义组件
+ var djcpsDate = {
+ // 默认配置
+ config: {
+ // 外部容器元素,传入jquery的dom对象
+ container: $('#date'),
+ // 时间控件的id
+ id: 'dateContent',
+ // 时间控件的placeholder
+ placeholder: '',
+ // 时间控件是否禁用
+ disabled: false,
+ // 控件类型,支持:date日期选择器/year年选择器/month年月选择器/time时间选择器/datetime日期时间选择器
+ type: 'date',
+ // 是否开启范围选择,即双控件
+ range: false,
+ // 默认日期格式,如:yyyy-MM-dd HH:mm:ss、yyyy年MM月dd日 HH时mm分ss秒
+ format: 'yyyy-MM-dd',
+ // 默认日期,支持传入new Date(),或者符合format参数设定的日期格式字符
+ value: null,
+ // 用于控制是否自动向元素填充初始值(需配合 value 参数使用)
+ isInitValue: true,
+ // 有效最小日期,年月日必须用“-”分割,时分秒必须用“:”分割。注意:它并不是遵循 format 设定的格式。
+ min: '1900-1-1',
+ //有效最大日期,同上
+ max: '2099-12-31',
+ // 呼出控件的事件,默认focus,如果绑定的元素非输入框,可改为click
+ trigger: 'focus',
+ // 是否直接显示,如果设置true,则默认直接显示控件
+ show: false,
+ // 是否显示底部栏
+ showBottom: true,
+ // 右下角显示的按钮,会按照数组顺序排列
+ btns: ['clear', 'now', 'confirm'],
+ // 语言,只支持cn/en,即中文和英文
+ lang: 'cn',
+ // 主题,分别有concise简洁风格,default默认风格,grid格子主题,molv墨绿背景主题,#393D49自定义背景色主题
+ theme: 'default',
+ // 控件定位方式定位, 默认absolute,支持:fixed/absolute/static
+ position: null,
+ // 是否开启公历重要节日,仅支持中文版
+ calendar: false,
+ // 日期备注,如重要事件或活动标记
+ mark: {},
+ // 控件层叠顺序
+ zIndex: null,
+ // 控件在打开时触发,返回参数date为初始的日期时间对象
+ ready: function (date) { },
+ // 控件选择完毕后的回调,点击清空/现在/确定也均会触发
+ // 返回参数value为生成的值、date为日期时间对象、endDate为结束的日期时间对象
+ done: function (value, date, endDate) { },
+ // 日期时间改变后的回调,切换上页下页、选择年月时触发
+ // 返回参数value为生成的值、date为日期时间对象、endDate为结束的日期时间对象
+ change: function (value, date, endDate) { }
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} options 配置项
+ */
+ var mainFn = function (options) {
+ var that = this;
+ // 合并默认配置,生成新的配置
+ that.config = $.extend({}, djcpsDate.config, options);
+ that.loadHtml().then(function () {
+ return that.renderHtml();
+ }).then(function () {
+ that.initDate();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#dateCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsDate/djcpsDate.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 渲染模板文件
+ */
+ mainFn.prototype.renderHtml = function () {
+ var that = this;
+ var defer = $.Deferred();
+ //整合模板数据
+ var data = {
+ id: that.config.id,
+ placeholder: that.config.placeholder,
+ disabled: that.config.disabled
+ };
+ var tpl = $('#dateTpl').html();
+ laytpl(tpl).render(data, function (html) {
+ that.config.container.html(html);
+ defer.resolve();
+ });
+ return defer.promise();
+ };
+ // 初始化日期与时间选择
+ mainFn.prototype.initDate = function () {
+ var that = this;
+ that.config.elem = '#' + that.config.id;
+ laydate.render(that.config);
+ };
+ // 组件入口
+ djcpsDate.init = function (options) {
+ return new mainFn(options);
+ };
+ // 输出组件
+ exports('djcpsDate', djcpsDate);
+});
diff --git a/static/components/modules/djcpsFlow/djcpsFlow.css b/static/components/modules/djcpsFlow/djcpsFlow.css
new file mode 100644
index 0000000..076fb0d
--- /dev/null
+++ b/static/components/modules/djcpsFlow/djcpsFlow.css
@@ -0,0 +1,31 @@
+.layflow {
+ float: left;
+ width: 680px;
+ height: 500px;
+ overflow: auto;
+}
+.layflow li{
+ float: left;
+ margin: 15px;
+ width: 300px;
+ height: 100px;
+ line-height: 100px;
+ background: #f1f1f1;
+ text-align: center;
+}
+.layflowlazyimg{
+ float: left;
+ width: 650px;
+ height: 500px;
+ overflow: auto;
+}
+.layflowlazyimg li {
+ float: left;
+ margin: 15px;
+ width: 180px;
+}
+.layflowlazyimg li img{
+ width: 100%;
+ height: 100%;
+ border: none;
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsFlow/djcpsFlow.html b/static/components/modules/djcpsFlow/djcpsFlow.html
new file mode 100644
index 0000000..1a04dda
--- /dev/null
+++ b/static/components/modules/djcpsFlow/djcpsFlow.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsFlow/djcpsFlow.js b/static/components/modules/djcpsFlow/djcpsFlow.js
new file mode 100644
index 0000000..359abde
--- /dev/null
+++ b/static/components/modules/djcpsFlow/djcpsFlow.js
@@ -0,0 +1,75 @@
+/**
+ * 流加载组件
+ * layui-flow二次封装
+ */
+layui.define('flow', function (exports) {
+ "use strict";
+ var layflow = layui.flow;
+ // 定义组件
+ var djcpsFlow = {
+ // 初始配置
+ config: {
+ // 流加载容器,传入dom对象如$('#layflow')
+ elem: $('#layflow'),
+ // 滚动条所在元素选择器,默认document。如果你不是通过窗口滚动来触发流加载,而是页面中的某一个容器的滚动条,那么通过该参数指定即可。。
+ scrollElem: '',
+ // 是否自动加载。默认true。如果设为false,点会在列表底部生成一个“加载更多”的button,则只能点击它才会加载下一页数据。
+ isAuto: true,
+ // 用于显示末页内容,可传入任意HTML字符。默认为:没有更多了
+ end: '没有更多了',
+ // 是否开启图片懒加载。默认false。如果设为true,则只会对在可视区域的图片进行按需加载。但与此同时,在拼接列表字符的时候,你不能给列表中的img元素赋值src,必须要用lay-src取代
+ isLazyimg: false,
+ // 与底部的临界距离,默认50。即当滚动条与底部产生该距离时,触发加载。注意:只有在isAuto为true时有效。
+ mb: '150',
+ // 到达临界点触发加载的回调。信息流最重要的一个存在。
+ done: function (page, next) { }
+ }
+ };
+ /**
+ * 核心功能构造函数 options 为配置参数
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsFlow.config, options);
+ that.loadHtml().then(function () {
+ that.initFlow();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#flowCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsFlow/djcpsFlow.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化流加载功能
+ */
+ mainFn.prototype.initFlow = function () {
+ var that = this;
+ layflow.load(that.config);
+ };
+ /**
+ * 组件入口
+ */
+ djcpsFlow.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ /**
+ * 输出组件
+ */
+ exports('djcpsFlow', djcpsFlow);
+});
diff --git a/static/components/modules/djcpsForm/djcpsForm.css b/static/components/modules/djcpsForm/djcpsForm.css
new file mode 100644
index 0000000..afd63ab
--- /dev/null
+++ b/static/components/modules/djcpsForm/djcpsForm.css
@@ -0,0 +1,86 @@
+/* 表单基础样式 */
+
+/* 表单主色调替换 */
+
+.layui-form-select dl dd.layui-this {
+ background-color: #1886E3;
+}
+
+.layui-form-radio:hover i, .layui-form-radioed i {
+ color: #1886E3;
+}
+
+.layui-btn {
+ background-color: #1886E3;
+}
+
+.layui-form-checked span, .layui-form-checked:hover span {
+ background-color: #1886E3;
+}
+
+.layui-form-checked i {
+ color: #1886E3;
+}
+
+.layui-form-checked[lay-skin=primary] span, .layui-form-checkbox[lay-skin=primary]:hover span {
+ background-color: #fff;
+}
+
+.layui-form-checked[lay-skin=primary] i {
+ border-color: #1886E3;
+ background-color: #1886E3;
+ color: #fff;
+}
+
+.layui-form-checkbox[lay-skin=primary]:hover i {
+ border-color: #1886E3;
+}
+
+.layui-form-onswitch {
+ border-color: #1886E3;
+ background-color: #1886E3;
+}
+
+/* checkbox禁用样式统一 */
+
+.layui-checkbox-disbaled.layui-form-checked span, .layui-checkbox-disbaled.layui-form-checked:hover span {
+ background-color: #1886E3!important;
+}
+
+.layui-checkbox-disbaled.layui-form-checked i, .layui-checkbox-disbaled.layui-form-checked:hover i {
+ color: #1886E3!important;
+}
+
+.layui-checkbox-disbaled.layui-form-checked[lay-skin=primary] span, .layui-checkbox-disbaled.layui-form-checked[lay-skin=primary]:hover span {
+ background-color: transparent!important;
+}
+
+.layui-checkbox-disbaled.layui-form-checked[lay-skin=primary] i, .layui-checkbox-disbaled.layui-form-checked[lay-skin=primary]:hover i {
+ color: #fff!important;
+ border-color: #1886E3!important;
+}
+
+.layui-checkbox-disbaled.layui-form-onswitch {
+ border-color: #1886E3!important;
+}
+
+/* 表单校验提示相关 */
+
+.layui-form-danger, .layui-form-danger:hover {
+ border-color: #FF5722!important;
+}
+
+/* 用于表单校验的上传input框隐藏 */
+
+.uploadContent {
+ width: 0;
+ border: 0;
+ height: 0;
+}
+
+/* 其他表单基础样式 */
+
+.layui-input, .layui-textarea {
+ outline: none;
+ resize: none;
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsForm/djcpsForm.html b/static/components/modules/djcpsForm/djcpsForm.html
new file mode 100644
index 0000000..b8210e2
--- /dev/null
+++ b/static/components/modules/djcpsForm/djcpsForm.html
@@ -0,0 +1,87 @@
+
+
diff --git a/static/components/modules/djcpsForm/djcpsForm.js b/static/components/modules/djcpsForm/djcpsForm.js
new file mode 100644
index 0000000..6246d8c
--- /dev/null
+++ b/static/components/modules/djcpsForm/djcpsForm.js
@@ -0,0 +1,320 @@
+/**
+ * 表单组件
+ * layui-form二次封装
+ */
+layui.define(['form', 'laytpl', 'layer', 'djcpsDate', 'djcpsUpload'], function (exports) {
+ "use strict";
+ var layform = layui.form,
+ laytpl = layui.laytpl,
+ layer = layui.layer,
+ djcpsDate = layui.djcpsDate,
+ djcpsUpload = layui.djcpsUpload;
+ var dateArr = [],
+ uploadArr = [];
+ var djcpsForm = {
+ // 初始配置
+ config: {
+ //外部容器元素,传入jquery的dom对象
+ container: $('#form'),
+ //lay-filter过滤器
+ layFilter: 'form',
+ //lay-verType异常提示层模式,msg默认提示框,tips吸附层,alert对话框
+ layVerType: 'msg',
+ //是否为编辑状态,编辑状态下初始化时立即触发全局表单校验
+ isEdit: false,
+ //表单方框风格,默认不开启
+ pane: false,
+ //表单数据
+ data: [{
+ //元素的label标签内容
+ label: '',
+ //元素类型,password密码,text单行文本,select下拉框,checkbox复选框,radio单选框,textarea文本域,date日期控件,custom自定义html片段
+ // 时间控件归入custom,并在业务页面创建后传入customHtml
+ type: 'text',
+ //元素的name值
+ name: '',
+ //元素的表单校验名和校验方法,自定义
+ layVerify: {
+ name: '',
+ rules: function (value) { }
+ },
+ //表单元素的值,text、password、textarea
+ value: '',
+ //各组件的其他配置项(非通用配置)
+ options: {
+ //是否禁用该组件,select、text、password、textarea、date
+ disabled: false,
+ //是否存在分组,select
+ hasGroup: false,
+ //是否允许搜索,select
+ laySearch: false,
+ //子项数据,select、radio、checkbox
+ data: [{
+ //子项显示值,select、radio、checkbox
+ title: '',
+ //子项value值,select、radio、checkbox
+ value: '',
+ //子项是否禁用,select、radio、checkbox
+ disabled: false,
+ //子项是否被选中,radio、checkbox、select
+ checked: false,
+ //checkbox风格,primary原始风格,switch开关风格,''为默认风格(文字+√)
+ laySkin: 'primary',
+ //自定义开关两种状态的文本,checkbox
+ layText: '开|关'
+ }],
+ //组件的placeholder,text、password、textarea、date
+ placeholder: '',
+ //是否开启自动填充,text、password
+ autocomplete: false,
+ //是否只读,text、password、textarea
+ readonly: false,
+ },
+ //自定义html片段,custom
+ customHtml: ''
+ }]
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} options 配置项
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsForm.config, options);
+ that.loadHtml().then(function () {
+ return that.renderHtml();
+ }).then(function () {
+ that.initForm();
+ that.rules = {};
+ var initValue = {};
+ for (var i = 0; i < that.config.data.length; i++) {
+ var data = that.config.data[i];
+ //存在自定义校验规则的,初始化自定义校验规则
+ if (data.layVerify && data.layVerify.rules) {
+ that.rules[data.layVerify.name] = data.layVerify.rules;
+ }
+ //text、password、textarea存在value初始值的,渲染初始值
+ if (data.value) {
+ initValue[data.name] = data.value;
+ }
+ //对日期时间控件、文件上传控件另外处理
+ if (data.type === 'date') {
+ var options = (function (dateData) {
+ var newOptions = $.extend({}, dateData.options, {
+ container: $('.' + dateData.name + ' .layui-input-block'),
+ //重写done事件,加入表单校验监听机制
+ done: function (value, date, endDate) {
+ that.singleValidate($('.' + dateData.name + ' .layui-input-block').find('input'));
+ if (typeof dateData.options.done === 'function') {
+ dateData.options.done(value, date, endDate);
+ }
+ }
+ });
+ return newOptions;
+ })(data);
+ dateArr[data.name] = djcpsDate.init(options);
+ $('.' + data.name + ' .layui-input-block').find('input').attr({
+ name: data.name,
+ 'lay-verify': data.layVerify.name
+ });
+ } else if (data.type === 'upload') {
+ var options = (function (uploadData) {
+ var newOptions = $.extend({}, uploadData.options, {
+ //重写choose和before事件,多传入实例参数,方便在业务层调用实例方法
+ choose: function (obj) {
+ if (typeof uploadData.options.choose === 'function') {
+ uploadData.options.choose(obj, uploadArr[uploadData.name]);
+ }
+ },
+ before: function (obj) {
+ if (typeof uploadData.options.before === 'function') {
+ uploadData.options.before(obj, uploadArr[uploadData.name]);
+ }
+ }
+ });
+ return newOptions;
+ })(data);
+ uploadArr[data.name] = djcpsUpload.init(options);
+ $('.' + data.name + ' .layui-input-block').find('.uploadContent').attr({
+ name: data.name,
+ 'lay-verify': data.layVerify.name
+ });
+ }
+ }
+ //全局设置异常提示模式,包括自定义模块
+ that.config.container.find('input,textarea,select').attr('lay-verType', that.config.layVerType);
+ that.verifyRules();
+ that.setValue(initValue);
+ that.autoValidate();
+ //编辑状态下初始化即触发全局校验
+ if (that.config.isEdit) {
+ that.fullValidate();
+ }
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#formCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsForm/djcpsForm.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 渲染模板文件
+ */
+ mainFn.prototype.renderHtml = function () {
+ var that = this;
+ var defer = $.Deferred();
+ that.arrangeData();
+ var data = {
+ layFilter: that.config.layFilter,
+ layVerType: that.config.layVerType,
+ pane: that.config.pane,
+ data: that.config.data
+ };
+ var tpl = $('#formTpl').html();
+ laytpl(tpl).render(data, function (html) {
+ that.config.container.html(html);
+ defer.resolve();
+ });
+ return defer.promise();
+ };
+ /**
+ * 处理select数据,返回一个处理后的新数据
+ */
+ mainFn.prototype.arrangeData = function () {
+ var that = this;
+ var arrangedData = that.config.data;
+ //整理后的select数据
+ var selectOptionData = {};
+ for (var i = 0; i < arrangedData.length; i++) {
+ //筛选出select数据
+ if (arrangedData[i].type === 'select' && arrangedData[i].options.hasGroup) {
+ for (var j = 0; j < arrangedData[i].options.data.length; j++) {
+ var optionData = arrangedData[i].options.data[j];
+ //如果带groupLabel属性,则存在select分组,并对相同的groupLabel值进行分组
+ //分组数据归为对象下的一个数组,不分组数据归为一个对象
+ if (optionData.groupLabel) {
+ if (selectOptionData[optionData.groupLabel]) {
+ selectOptionData[optionData.groupLabel].push(optionData);
+ } else {
+ selectOptionData[optionData.groupLabel] = [].concat([optionData]);
+ }
+ } else {
+ selectOptionData[j] = optionData;
+ }
+ }
+ //将老数据替换成新数据
+ arrangedData[i].options.data = selectOptionData;
+ }
+ }
+ };
+ /**
+ * 初始化表单
+ * @param {*} type 更新元素类型,select下拉框,checkbox复选框,radio单选框,null全部元素
+ */
+ mainFn.prototype.initForm = function (type) {
+ var that = this;
+ layform.render(type, that.config.layFilter);
+ };
+ /**
+ * 验证规则设定
+ */
+ mainFn.prototype.verifyRules = function () {
+ var that = this;
+ layform.verify(that.rules);
+ };
+ /**
+ * 表单事件监听
+ * @param {*} event 监听的事件名
+ * @param {*} callback 监听的回调事件
+ */
+ mainFn.prototype.on = function (events, callback) {
+ layform.on(events, function (obj) {
+ if (typeof callback === 'function') {
+ callback(obj);
+ }
+ return false;
+ });
+ };
+ /**
+ * 初始赋值
+ * @param {*} object 初始值对象,传入{元素name: 元素value}的形式
+ */
+ mainFn.prototype.setValue = function (object) {
+ var that = this;
+ layform.val(that.config.layFilter, object);
+ };
+ /**
+ * 初始化表单后开启自动校验
+ */
+ mainFn.prototype.autoValidate = function () {
+ var that = this;
+ that.config.container.find('*[lay-verify]').each(function (index, item) {
+ if (!$(item).hasClass('layui-input-date')) {
+ $(item).unbind().bind('blur', function () {
+ that.singleValidate($(this));
+ });
+ }
+ });
+ };
+ /**
+ * 单个表单项校验,校验逻辑与layui.form源码基本一致
+ * @param {*} $dom 表单项元素
+ */
+ mainFn.prototype.singleValidate = function ($dom) {
+ var that = this;
+ var rule = that.rules[$dom.attr('lay-verify')];
+ var value = $dom.val();
+ //注:异步请求需要设置async:false后return结果
+ var invalidMsg = rule(value);
+ if (invalidMsg) {
+ $dom.addClass('layui-form-danger');
+ if (that.config.layVerType === 'tips') {
+ layer.tips(invalidMsg, function () {
+ if (typeof $dom.attr('lay-ignore') !== 'string') {
+ if ($dom[0].tagName.toLowerCase() === 'select' || /^checkbox|radio$/.test($dom[0].type)) {
+ return $dom.next();
+ }
+ }
+ return $dom;
+ }(), { tips: 1, tipsMore: true });
+ } else if (that.config.layVerType === 'alert') {
+ layer.alert(invalidMsg, { title: '提示', shadeClose: true });
+ } else {
+ layer.msg(invalidMsg, { icon: 5, shift: 6 });
+ }
+ } else {
+ $dom.removeClass('layui-form-danger');
+ }
+ };
+ /**
+ * 全局校验表单
+ */
+ mainFn.prototype.fullValidate = function () {
+ var that = this;
+ that.config.container.find('*[lay-verify]').each(function (index, item) {
+ that.singleValidate($(item));
+ });
+ };
+ // 组件入口
+ djcpsForm.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ // 输出组件
+ exports('djcpsForm', djcpsForm);
+});
diff --git a/static/components/modules/djcpsLoad/djcpsLoad.css b/static/components/modules/djcpsLoad/djcpsLoad.css
new file mode 100644
index 0000000..3c11c05
--- /dev/null
+++ b/static/components/modules/djcpsLoad/djcpsLoad.css
@@ -0,0 +1 @@
+.cps-layer-load {}
\ No newline at end of file
diff --git a/static/components/modules/djcpsLoad/djcpsLoad.html b/static/components/modules/djcpsLoad/djcpsLoad.html
new file mode 100644
index 0000000..340aa25
--- /dev/null
+++ b/static/components/modules/djcpsLoad/djcpsLoad.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsLoad/djcpsLoad.js b/static/components/modules/djcpsLoad/djcpsLoad.js
new file mode 100644
index 0000000..b711c19
--- /dev/null
+++ b/static/components/modules/djcpsLoad/djcpsLoad.js
@@ -0,0 +1,91 @@
+/**
+ * 加载层load组件
+ * layui-layer-load二次封装
+ */
+layui.define('layer', function (exports) {
+ "use strict";
+ var layer = layui.layer;
+ // 定义组件
+ var djcpsLoad = {
+ // 初始配置
+ config: {
+ //样式类名,会加载加载层元素的最外层
+ skin: 'cps-layer-load',
+ //宽高,auto自适应,500px为宽度500高度仍自适应
+ area: "auto",
+ //坐标,auto垂直水平居中,100px为top坐标100水平仍居中,['100px', '50px']为top、left坐标
+ //快捷设置,t顶部居中,r右边缘居中,b底部居中,l左边缘居中,lt左上角,lb左下角,rt右上角,rb右下角
+ offset: 'auto',
+ //遮罩,加载层外区域#000背景透明度,0为不遮罩,[0.8, '#393D49']可自定义遮罩颜色
+ shade: 0.3,
+ //是否固定在可视区域(鼠标滚动时)
+ fixed: true,
+ //是否允许浏览器出现滚动条
+ scrollbar: true,
+ //层叠顺序,一般用于解决和其他组件的层叠冲突
+ zIndex: 19891014,
+ //触发拖拽的元素,传元素选择器'.layui-layer-title',传false禁止拖拽
+ move: false
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} type 图标类型,可选0,1,2
+ * @param {*} options 配置项
+ */
+ var mainFn = function (type, options) {
+ var that = this;
+ that.type = type !== undefined ? type : 1;
+ that.config = $.extend({}, djcpsLoad.config, options);
+ that.loadHtml().then(function () {
+ that.initLoad();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#loadCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsLoad/djcpsLoad.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化加载层功能
+ */
+ mainFn.prototype.initLoad = function () {
+ var that = this;
+ that.load = layer.load(that.type, that.config);
+ };
+ /**
+ * 关闭加载层
+ */
+ mainFn.prototype.close = function () {
+ var that = this;
+ if(that.load) {
+ layer.close(that.load);
+ } else {
+ setTimeout(function() {
+ that.close();
+ }, 50);
+ }
+
+ };
+ //组件入口
+ djcpsLoad.init = function (type, options) {
+ var inst = new mainFn(type, options);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsLoad', djcpsLoad);
+});
diff --git a/static/components/modules/djcpsModal/djcpsModal.css b/static/components/modules/djcpsModal/djcpsModal.css
new file mode 100644
index 0000000..30e23c8
--- /dev/null
+++ b/static/components/modules/djcpsModal/djcpsModal.css
@@ -0,0 +1,18 @@
+.cps-layer-modal {
+ -webkit-border-radius: 0 0 12px 12px;
+ -moz-border-radius: 0 0 12px 12px;
+ -ms-border-radius: 0 0 12px 12px;
+ border-radius: 0 0 12px 12px;
+ background: #ffffff;
+ border-radius: 12px;
+ padding: 0px 10px;
+}
+
+.cps-layer-modal .layui-layer-title {
+ background: #fff;
+ border-bottom: 1px solid #b3b3b3;
+ -webkit-border-radius: 12px 12px 0 0;
+ -moz-border-radius: 12px 12px 0 0;
+ -ms-border-radius: 12px 12px 0 0;
+ border-radius: 12px 12px 0 0;
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsModal/djcpsModal.html b/static/components/modules/djcpsModal/djcpsModal.html
new file mode 100644
index 0000000..e0a85c2
--- /dev/null
+++ b/static/components/modules/djcpsModal/djcpsModal.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsModal/djcpsModal.js b/static/components/modules/djcpsModal/djcpsModal.js
new file mode 100644
index 0000000..a76028c
--- /dev/null
+++ b/static/components/modules/djcpsModal/djcpsModal.js
@@ -0,0 +1,286 @@
+/**
+ * 模态框(弹窗)组件
+ * layui-layer-open二次封装
+ */
+layui.define('layer', function (exports) {
+ "use strict";
+ var layer = layui.layer;
+ // 定义组件
+ var djcpsModal = {
+ // 初始配置
+ config: {
+ //内容层类型: 1页面层,2iframe层
+ type: 1,
+ //标题,也可以设置标题样式 ['文本', 'font-size:18px;'],传false则不显示标题栏
+ title: '提示',
+ //内容,页面层为文本或jquery的dom元素,iframe层则为url
+ content: '',
+ //样式类名,会加载模态框元素的最外层
+ skin: 'cps-layer-modal',
+ //宽高,auto自适应,500px为宽度500高度仍自适应
+ area: ['500px', '300px'],
+ //坐标,auto垂直水平居中,100px为top坐标100水平仍居中,['100px', '50px']为top、left坐标
+ //快捷设置,t顶部居中,r右边缘居中,b底部居中,l左边缘居中,lt左上角,lb左下角,rt右上角,rb右下角
+ offset: 'auto',
+ //关闭按钮,样式1或2,0为无关闭按钮
+ closeBtn: 1,
+ //遮罩,模态框外区域#000背景透明度,0为不遮罩,[0.8, '#393D49']可自定义遮罩颜色
+ shade: 0.3,
+ //是否通过点击遮罩来关闭模态框
+ shadeClose: false,
+ //是否显示最大最小化按钮
+ maxmin: false,
+ //是否固定在可视区域(鼠标滚动时)
+ fixed: true,
+ //是否允许拉伸
+ resize: false,
+ //是否允许浏览器出现滚动条
+ scrollbar: true,
+ //最大宽度,只有在area宽度自适应时才有效
+ maxWidth: 500,
+ //最大高度,只有在area高度自适应时才有效
+ maxHeight: 300,
+ //层叠顺序,一般用于解决和其他组件的层叠冲突
+ zIndex: 19891014,
+ //触发拖拽的元素,传元素选择器'.layui-layer-title',传false禁止拖拽
+ move: false,
+ //是否允许拖拽到窗口外
+ moveOut: false
+ //模态框弹出后的回调,带layero参数为当前层的dom对象,index参数为当前层的索引
+ // success: function (layero, index) { },
+ //点击右上角关闭按钮时的回调,默认自动触发关闭,return false可阻止关闭带layero参数为当前层的dom对象,index参数为当前层的索引
+ // cancel: function (index, layero) { },
+ //模态框销毁后的回调,不管确认还是取消都会触发,不带任何参数
+ // end: function () { }
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} options 配置项
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsModal.config, options);
+ that.loadHtml().then(function () {
+ that.initModal();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#modalCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsModal/djcpsModal.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化模态框功能
+ */
+ mainFn.prototype.initModal = function () {
+ var that = this;
+ setTimeout(function () {
+ that.modal = layer.open(that.config);
+ });
+ };
+ /**
+ * 模态框弹出后的回调
+ * 带layero参数为当前层的dom对象,index参数为当前层的索引
+ */
+ mainFn.prototype.success = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { success: fn });
+ }
+ };
+ /**
+ * 点击右上角关闭按钮时的回调,默认自动触发关闭,return false可阻止关闭
+ * 带layero参数为当前层的dom对象,index参数为当前层的索引
+ */
+ mainFn.prototype.cancel = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { cancel: fn });
+ }
+ };
+ /**
+ * 模态框销毁后的回调,不管确认还是取消都会触发,不带任何参数
+ */
+ mainFn.prototype.end = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { end: fn });
+ }
+ };
+ /**
+ * 模态框拉伸后的回调,带layero参数为当前层的dom对象
+ */
+ mainFn.prototype.resizing = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { end: fn });
+ }
+ };
+ /**
+ * 拖拽完毕后的回调,带layero参数为当前层的dom对象
+ */
+ mainFn.prototype.moveEnd = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { end: fn });
+ }
+ };
+ /**
+ * 模态框最大化后的回调
+ * 带layero参数为当前层的dom对象
+ */
+ mainFn.prototype.full = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { full: fn });
+ }
+ };
+ /**
+ * 模态框最小化后的回调
+ * 带layero参数为当前层的dom对象
+ */
+ mainFn.prototype.min = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { min: fn });
+ }
+ };
+ /**
+ * 模态框恢复原窗口后的回调
+ * 带layero参数为当前层的dom对象
+ */
+ mainFn.prototype.restore = function (fn) {
+ var that = this;
+ if (typeof fn === 'function') {
+ that.config = $.extend({}, that.config, { restore: fn });
+ }
+ };
+ /**
+ * 关闭模态框
+ * @param index 当前模态框的index
+ */
+ mainFn.prototype.close = function (index) {
+ var that = this;
+ var modalIndex = index || that.modal;
+ if (modalIndex) {
+ layer.close(modalIndex);
+ }
+ };
+ /**
+ * 批量关闭模态框
+ * @param type 模态框类型,不传关闭所有模态框
+ */
+ mainFn.prototype.closeAll = function (type) {
+ layer.closeAll(type);
+ };
+ /**
+ * 改变模态框最外层的样式
+ * @param cssObj css对象,以{'font-size': '18px'}为例
+ * @param index 当前模态框的index
+ */
+ mainFn.prototype.changeStyle = function (cssObj, index) {
+ var that = this;
+ var modalIndex = index || that.modal;
+ if (modalIndex) {
+ layer.style(modalIndex, cssObj);
+ }
+ };
+ /**
+ * 改变模态框的标题
+ * @param newTitle 新的标题
+ * @param index 当前模态框的index
+ */
+ mainFn.prototype.changeTitle = function (newTitle, index) {
+ var that = this;
+ var modalIndex = index || that.modal;
+ if (modalIndex) {
+ layer.title(newTitle, modalIndex);
+ }
+ };
+ /**
+ * 获取iframe页的dom元素,返回一个jquery的dom元素
+ * @param dom 要获取的dom元素
+ * @param index 当前模态框的index
+ */
+ mainFn.prototype.getChildFrame = function (dom, index) {
+ var that = this;
+ var modalIndex = index || that.modal;
+ if (modalIndex) {
+ return layer.getChildFrame(dom, modalIndex);
+ }
+ };
+ /**
+ * 指定iframe层自适应
+ * @param index 当前模态框的index
+ */
+ mainFn.prototype.iframeAuto = function (index) {
+ var that = this;
+ var modalIndex = index || that.modal;
+ if (modalIndex) {
+ layer.iframeAuto(modalIndex);
+ }
+ };
+ /**
+ * 重置iframe层的url
+ * @param url 新的iframe地址
+ * @param index 当前模态框的index
+ */
+ mainFn.prototype.iframeSrc = function (url, index) {
+ var that = this;
+ var modalIndex = index || that.modal;
+ if (modalIndex) {
+ layer.iframeSrc(modalIndex, url);
+ }
+ };
+ /**
+ * 置顶当前模态框窗口
+ * @param layero 当前模态框的dom元素对象layero
+ */
+ mainFn.prototype.setTop = function (layero) {
+ layer.iframeSrc(layero);
+ };
+ /**
+ * 对模态框进行最大化、最小化、恢复原窗口
+ * @param type 操作类型,1最大化,2最小化,3恢复原窗口
+ * @param index 当前模态框的index
+ */
+ mainFn.prototype.setMaxMin = function (type, index) {
+ var that = this;
+ var modalIndex = index || that.modal;
+ if (modalIndex) {
+ if (type === 1) {
+ layer.full(modalIndex);
+ } else if (type === 2) {
+ layer.min(modalIndex);
+ } else if (type === 3) {
+ try {
+ layer.restore(modalIndex);
+ } catch (e) {
+ console.log('未进行过最大、最小化,因此无法执行恢复原窗口操作!')
+ }
+ }
+ }
+ };
+ //组件入口
+ djcpsModal.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsModal', djcpsModal);
+});
diff --git a/static/components/modules/djcpsMsg/djcpsMsg.css b/static/components/modules/djcpsMsg/djcpsMsg.css
new file mode 100644
index 0000000..e69de29
diff --git a/static/components/modules/djcpsMsg/djcpsMsg.html b/static/components/modules/djcpsMsg/djcpsMsg.html
new file mode 100644
index 0000000..c687658
--- /dev/null
+++ b/static/components/modules/djcpsMsg/djcpsMsg.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsMsg/djcpsMsg.js b/static/components/modules/djcpsMsg/djcpsMsg.js
new file mode 100644
index 0000000..55a28a0
--- /dev/null
+++ b/static/components/modules/djcpsMsg/djcpsMsg.js
@@ -0,0 +1,89 @@
+/**
+ * 消息框msg组件
+ * layui-layer-msg二次封装
+ */
+layui.define('layer', function (exports) {
+ "use strict";
+ var layer = layui.layer;
+ // 定义组件
+ var djcpsMsg = {
+ // 初始配置
+ config: {
+ //宽高,auto自适应,500px为宽度500高度仍自适应
+ area: "auto",
+ //坐标,auto垂直水平居中,100px为top坐标100水平仍居中,['100px', '50px']为top、left坐标
+ //快捷设置,t顶部居中,r右边缘居中,b底部居中,l左边缘居中,lt左上角,lb左下角,rt右上角,rb右下角
+ offset: 'auto',
+ //图标,显示在文字之前
+ icon: -1,
+ //关闭按钮,样式1或2,0为无关闭按钮
+ closeBtn: 0,
+ //遮罩,消息框外区域#000背景透明度,0为不遮罩,[0.8, '#393D49']可自定义遮罩颜色
+ shade: 0,
+ //是否通过点击遮罩来关闭消息框
+ shadeClose: false,
+ //自动关闭所需毫秒
+ time: 3000,
+ //是否固定在可视区域(鼠标滚动时)
+ fixed: true,
+ //是否允许浏览器出现滚动条
+ scrollbar: true,
+ //层叠顺序,一般用于解决和其他组件的层叠冲突
+ zIndex: 19891014,
+ //触发拖拽的元素,传元素选择器'.layui-layer-title',传false禁止拖拽
+ move: false
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} content 内容
+ * @param {*} options 配置项
+ * @param {*} callback 回调函数,不带任何参数
+ */
+ var mainFn = function (content, options, callback) {
+ var that = this;
+ that.content = content === undefined ? '' : content;
+ that.config = $.extend({}, djcpsMsg.config, options);
+ that.callback = typeof callback === 'function' ? callback : undefined;
+ that.loadHtml().then(function () {
+ that.initMsg();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#msgCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsMsg/djcpsMsg.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化消息框功能
+ */
+ mainFn.prototype.initMsg = function () {
+ var that = this;
+ layer.msg(that.content, that.config, function () {
+ if (typeof that.callback === "function") {
+ that.callback();
+ }
+ });
+ };
+ //组件入口
+ djcpsMsg.init = function (content, options, callback) {
+ var inst = new mainFn(content, options, callback);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsMsg', djcpsMsg);
+});
diff --git a/static/components/modules/djcpsPage/djcpsPage.css b/static/components/modules/djcpsPage/djcpsPage.css
new file mode 100644
index 0000000..a2430d2
--- /dev/null
+++ b/static/components/modules/djcpsPage/djcpsPage.css
@@ -0,0 +1,72 @@
+/* laypage分页样式 */
+
+.layui-laypage-cps .layui-laypage-prev {
+ border-radius: 6px !important;
+ margin-right: 11px !important;
+}
+
+.layui-laypage-cps .layui-laypage-next {
+ margin-left: 11px !important;
+}
+
+.layui-laypage-cps.layui-laypage a, .layui-laypage-cps.layui-laypage span {
+ -webkit-border-radius: 6px;
+ -moz-border-radius: 6px;
+ -ms-border-radius: 6px;
+ border-radius: 6px;
+ margin: 0 6px;
+ border: none;
+ background-color: #f1eff0;
+}
+
+.layui-laypage-cps .layui-laypage-skip {
+ background: #fff !important;
+}
+
+.layui-laypage-cps.layui-laypage .layui-laypage-curr {
+ -webkit-border-radius: 6px;
+ -moz-border-radius: 6px;
+ -ms-border-radius: 6px;
+ border-radius: 6px;
+ overflow: hidden;
+ padding: 0 11px;
+ margin: 0 3px;
+}
+
+.layui-laypage-cps .layui-laypage-curr .layui-laypage-em {
+ background-color: #1886e3 !important;
+}
+
+.layui-laypage-cps.layui-laypage input {
+ -webkit-border-radius: 6px;
+ -moz-border-radius: 6px;
+ -ms-border-radius: 6px;
+ border-radius: 6px;
+}
+
+.layui-laypage-cps .layui-laypage-btn {
+ -webkit-border-radius: 6px;
+ -moz-border-radius: 6px;
+ -ms-border-radius: 6px;
+ border-radius: 6px;
+ width: auto;
+}
+
+.layui-laypage-cps.layui-laypage button, .layui-laypage-cps.layui-laypage input {
+ -webkit-border-radius: 6px;
+ -moz-border-radius: 6px;
+ -ms-border-radius: 6px;
+ border-radius: 6px;
+}
+
+.layui-laypage-cps.layui-laypage input:focus {
+ border: 1px solid #e2e2e2;
+}
+
+.layui-laypage-cps.layui-laypage a, .layui-laypage-cps.layui-laypage span {
+ -webkit-border-radius: 6px !important;
+ -moz-border-radius: 6px !important;
+ border-radius: 6px !important;
+ padding: 0 11px;
+ margin: 0 3px;
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsPage/djcpsPage.html b/static/components/modules/djcpsPage/djcpsPage.html
new file mode 100644
index 0000000..d1999ae
--- /dev/null
+++ b/static/components/modules/djcpsPage/djcpsPage.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsPage/djcpsPage.js b/static/components/modules/djcpsPage/djcpsPage.js
new file mode 100644
index 0000000..0c65220
--- /dev/null
+++ b/static/components/modules/djcpsPage/djcpsPage.js
@@ -0,0 +1,98 @@
+/**
+ * 分页组件
+ * layui-laypage二次封装
+ */
+layui.define('laypage', function (exports) {
+ "use strict";
+ var laypage = layui.laypage;
+ // 定义组件
+ var djcpsPage = {
+ // 初始配置
+ config: {
+ // 容器,传入dom对象如$('#page')
+ elem: $('#page'),
+ // 数据总数
+ count: 0,
+ // 每页显示的条数
+ limit: 10,
+ // 每页条数的下拉框
+ limits: [10, 20, 30, 40, 50],
+ // 当前页,从1开始
+ curr: 1,
+ // 连续分页数
+ groups: 4,
+ // 上一页文字
+ prev: '上一页',
+ // 下一页文字
+ next: '下一页',
+ // 首页文字
+ first: '首页',
+ // 末页文字
+ last: '末页',
+ // 自定义排版:count总条数、prev上一页、page分页、next下一页、limit每页条数、refresh刷新、skip跳页
+ layout: ['prev', 'page', 'next', 'skip'],
+ // 自定义主题,会生成layui-laypage-xxx的css类
+ theme: 'default',
+ // 自定义hash值,在触发分页时,会自动对url追加hash的对应值,并在页面载入时就定位到指定页
+ hash: false,
+ // 页面切换时触发
+ jump: function (obj, first) { },
+ // 非layui原生配置项,控制单页时是否隐藏分页
+ onePageHide: true
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} options 配置项
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsPage.config, options);
+ that.loadHtml().then(function () {
+ that.initPage();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#pageCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsPage/djcpsPage.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化分页功能
+ */
+ mainFn.prototype.initPage = function () {
+ var that = this;
+ // 无数据时不显示分页
+ if (that.config.count === 0) {
+ that.config.elem.hide();
+ }
+ // 配置了单页隐藏 且 不显示每页条数下拉框 且 总页数为1时,也不显示分页
+ else if (that.config.onePageHide && that.config.layout.join(',').indexOf('limit') < 0 && Number(that.config.count) / Number(that.config.limit) <= 1) {
+ that.config.elem.hide();
+ } else {
+ that.config.elem.show();
+ }
+ laypage.render(that.config);
+ };
+ //组件入口
+ djcpsPage.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsPage', djcpsPage);
+});
diff --git a/static/components/modules/djcpsPanel/djcpsPanel.css b/static/components/modules/djcpsPanel/djcpsPanel.css
new file mode 100644
index 0000000..2ab28b1
--- /dev/null
+++ b/static/components/modules/djcpsPanel/djcpsPanel.css
@@ -0,0 +1,15 @@
+.laypanel-switch{
+ margin: 10px;
+ width: 80px;
+ height: 30px;
+ line-height: 30px;
+ text-align: center;
+ background: #1886e3;
+ color: #fFF;
+ border: 0;
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ -ms-border-radius: 3px;
+ border-radius: 3px;
+ cursor: pointer;
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsPanel/djcpsPanel.html b/static/components/modules/djcpsPanel/djcpsPanel.html
new file mode 100644
index 0000000..823c129
--- /dev/null
+++ b/static/components/modules/djcpsPanel/djcpsPanel.html
@@ -0,0 +1,11 @@
+
+
diff --git a/static/components/modules/djcpsPanel/djcpsPanel.js b/static/components/modules/djcpsPanel/djcpsPanel.js
new file mode 100644
index 0000000..9d8813b
--- /dev/null
+++ b/static/components/modules/djcpsPanel/djcpsPanel.js
@@ -0,0 +1,113 @@
+/**
+ * 面板组件
+ */
+layui.define(['element', 'laytpl'], function (exports) {
+ "use strict";
+ var laypanel = layui.element;
+ var laytpl = layui.laytpl;
+ var djcpsPanel = {
+ // 初始配置
+ config: {
+ // 需要点击展开或折叠的按钮的id
+ elem: '#laypanel',
+ //非layui原生配置,外部容器元素,传入jquery的dom对象
+ container: $('#panel'),
+ // 按钮默认命名
+ buttonName: '批量展开',
+ // 点击按钮后的命名
+ buttonAfterName: '批量折叠',
+ // 是否开启手风琴
+ layAccordion: false,
+ //数据
+ data: [
+ {
+ 'title': '',//被点击的参数
+ 'content': ''//被隐藏的部分
+ }
+ ]
+ }
+ };
+ /**
+ * 核心功能构造函数
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsPanel.config, options);
+ that.loadHtml().then(function () {
+ return that.renderHtml();
+ }).then(function () {
+ that.initPanel();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#panelCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsPanel/djcpsPanel.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 渲染模板文件
+ */
+ mainFn.prototype.renderHtml = function () {
+ var that = this;
+ var defer = $.Deferred();
+ var data = {
+ layAccordion: that.config.layAccordion,
+ data: that.config.data
+ };
+ var tpl = $('#panelTpl').html();
+ laytpl(tpl).render(data, function (html) {
+ that.config.container.html(html);
+ defer.resolve();
+ });
+ return defer.promise();
+ };
+ /**
+ * 初始化功能
+ */
+ mainFn.prototype.initPanel = function () {
+ var that = this;
+ var elem = that.config.elem;
+ var buttonName = that.config.buttonName;
+ var buttonAfterName = that.config.buttonAfterName;
+ laypanel.init(that.config);
+ $(elem).click(function () {
+ $(elem).html() == buttonName ? $(elem).html(buttonAfterName) : $(elem).html(buttonName);
+ $(elem).html() == buttonName ? $('.layui-icon').html('') : $('.layui-icon').html('');
+ $(elem).html() == buttonName ? $('.layui-colla-content').removeClass('layui-show') : $('.layui-colla-content').addClass('layui-show');
+ });
+ $('.layui-colla-title').click(function () {
+ var len = $('.layui-colla-content').length;
+ var lens = $(".layui-show").length;
+ if (len == lens) {
+ $(elem).html(buttonAfterName)
+ } else if (lens == 0) {
+ $(elem).html(buttonName)
+ }
+ });
+ };
+ /**
+ * 组件入口
+ */
+ djcpsPanel.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ /**
+ * 输出组件
+ */
+ exports('djcpsPanel', djcpsPanel);
+});
diff --git a/static/components/modules/djcpsProgress/djcpsProgress.css b/static/components/modules/djcpsProgress/djcpsProgress.css
new file mode 100644
index 0000000..e69de29
diff --git a/static/components/modules/djcpsProgress/djcpsProgress.html b/static/components/modules/djcpsProgress/djcpsProgress.html
new file mode 100644
index 0000000..636c2ea
--- /dev/null
+++ b/static/components/modules/djcpsProgress/djcpsProgress.html
@@ -0,0 +1,10 @@
+
+
diff --git a/static/components/modules/djcpsProgress/djcpsProgress.js b/static/components/modules/djcpsProgress/djcpsProgress.js
new file mode 100644
index 0000000..ae0f6a7
--- /dev/null
+++ b/static/components/modules/djcpsProgress/djcpsProgress.js
@@ -0,0 +1,93 @@
+/**
+ * 进度条progress组件
+ * layui-element-progress二次封装
+ */
+layui.define(['element', 'laytpl'], function (exports) {
+ "use strict";
+ var element = layui.element;
+ var laytpl = layui.laytpl;
+ // 定义组件
+ var djcpsProgress = {
+ // 初始配置
+ config: {
+ //非layui原生配置,外部容器元素,传入jquery的dom对象
+ container: $('#progress'),
+ //非layui原生配置,用于组件区分标识(过滤器)
+ filter: 'progress',
+ //非layui原生配置,是否显示进度条的值
+ showPercent: false,
+ //非layui原生配置,进度条的值,可以传10%、1/3、50(表示像素)等值
+ percent: '0%',
+ //非layui原生配置,是否显示大号进度条
+ bigProgress: false
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} options 配置项
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsProgress.config, options);
+ that.loadHtml().then(function () {
+ return that.renderHtml();
+ }).then(function () {
+ that.setProgress();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#progressCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsProgress/djcpsProgress.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 渲染模板文件
+ */
+ mainFn.prototype.renderHtml = function () {
+ var that = this;
+ var defer = $.Deferred();
+ //整合模板数据
+ var data = {
+ filter: that.config.filter,
+ showPercent: that.config.showPercent,
+ percent: that.config.percent,
+ bigProgress: that.config.bigProgress
+ };
+ var tpl = $('#progressTpl').html();
+ laytpl(tpl).render(data, function (html) {
+ that.config.container.html(html);
+ defer.resolve();
+ });
+ return defer.promise();
+ };
+ /**
+ * 设置进度条长度
+ */
+ mainFn.prototype.setProgress = function (filter, percent) {
+ var that = this;
+ setTimeout(function () {
+ element.progress(filter || that.config.filter, percent || that.config.percent);
+ }, 50);
+ };
+ //组件入口
+ djcpsProgress.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsProgress', djcpsProgress);
+});
diff --git a/static/components/modules/djcpsTable/data.json b/static/components/modules/djcpsTable/data.json
new file mode 100644
index 0000000..17d0f0e
--- /dev/null
+++ b/static/components/modules/djcpsTable/data.json
@@ -0,0 +1,104 @@
+{
+ "code": 0,
+ "msg": "",
+ "count": 3000000,
+ "data": [
+ {
+ "id": "10001",
+ "username": "杜甫",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "点击此处,显示更多。当内容超出时,点击单元格会自动显示更多内容。",
+ "experience": "116",
+ "ip": "192.168.0.8",
+ "logins": "108",
+ "joinTime": "2016-10-14"
+ },
+ {
+ "id": "10002",
+ "username": "李白",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "君不见,黄河之水天上来,奔流到海不复回。 君不见,高堂明镜悲白发,朝如青丝暮成雪。 人生得意须尽欢,莫使金樽空对月。 天生我材必有用,千金散尽还复来。 烹羊宰牛且为乐,会须一饮三百杯。 岑夫子,丹丘生,将进酒,杯莫停。 与君歌一曲,请君为我倾耳听。(倾耳听 一作:侧耳听) 钟鼓馔玉不足贵,但愿长醉不复醒。(不足贵 一作:何足贵;不复醒 一作:不愿醒/不用醒) 古来圣贤皆寂寞,惟有饮者留其名。(古来 一作:自古;惟 通:唯) 陈王昔时宴平乐,斗酒十千恣欢谑。 主人何为言少钱,径须沽取对君酌。 五花马,千金裘,呼儿将出换美酒,与尔同销万古愁。",
+ "experience": "12",
+ "ip": "192.168.0.8",
+ "logins": "106",
+ "joinTime": "2016-10-14",
+ "LAY_CHECKED": true
+ },
+ {
+ "id": "10003",
+ "username": "王勃",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "人生恰似一场修行",
+ "experience": "65",
+ "ip": "192.168.0.8",
+ "logins": "106",
+ "joinTime": "2016-10-14"
+ },
+ {
+ "id": "10004",
+ "username": "李清照",
+ "email": "xianxin@layui.com",
+ "sex": "女",
+ "city": "浙江杭州",
+ "sign": "人生恰似一场修行",
+ "experience": "666",
+ "ip": "192.168.0.8",
+ "logins": "106",
+ "joinTime": "2016-10-14"
+ },
+ {
+ "id": "10005",
+ "username": "冰心",
+ "email": "xianxin@layui.com",
+ "sex": "女",
+ "city": "浙江杭州",
+ "sign": "人生恰似一场修行",
+ "experience": "86",
+ "ip": "192.168.0.8",
+ "logins": "106",
+ "joinTime": "2016-10-14"
+ },
+ {
+ "id": "10006",
+ "username": "贤心",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "人生恰似一场修行",
+ "experience": "12",
+ "ip": "192.168.0.8",
+ "logins": "106",
+ "joinTime": "2016-10-14"
+ },
+ {
+ "id": "10007",
+ "username": "贤心",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "人生恰似一场修行",
+ "experience": "16",
+ "ip": "192.168.0.8",
+ "logins": "106",
+ "joinTime": "2016-10-14"
+ },
+ {
+ "id": "10008",
+ "username": "贤心",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "人生恰似一场修行",
+ "experience": "106",
+ "ip": "192.168.0.8",
+ "logins": "106",
+ "joinTime": "2016-10-14"
+ }
+ ]
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsTable/djcpsTable.css b/static/components/modules/djcpsTable/djcpsTable.css
new file mode 100644
index 0000000..475ae8e
--- /dev/null
+++ b/static/components/modules/djcpsTable/djcpsTable.css
@@ -0,0 +1,3 @@
+.toolbarDemo .layui-btn {
+ background: #1886E3;
+}
\ No newline at end of file
diff --git a/static/components/modules/djcpsTable/djcpsTable.html b/static/components/modules/djcpsTable/djcpsTable.html
new file mode 100644
index 0000000..0e1e277
--- /dev/null
+++ b/static/components/modules/djcpsTable/djcpsTable.html
@@ -0,0 +1,8 @@
+
+
diff --git a/static/components/modules/djcpsTable/djcpsTable.js b/static/components/modules/djcpsTable/djcpsTable.js
new file mode 100644
index 0000000..b83629f
--- /dev/null
+++ b/static/components/modules/djcpsTable/djcpsTable.js
@@ -0,0 +1,175 @@
+layui.define('table', function (exports) {
+ "use strict";
+ var table = layui.table;
+ var data = {
+ "code": 0,
+ "msg": "",
+ "count": 3000000,
+ "data": [{
+ "id": "10001",
+ "username": "杜甫",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "点击此处,显示更多。当内容超出时,点击单元格会自动显示更多内容。",
+ "experience": "116",
+ "ip": "192.168.0.8",
+ "logins": "108",
+ "joinTime": "2016-10-14"
+ }, {
+ "id": "10002",
+ "username": "李白",
+ "email": "xianxin@layui.com",
+ "sex": "男",
+ "city": "浙江杭州",
+ "sign": "君不见,黄河之水天上来,奔流到海不复回。 君不见,高堂明镜悲白发,朝如青丝暮成雪。 人生得意须尽欢,莫使金樽空对月。 天生我材必有用,千金散尽还复来。 烹羊宰牛且为乐,会须一饮三百杯。 岑夫子,丹丘生,将进酒,杯莫停。 与君歌一曲,请君为我倾耳听。(倾耳听 一作:侧耳听) 钟鼓馔玉不足贵,但愿长醉不复醒。(不足贵 一作:何足贵;不复醒 一作:不愿醒/不用醒) 古来圣贤皆寂寞,惟有饮者留其名。(古来 一作:自古;惟 通:唯) 陈王昔时宴平乐,斗酒十千恣欢谑。 主人何为言少钱,径须沽取对君酌。 五花马,千金裘,呼儿将出换美酒,与尔同销万古愁。",
+ "experience": "12",
+ "ip": "192.168.0.8", "logins": "106"
+ , "joinTime": "2016-10-14"
+ , "LAY_CHECKED": true
+ }, {
+ "id": "10003"
+ , "username": "王勃"
+ , "email": "xianxin@layui.com"
+ , "sex": "男"
+ , "city": "浙江杭州"
+ , "sign": "人生恰似一场修行"
+ , "experience": "65"
+ , "ip": "192.168.0.8"
+ , "logins": "106"
+ , "joinTime": "2016-10-14"
+ }, {
+ "id": "10004"
+ , "username": "李清照"
+ , "email": "xianxin@layui.com"
+ , "sex": "女"
+ , "city": "浙江杭州"
+ , "sign": "人生恰似一场修行"
+ , "experience": "666"
+ , "ip": "192.168.0.8"
+ , "logins": "106"
+ , "joinTime": "2016-10-14"
+ }, {
+ "id": "10005"
+ , "username": "冰心"
+ , "email": "xianxin@layui.com"
+ , "sex": "女"
+ , "city": "浙江杭州"
+ , "sign": "人生恰似一场修行"
+ , "experience": "86"
+ , "ip": "192.168.0.8"
+ , "logins": "106"
+ , "joinTime": "2016-10-14"
+ }, {
+ "id": "10006"
+ , "username": "贤心"
+ , "email": "xianxin@layui.com"
+ , "sex": "男"
+ , "city": "浙江杭州"
+ , "sign": "人生恰似一场修行"
+ , "experience": "12"
+ , "ip": "192.168.0.8"
+ , "logins": "106"
+ , "joinTime": "2016-10-14"
+ }, {
+ "id": "10007"
+ , "username": "贤心"
+ , "email": "xianxin@layui.com"
+ , "sex": "男"
+ , "city": "浙江杭州"
+ , "sign": "人生恰似一场修行"
+ , "experience": "16"
+ , "ip": "192.168.0.8"
+ , "logins": "106"
+ , "joinTime": "2016-10-14"
+ }, {
+ "id": "10008"
+ , "username": "贤心"
+ , "email": "xianxin@layui.com"
+ , "sex": "男"
+ , "city": "浙江杭州"
+ , "sign": "人生恰似一场修行"
+ , "experience": "106"
+ , "ip": "192.168.0.8"
+ , "logins": "106"
+ , "joinTime": "2016-10-14"
+ }]
+ }
+ var djcpsTable = {
+
+ };
+ var mainFn = function (options) {
+ var that = this;
+ that.loadHtml().then(function () {
+ that.initTable();
+ });
+ };
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#tableCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsTable/djcpsTable.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ mainFn.prototype.initTable = function () {
+ table.render({
+ elem: '#table',
+ data: data.data,
+ toolbar: '#toolbarDemo',
+ title: '用户数据表',
+ totalRow: true,
+ cols: [[
+ { type: 'checkbox', fixed: 'left' },
+ { field: 'id', title: 'ID', width: 80, fixed: 'left', unresize: true, sort: true, totalRowText: '合计' },
+ { field: 'username', title: '用户名', width: 120, edit: 'text' },
+ {
+ field: 'email', title: '邮箱', width: 150, edit: 'text', templet: function (res) {
+ return '' + res.email + ''
+ }
+ },
+ { field: 'experience', title: '积分', width: 80, sort: true, totalRow: true },
+ { field: 'sex', title: '性别', width: 80, edit: 'text', sort: true },
+ { field: 'logins', title: '登入次数', width: 100, sort: true, totalRow: true },
+ { field: 'sign', title: '签名' },
+ { field: 'city', title: '城市', width: 100 },
+ { field: 'ip', title: 'IP', width: 120 },
+ { field: 'joinTime', title: '加入时间', width: 120 },
+ { fixed: 'right', title: '操作', toolbar: '#barDemo', width: 150 }
+ ]]
+ , page: true
+ });
+ //工具栏事件
+ table.on('toolbar(test)', function (obj) {
+ var checkStatus = table.checkStatus(obj.config.id);
+ switch (obj.event) {
+ case 'getCheckData':
+ var data = checkStatus.data;
+ layer.alert(JSON.stringify(data));
+ break;
+ case 'getCheckLength':
+ var data = checkStatus.data;
+ layer.msg('选中了:' + data.length + ' 个');
+ break;
+ case 'isAll':
+ layer.msg(checkStatus.isAll ? '全选' : '未全选')
+ break;
+ };
+ });
+ }
+ //组件入口
+ djcpsTable.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsTable', djcpsTable);
+});
diff --git a/static/components/modules/djcpsTips/djcpsTips.css b/static/components/modules/djcpsTips/djcpsTips.css
new file mode 100644
index 0000000..e69de29
diff --git a/static/components/modules/djcpsTips/djcpsTips.html b/static/components/modules/djcpsTips/djcpsTips.html
new file mode 100644
index 0000000..9756bf0
--- /dev/null
+++ b/static/components/modules/djcpsTips/djcpsTips.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsTips/djcpsTips.js b/static/components/modules/djcpsTips/djcpsTips.js
new file mode 100644
index 0000000..5543a7e
--- /dev/null
+++ b/static/components/modules/djcpsTips/djcpsTips.js
@@ -0,0 +1,87 @@
+/**
+ * 信息框tips组件
+ * layui-layer-tips二次封装
+ */
+layui.define('layer', function (exports) {
+ "use strict";
+ var layer = layui.layer;
+ // 定义组件
+ var djcpsTips = {
+ // 初始配置
+ config: {
+ //宽高,auto自适应,500px为宽度500高度仍自适应
+ area: "auto",
+ //坐标,auto垂直水平居中,100px为top坐标100水平仍居中,['100px', '50px']为top、left坐标
+ //快捷设置,t顶部居中,r右边缘居中,b底部居中,l左边缘居中,lt左上角,lb左下角,rt右上角,rb右下角
+ offset: 'auto',
+ //关闭按钮,样式1或2,0为无关闭按钮
+ closeBtn: 0,
+ //遮罩,消息框外区域#000背景透明度,0为不遮罩,[0.8, '#393D49']可自定义遮罩颜色
+ shade: 0,
+ //是否通过点击遮罩来关闭消息框
+ shadeClose: false,
+ //自动关闭所需毫秒
+ time: 3000,
+ //是否固定在可视区域(鼠标滚动时)
+ fixed: true,
+ //是否允许浏览器出现滚动条
+ scrollbar: true,
+ //层叠顺序,一般用于解决和其他组件的层叠冲突
+ zIndex: 19891014,
+ //触发拖拽的元素,传元素选择器'.layui-layer-title',传false禁止拖拽
+ move: false,
+ //tips的方向和颜色,上1右2下3左4,也可以使用[1, '#c00']来定义颜色
+ tips: 2,
+ //是否允许多个tips
+ tipsMore: false
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} content 内容
+ * @param {*} follow 跟随元素,传入jquery的dom对象
+ * @param {*} options 配置项
+ */
+ var mainFn = function (content, follow, options) {
+ var that = this;
+ that.content = content === undefined ? '' : content;
+ that.follow = follow;
+ that.config = $.extend({}, djcpsTips.config, options);
+ that.loadHtml().then(function () {
+ that.initTips();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#tipsCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsTips/djcpsTips.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化消息框功能
+ */
+ mainFn.prototype.initTips = function () {
+ var that = this;
+ layer.tips(that.content, that.follow, that.config);
+ };
+ //组件入口
+ djcpsTips.init = function (content, follow, options) {
+ var inst = new mainFn(content, follow, options);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsTips', djcpsTips);
+});
diff --git a/static/components/modules/djcpsTree/djcpsTree.css b/static/components/modules/djcpsTree/djcpsTree.css
new file mode 100644
index 0000000..8e571be
--- /dev/null
+++ b/static/components/modules/djcpsTree/djcpsTree.css
@@ -0,0 +1,13 @@
+/* tree树形菜单样式,concise简洁的背景主题 */
+
+.layui-tree-skin-concise .layui-tree-branch {
+ color: #1886E3;
+}
+
+.layui-tree-skin-concise li .layui-tree-spread, .layui-tree-skin-concise li a:hover {
+ color: #1886E3;
+}
+
+.layui-tree-skin-concise li a i {
+ font-size: 0;
+}
diff --git a/static/components/modules/djcpsTree/djcpsTree.html b/static/components/modules/djcpsTree/djcpsTree.html
new file mode 100644
index 0000000..31b08e6
--- /dev/null
+++ b/static/components/modules/djcpsTree/djcpsTree.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsTree/djcpsTree.js b/static/components/modules/djcpsTree/djcpsTree.js
new file mode 100644
index 0000000..505c783
--- /dev/null
+++ b/static/components/modules/djcpsTree/djcpsTree.js
@@ -0,0 +1,78 @@
+// tree树形菜单组件,layui-tree二次封装
+layui.define('tree', function (exports) {
+ 'use strict';
+ // 引用layui自带的树形菜单
+ var tree = layui.tree;
+
+ // 图标需要在tree.js改源码文件
+ var icon = {
+ // 箭头
+ arrow: ['', ''],
+ // 复选框
+ checkbox: ['', ''],
+ // 单选框
+ radio: ['', ''],
+ // 父节点
+ branch: ['', ''],
+ // 叶节点
+ leaf: ''
+ };
+
+ // 定义组件
+ var djcpsTree = {
+ // 默认配置
+ config: {
+ // 指定元素的选择器,默认tree
+ elem: $('#tree'),
+ // 节点数据
+ nodes: [],
+ // 风格定义,默认为concise简洁风格
+ skin: 'concise',
+ // 点击节点的回调
+ click: function (node) {
+ },
+ // 节点链接(可选),未设则不会跳转
+ href: null,
+ // 节点打开方式(即a的target值),必须href设定后才有效
+ target: null,
+ }
+ };
+
+ // 核心功能构造函数,options为配置参数
+ var mainFn = function (options) {
+ var that = this;
+ // 合并默认配置,生成新的配置
+ that.config = $.extend({}, djcpsTree.config, options);
+ that.loadHtml().then(function () {
+ that.initTree();
+ });
+ };
+ // 加载模板文件
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#treeCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsTree/djcpsTree.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ // 初始化树形菜单
+ mainFn.prototype.initTree = function () {
+ var that = this;
+ tree(that.config);
+ };
+ // 组件入口
+ djcpsTree.init = function (options) {
+ return new mainFn(options);
+ };
+ // 输出组件
+ exports('djcpsTree', djcpsTree);
+});
diff --git a/static/components/modules/djcpsUpload/djcpsUpload.css b/static/components/modules/djcpsUpload/djcpsUpload.css
new file mode 100644
index 0000000..e69de29
diff --git a/static/components/modules/djcpsUpload/djcpsUpload.html b/static/components/modules/djcpsUpload/djcpsUpload.html
new file mode 100644
index 0000000..6356125
--- /dev/null
+++ b/static/components/modules/djcpsUpload/djcpsUpload.html
@@ -0,0 +1 @@
+
diff --git a/static/components/modules/djcpsUpload/djcpsUpload.js b/static/components/modules/djcpsUpload/djcpsUpload.js
new file mode 100644
index 0000000..1f916b1
--- /dev/null
+++ b/static/components/modules/djcpsUpload/djcpsUpload.js
@@ -0,0 +1,189 @@
+/**
+ * 文件上传upload组件
+ * layui-upload二次封装
+ */
+layui.define('upload', function (exports) {
+ "use strict";
+ var upload = layui.upload;
+ // 定义组件
+ var djcpsUpload = {
+ // 初始配置
+ config: {
+ //指向容器选择器,dom选择器
+ elem: '#upload',
+ //服务端上传接口
+ url: '',
+ //请求上传接口的额外参数
+ data: {},
+ //接口的请求头
+ headers: {},
+ //允许上传的文件类型,file所有文件,images图片,video视频,audio音频
+ accept: 'images',
+ //打开文件选择框时,筛选出的文件类型,值为用逗号隔开的MIME类型列表
+ //如'image/*'(只显示图片文件),'image/jpg, image/png'(只显示 jpg 和 png 文件)
+ acceptMime: 'image/jpg, image/png, image/jpeg',
+ //允许上传的文件后缀
+ exts: 'jpg|png|jpeg',
+ //是否选完文件后自动上传,若false则需设置bindAction来指向其他按钮提交上传
+ auto: false,
+ //作为提交上传按钮,当auto为false时使用,传入jquery的dom对象
+ bindAction: $('#uploadBtn'),
+ //设定文件域的字段名
+ field: 'file',
+ //设置文件最大可允许上传的大小,单位KB,不支持ie8/9,0为不限制
+ size: 0,
+ //是否允许多文件上传,不支持ie8/9
+ multiple: false,
+ //设置同时可上传的文件数量,一般配合multiple参数出现,0为不限制
+ number: 0,
+ //是否接受拖拽的文件上传,不支持ie8/9
+ drag: false,
+ //选择文件后的回调函数,带参数object文件信息
+ choose: function (object) {
+ },
+ //文件提交上传前的回调
+ //带参数object文件信息
+ before: function (object) {
+ },
+ //执行上传请求后的回调
+ //带参数res服务端响应信息、index当前文件的索引、upload重新上传的方法,一般在文件上传失败后使用
+ done: function (res, index, upload) {
+ },
+ //执行上传请求出现异常的回调
+ //带参数index当前文件的索引、upload重新上传的方法
+ error: function (index, upload) {
+ },
+ //多文件上传完毕后的状态回调,只有在multiple:true时才触发
+ //带参数object文件信息,total总文件数,successful上传成功文件数,aborted上传失败文件数
+ allDone: function (obj) {
+ }
+ }
+ };
+ /**
+ * 核心功能构造函数
+ * @param {*} options 配置项
+ */
+ var mainFn = function (options) {
+ var that = this;
+ that.config = $.extend({}, djcpsUpload.config, options);
+ //重写choose事件,先获取文件队列,再执行回调操作
+ that.config.choose = function (object) {
+ // 等待上传的文件队列
+ that.files = object.pushFile();
+ options.choose(object);
+ };
+ that.loadHtml().then(function () {
+ that.initUpload();
+ });
+ };
+ /**
+ * 加载模板文件
+ */
+ mainFn.prototype.loadHtml = function () {
+ var defer = $.Deferred();
+ if ($('#uploadCss').length > 0) {
+ defer.resolve();
+ } else {
+ $.ajax({
+ url: "static/components/modules/djcpsUpload/djcpsUpload.html",
+ async: false,
+ success: function (result) {
+ $('body').append(result);
+ defer.resolve();
+ }
+ });
+ }
+ return defer.promise();
+ };
+ /**
+ * 初始化文件上传功能
+ */
+ mainFn.prototype.initUpload = function () {
+ var that = this;
+ that.upload = upload.render(that.config);
+ };
+ /**
+ * 在choose或before阶段执行,预读待上传的所有本地文件,返回一个promise,带文件数组参数
+ */
+ mainFn.prototype.filePreview = function () {
+ var defer = $.Deferred();
+ var that = this;
+ //文件数组
+ var fileArr = [];
+ //文件数量计数
+ // var filesCount = 0;
+ //已读取文件计数
+ // var onloadCount = 0;
+ if (window.FileReader) {
+ layui.each(that.files, function (index, file) {
+ var url = URL.createObjectURL(file);
+ fileArr.push({
+ index: index,
+ file: file,
+ url: url
+ });
+ setTimeout(function () {
+ URL.revokeObjectURL(url);
+ }, 0);
+ defer.resolve(fileArr);
+ // var reader = new FileReader();
+ // reader.readAsDataURL(file);
+ // filesCount++;
+ // reader.onload = function () {
+ // fileArr.push({
+ // index: index,
+ // file: file,
+ // result: this.result
+ // });
+ // onloadCount++;
+ // if (filesCount === onloadCount) {
+ // defer.resolve(fileArr);
+ // }
+ // };
+ });
+ } else {
+ defer.reject();
+ }
+ return defer.promise();
+ };
+ /**
+ * 在choose或before阶段执行,删除本地文件
+ * @param {*} fileIndex 文件索引
+ * @param {*} $dom 文件所在元素
+ */
+ mainFn.prototype.deleteFile = function (fileIndex, $dom) {
+ var that = this;
+ //删除队列文件
+ delete that.files[fileIndex];
+ //移除页面元素
+ $dom.remove();
+ //清空input file值,以免删除后出现同名文件不可选
+ console.log($(that.upload.config.elem).next()[0]);
+ $(that.upload.config.elem).next()[0].value = '';
+ };
+ mainFn.prototype.deleteAllFile = function () {
+ var that = this;
+ that.files = {};
+ };
+ /**
+ * 在choose或before阶段执行,单个文件上传
+ * @param {*} obj 文件信息
+ * @param {*} file 单个文件信息
+ * @param {*} index 文件索引
+ */
+ mainFn.prototype.reupload = function (obj, file, index) {
+ var that = this;
+ if (obj) {
+ obj.upload(index, file);
+ } else {
+ that.upload.upload();
+ }
+ };
+ //组件入口
+ djcpsUpload.init = function (options) {
+ var inst = new mainFn(options);
+ return inst;
+ };
+ //输出组件
+ exports('djcpsUpload', djcpsUpload);
+});
diff --git a/static/data.json b/static/data.json
new file mode 100644
index 0000000..11b5f05
--- /dev/null
+++ b/static/data.json
@@ -0,0 +1,403 @@
+{
+ "code": 0,
+ "msg": "",
+ "count": 132,
+ "data": [
+ {
+ "text": "11111"
+ },
+ {
+ "text": "22222"
+ },
+ {
+ "text": "33333"
+ },
+ {
+ "text": "44444"
+ },
+ {
+ "text": "55555"
+ },
+ {
+ "text": "666666"
+ },
+ {
+ "text": "77777"
+ },
+ {
+ "text": "88888"
+ },
+ {
+ "text": "99999"
+ },
+ {
+ "text": "00000"
+ },
+ {
+ "text": "100000"
+ },
+ {
+ "text": "200000"
+ },
+ {
+ "text": "300000"
+ },
+ {
+ "text": "400000"
+ },
+ {
+ "text": "500000"
+ },
+ {
+ "text": "600000"
+ },
+ {
+ "text": "700000"
+ },
+ {
+ "text": "800000"
+ },
+ {
+ "text": "900000"
+ },
+ {
+ "text": "000000"
+ },
+ {
+ "text": "1111111"
+ },
+ {
+ "text": "1222222"
+ },
+ {
+ "text": "1333333"
+ },
+ {
+ "text": "1444444"
+ },
+ {
+ "text": "1555555"
+ },
+ {
+ "text": "1666666"
+ },
+ {
+ "text": "1777777"
+ },
+ {
+ "text": "1888888"
+ },
+ {
+ "text": "1999999"
+ },
+ {
+ "text": "1000000"
+ },
+ {
+ "text": "2111111"
+ },
+ {
+ "text": "2222222"
+ },
+ {
+ "text": "2333333"
+ },
+ {
+ "text": "2444444"
+ },
+ {
+ "text": "2555555"
+ },
+ {
+ "text": "2666666"
+ },
+ {
+ "text": "2777777"
+ },
+ {
+ "text": "2888888"
+ },
+ {
+ "text": "2999999"
+ },
+ {
+ "text": "2000000"
+ },
+ {
+ "text": "3111111"
+ },
+ {
+ "text": "3222222"
+ },
+ {
+ "text": "3333333"
+ },
+ {
+ "text": "3444444"
+ },
+ {
+ "text": "3555555"
+ },
+ {
+ "text": "3666666"
+ },
+ {
+ "text": "3777777"
+ },
+ {
+ "text": "3888888"
+ },
+ {
+ "text": "3999999"
+ },
+ {
+ "text": "3000000"
+ },
+ {
+ "text": "4111111"
+ },
+ {
+ "text": "4222222"
+ },
+ {
+ "text": "4333333"
+ },
+ {
+ "text": "4444444"
+ },
+ {
+ "text": "4555555"
+ },
+ {
+ "text": "4666666"
+ },
+ {
+ "text": "4777777"
+ },
+ {
+ "text": "4888888"
+ },
+ {
+ "text": "4999999"
+ },
+ {
+ "text": "4000000"
+ },
+ {
+ "text": "5111111"
+ },
+ {
+ "text": "5222222"
+ },
+ {
+ "text": "5333333"
+ },
+ {
+ "text": "5444444"
+ },
+ {
+ "text": "5555555"
+ },
+ {
+ "text": "5666666"
+ },
+ {
+ "text": "5777777"
+ },
+ {
+ "text": "5888888"
+ },
+ {
+ "text": "5888888"
+ },
+ {
+ "text": "5888888"
+ },
+ {
+ "text": "6000000"
+ },
+ {
+ "text": "6000001"
+ },
+ {
+ "text": "6000002"
+ },
+ {
+ "text": "6000003"
+ },
+ {
+ "text": "6000004"
+ },
+ {
+ "text": "6000005"
+ },
+ {
+ "text": "6000006"
+ },
+ {
+ "text": "6000007"
+ },
+ {
+ "text": "6000008"
+ },
+ {
+ "text": "6000009"
+ },
+ {
+ "text": "6000010"
+ },
+ {
+ "text": "6000011"
+ },
+ {
+ "text": "6000012"
+ },
+ {
+ "text": "6000013"
+ },
+ {
+ "text": "6000014"
+ },
+ {
+ "text": "6000015"
+ },
+ {
+ "text": "6000016"
+ },
+ {
+ "text": "6000017"
+ },
+ {
+ "text": "6000018"
+ },
+ {
+ "text": "6000019"
+ },
+ {
+ "text": "6000020"
+ },
+ {
+ "text": "6000021"
+ },
+ {
+ "text": "6000022"
+ },
+ {
+ "text": "6000023"
+ },
+ {
+ "text": "6000024"
+ },
+ {
+ "text": "6000025"
+ },
+ {
+ "text": "6000026"
+ },
+ {
+ "text": "6000027"
+ },
+ {
+ "text": "6000028"
+ },
+ {
+ "text": "6000029"
+ },
+ {
+ "text": "6000030"
+ },
+ {
+ "text": "6000031"
+ },
+ {
+ "text": "6000032"
+ },
+ {
+ "text": "6000033"
+ },
+ {
+ "text": "6000034"
+ },
+ {
+ "text": "6000035"
+ },
+ {
+ "text": "6000036"
+ },
+ {
+ "text": "6000037"
+ },
+ {
+ "text": "6000038"
+ },
+ {
+ "text": "6000039"
+ },
+ {
+ "text": "6000040"
+ },
+ {
+ "text": "6000041"
+ },
+ {
+ "text": "6000042"
+ },
+ {
+ "text": "6000043"
+ },
+ {
+ "text": "6000044"
+ },
+ {
+ "text": "6000045"
+ },
+ {
+ "text": "6000046"
+ },
+ {
+ "text": "6000047"
+ },
+ {
+ "text": "6000048"
+ },
+ {
+ "text": "6000049"
+ },
+ {
+ "text": "6000050"
+ },
+ {
+ "text": "6000051"
+ },
+ {
+ "text": "6000052"
+ },
+ {
+ "text": "6000053"
+ },
+ {
+ "text": "6000054"
+ },
+ {
+ "text": "6000055"
+ },
+ {
+ "text": "6000056"
+ },
+ {
+ "text": "6000057"
+ },
+ {
+ "text": "6000058"
+ },
+ {
+ "text": "6000059"
+ },
+ {
+ "text": "6000060"
+ },
+ {
+ "text": "6000061"
+ }
+ ]
+}
\ No newline at end of file
diff --git a/static/images/1.jpg b/static/images/1.jpg
new file mode 100644
index 0000000..9d83123
Binary files /dev/null and b/static/images/1.jpg differ
diff --git a/static/images/2.jpg b/static/images/2.jpg
new file mode 100644
index 0000000..6277678
Binary files /dev/null and b/static/images/2.jpg differ
diff --git a/static/images/3.jpg b/static/images/3.jpg
new file mode 100644
index 0000000..86dc4ea
Binary files /dev/null and b/static/images/3.jpg differ
diff --git a/static/images/4.jpg b/static/images/4.jpg
new file mode 100644
index 0000000..13710a0
Binary files /dev/null and b/static/images/4.jpg differ
diff --git a/static/images/5.jpg b/static/images/5.jpg
new file mode 100644
index 0000000..90575a7
Binary files /dev/null and b/static/images/5.jpg differ
diff --git a/static/images/6.jpg b/static/images/6.jpg
new file mode 100644
index 0000000..988cce0
Binary files /dev/null and b/static/images/6.jpg differ
diff --git a/static/images/bee.png b/static/images/bee.png
new file mode 100644
index 0000000..9c5c2bf
Binary files /dev/null and b/static/images/bee.png differ
diff --git a/static/images/error.png b/static/images/error.png
new file mode 100644
index 0000000..252cf54
Binary files /dev/null and b/static/images/error.png differ
diff --git a/static/js/PIE_IE678.js b/static/js/PIE_IE678.js
new file mode 100644
index 0000000..e12d37d
--- /dev/null
+++ b/static/js/PIE_IE678.js
@@ -0,0 +1,72 @@
+(function(O,H){var h=O.PIE||(O.PIE={});h.Fa=function(a){var b,d,e,c,g=arguments;b=1;for(d=g.length;b",d[0];);h.U=a;if(a===6)h.z=h.z.replace(/^-/,"");h.qa=H.documentMode||h.U;b.innerHTML='';a=b.firstChild;a.style.behavior="url(#default#VML)";h.tc=typeof a.adj==="object"})();(function(){var a=0,b={};h.Q={pa:function(d){return d&&d._pieId||(d._pieId="_"+a++)},Ac:function(d,e,c){var g=b[d],i,j;if(g)Object.prototype.toString.call(g)==="[object Array]"?g.push([e,c]):e.call(c,g);else{j=b[d]=[[e,c]];
+i=new Image;i.onload=function(){g=b[d]={f:i.width,e:i.height};for(var f=0,k=j.length;f=180?0:b,a<90||a>270?0:d);e=c[0];c=c[1];b=b-e;d=d-c;return{la:a,
+qd:e,rd:c,ae:b,be:d,Jd:h.nb.ld(b,d,e,c)}},Od:function(a,b,d,e,c){if(d===0||d===180)return[a,c];else if(d===90||d===270)return[e,b];else{d=Math.tan((d-90)*Math.PI/180);a=d*a-b;b=-1/d;e=b*e-c;c=b-d;return[(e-a)/c,(d*e-b*a)/c]}},ld:function(a,b,d,e){a=d-a;b=e-b;return Math.abs(a===0?b:b===0?a:Math.sqrt(a*a+b*b))}};h.ja=function(){this.Eb=[];this.hc={}};h.ja.prototype={ca:function(a){var b=h.Q.pa(a),d=this.hc,e=this.Eb;if(!(b in d)){d[b]=e.length;e.push(a)}},Ka:function(a){a=h.Q.pa(a);var b=this.hc;if(a&&
+a in b){delete this.Eb[b[a]];delete b[a]}},Da:function(){for(var a=this.Eb,b=a.length;b--;)a[b]&&a[b]()}};h.Pa=new h.ja;h.Pa.Ud=function(){var a=this,b;if(!a.Vd){b=H.documentElement.currentStyle.getAttribute(h.z+"poll-interval")||250;(function d(){a.Da();setTimeout(d,b)})();a.Vd=1}};(function(){function a(){h.J.Da();O.detachEvent("onunload",a);O.PIE=null}h.J=new h.ja;O.attachEvent("onunload",a);h.J.za=function(b,d,e){b.attachEvent(d,e);this.ca(function(){b.detachEvent(d,e)})}})();h.Sa=new h.ja;h.J.za(O,
+"onresize",function(){h.Sa.Da()});(function(){function a(){h.pb.Da()}h.pb=new h.ja;h.J.za(O,"onscroll",a);h.Sa.ca(a)})();(function(){function a(){d=h.mb.kd()}function b(){if(d){for(var e=0,c=d.length;e0)return parseFloat(k);else if(f.tagName in h.Tb){m=this;l=f.parentNode;return h.m(k).a(l,function(){return m.yb(l)})}else{f.appendChild(b);k=b.offsetWidth;b.parentNode===f&&f.removeChild(b);return k}}};a.gb=function(f){return f/c.pt};h.m=function(f){return j[f]||(j[f]=new a(f))};return a}();h.kb=function(){function a(c){this.ga=c}var b=h.m("50%"),
+d={top:1,center:1,bottom:1},e={left:1,center:1,right:1};a.prototype={Bd:function(){if(!this.Rb){var c=this.ga,g=c.length,i=h.q,j=i.ya,f=h.m("0");j=j.W;f=["left",f,"top",f];if(g===1){c.push(new i.rb(j,"center"));g++}if(g===2){j&(c[0].h|c[1].h)&&c[0].c in d&&c[1].c in e&&c.push(c.shift());if(c[0].h&j)if(c[0].c==="center")f[1]=b;else f[0]=c[0].c;else if(c[0].G())f[1]=h.m(c[0].c);if(c[1].h&j)if(c[1].c==="center")f[3]=b;else f[2]=c[1].c;else if(c[1].G())f[3]=h.m(c[1].c)}this.Rb=f}return this.Rb},coords:function(c,
+g,i){var j=this.Bd(),f=j[1].a(c,g);c=j[3].a(c,i);return{x:j[0]==="right"?g-f:f,y:j[2]==="bottom"?i-c:c}}};return a}();h.Ma=function(){function a(b,d){this.f=b;this.e=d}a.prototype={a:function(b,d,e,c,g){var i=this.f,j=this.e,f=d/e;c=c/g;if(i==="contain"){i=c>f?d:e*c;j=c>f?d/c:e}else if(i==="cover"){i=c1)l-=1;return 255*(6*l<1?f+(k-f)*l*6:2*l<1?k:3*l<2?f+(k-f)*(2/3-l)*6:f)}function b(f){this.ha=f}var d={};b.Td=/\s*rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(,\s*(\d+|\d*\.\d+))?\s*\)\s*/;
+b.Fd=/\s*hsla?\(\s*(\d*\.?\d+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*(,\s*(\d+|\d*\.\d+))?\s*\)\s*/;b.db={};for(var e="black|0|navy|3k|darkblue|b|mediumblue|1u|blue|1e|darkgreen|jk1|green|5j4|teal|3k|darkcyan|26j|deepskyblue|ad0|darkturquoise|2xe|mediumspringgreen|8nd|lime|va|springgreen|3j|aqua|3k|cyan|0|midnightblue|xunl|dodgerblue|7ogf|lightseagreen|2zsb|forestgreen|2lbs|seagreen|guut|darkslategray|12pk|limegreen|4wkj|mediumseagreen|dwlb|turquoise|5v8f|royalblue|r2p|steelblue|75qr|darkslateblue|2fh3|mediumturquoise|ta9|indigo|32d2|darkolivegreen|emr1|cadetblue|ebu9|cornflowerblue|6z4d|mediumaquamarine|3459|dimgray|3nwf|slateblue|1bok|olivedrab|1opi|slategray|6y5p|lightslategray|9vk9|mediumslateblue|5g0l|lawngreen|27ma|chartreuse|48ao|aquamarine|5w|maroon|18|purple|3k|olive|p6o|gray|3k|lightslateblue|5j7j|skyblue|4q98|lightskyblue|f|blueviolet|3bhk|darkred|15we|darkmagenta|3v|saddlebrown|djc|darkseagreen|69vg|lightgreen|1og1|mediumpurple|3ivc|darkviolet|sfv|palegreen|6zt1|darkorchid|awk|yellowgreen|292e|sienna|7r3v|brown|6sxp|darkgray|6bgf|lightblue|5vlp|greenyellow|7k9|paleturquoise|2pxb|lightsteelblue|169c|powderblue|5jc|firebrick|1rgc|darkgoldenrod|8z55|mediumorchid|2jm0|rosybrown|34jg|darkkhaki|1mfw|silver|49jp|mediumvioletred|8w5h|indianred|8tef|peru|82r|violetred|3ntd|feldspar|212d|chocolate|16eh|tan|ewe|lightgrey|1kqv|palevioletred|6h8g|metle|fnp|orchid|2dj2|goldenrod|abu|crimson|20ik|gainsboro|13mo|plum|12pt|burlywood|1j8q|lightcyan|3794|lavender|8agr|darksalmon|3rsw|violet|6wz8|palegoldenrod|k3g|lightcoral|28k6|khaki|k5o|aliceblue|3n7|honeydew|1dd|azure|f|sandybrown|5469|wheat|1q37|beige|4kp|whitesmoke|p|mintcream|1z9|ghostwhite|46bp|salmon|25bn|antiquewhite|l7p|linen|zz|lightgoldenrodyellow|1yk|oldlace|46qc|red|1gka|magenta|73|fuchsia|0|deeppink|3v8|orangered|9kd|tomato|5zb|hotpink|19p|coral|49o|darkorange|2i8|lightsalmon|41m|orange|w6|lightpink|3i9|pink|1ze|gold|4dx|peachpuff|qh|navajowhite|s4|moccasin|16w|bisque|f|mistyrose|t|blanchedalmond|1d8|papayawhip|so|lavenderblush|80|seashell|zd|cornsilk|ku|lemonchiffon|dt|floralwhite|z|snow|a|yellow|sm|lightyellow|68|ivory|g|white|f".split("|"),
+c=0,g=e.length,i=0,j;c=this.$a.length)return c();i=this.ch;g=this.$a.substring(this.ch);j=g.charAt(0);switch(j){case "#":if(f=g.match(this.Dd)){this.ch+=f[0].length;return e(b.u,f[0])}break;case '"':case "'":if(f=g.match(this.ce)){this.ch+=f[0].length;return e(b.Nc,
+f[2]||f[3]||"")}break;case "/":case ",":this.ch++;return e(b.xa,j);case "u":if(f=g.match(this.url)){this.ch+=f[0].length;return e(b.URL,f[2]||f[3]||f[4]||"")}}if(f=g.match(this.Nd)){j=f[0];this.ch+=j.length;if(g.charAt(j.length)==="%"){this.ch++;return e(b.Ta,j+"%")}if(f=g.substring(j.length).match(this.gc)){j+=f[0];this.ch+=f[0].length;return e(this.ie[f[0].toLowerCase()]||b.Kc,j)}return e(b.wa,j)}if(f=g.match(this.gc)){j=f[0];this.ch+=j.length;if(j.toLowerCase()in h.Ic.db||j==="currentColor"||j===
+"transparent")return e(b.u,j);if(g.charAt(j.length)==="("){this.ch++;if(j.toLowerCase()in this.cd){g=function(o){return o&&o.h&b.wa};f=function(o){return o&&o.h&(b.wa|b.Ta)};var l=function(o,s){return o&&o.c===s},m=function(){return k.next(1)};if((j.charAt(0)==="r"?f(m()):g(m()))&&l(m(),",")&&f(m())&&l(m(),",")&&f(m())&&(j==="rgb"||j==="hsa"||l(m(),",")&&g(m()))&&l(m(),")"))return e(b.u,this.$a.substring(i,this.ch));return c()}return e(b.Mb,j)}return e(b.W,j)}this.ch++;return e(b.Lb,j)},C:function(){return this.ga[this.Ja-- -
+2]},all:function(){for(;this.next(););return this.ga},va:function(d,e){for(var c=[],g,i;g=this.next();){if(d(g)){i=true;this.C();break}c.push(g)}return e&&!i?null:c}};return a}();h.Kb=function(a){this.d=a};h.Kb.prototype={X:0,oc:function(){var a=this.ub,b;return!a||(b=this.n())&&(a.x!==b.x||a.y!==b.y)},Yd:function(){var a=this.ub,b;return!a||(b=this.n())&&(a.f!==b.f||a.e!==b.e)},cc:function(){var a=this.d,b=a.getBoundingClientRect(),d=h.qa===9,e=h.U===7,c=b.right-b.left;return{x:b.left,y:b.top,f:d||
+e?a.offsetWidth:c,e:d||e?a.offsetHeight:b.bottom-b.top,jc:e&&c?a.offsetWidth/c:1}},n:function(){return this.X?this.Va||(this.Va=this.cc()):this.cc()},Cd:function(){return!!this.ub},cb:function(){++this.X},ib:function(){if(!--this.X){if(this.Va)this.ub=this.Va;this.Va=null}}};(function(){function a(b){var d=h.Q.pa(b);return function(){if(this.X){var e=this.Pb||(this.Pb={});return d in e?e[d]:(e[d]=b.call(this))}else return b.call(this)}}h.p={X:0,ba:function(b){function d(e){this.d=e;this.Ob=this.T()}
+h.Fa(d.prototype,h.p,b);d.Vc={};return d},i:function(){var b=this.T(),d=this.constructor.Vc;return b?b in d?d[b]:(d[b]=this.ea(b)):null},T:a(function(){var b=this.d,d=this.constructor,e=b.style;b=b.currentStyle;var c=this.Aa,g=this.Ia,i=d.Tc||(d.Tc=h.z+c);d=d.Uc||(d.Uc=h.qb+g.charAt(0).toUpperCase()+g.substring(1));return e[d]||b.getAttribute(i)||e[g]||b.getAttribute(c)}),j:a(function(){return!!this.i()}),L:a(function(){var b=this.T(),d=b!==this.Ob;this.Ob=b;return d}),oa:a,cb:function(){++this.X},
+ib:function(){--this.X||delete this.Pb}}})();h.Hb=h.p.ba({Aa:h.z+"background",Ia:h.qb+"Background",Yc:{scroll:1,fixed:1,local:1},hb:{"repeat-x":1,"repeat-y":1,repeat:1,"no-repeat":1},nc:{"padding-box":1,"border-box":1,"content-box":1},Qd:{top:1,right:1,bottom:1,left:1,center:1},Zd:{contain:1,cover:1},fe:{top:1,bottom:1},Kd:{left:1,right:1},fb:{Oa:"backgroundClip",u:"backgroundColor",ia:"backgroundImage",Ra:"backgroundOrigin",P:"backgroundPosition",ka:"backgroundRepeat",Ua:"backgroundSize"},ea:function(a){function b(r){return r&&
+(r.G()&&h.m(r.c)||r.c==="auto"&&"auto")}var d=this.d.currentStyle,e,c,g,i=h.q.ya,j=i.xa,f=i.W,k=i.u,l,m,o=0,s=this.Qd,q,t,n,u,p={R:[]};if(this.xb()){e=new h.q(a);for(g={};c=e.next();){l=c.h;m=c.c;if(!g.V&&l&i.Mb&&m==="linear-gradient"){q={ua:[],V:m};for(t={};c=e.next();){l=c.h;m=c.c;if(l&i.Lb&&m===")"){t.color&&q.ua.push(t);q.ua.length>1&&h.Fa(g,q);break}if(l&k){if(q.la||q.ab){c=e.C();if(c.h!==j)break;e.next()}t={color:h.aa(m)};c=e.next();if(c.G())t.lc=h.m(c.c);else e.C()}else if(l&i.La&&!q.la&&!q.ab&&
+!t.color&&!q.ua.length)q.la=new h.Cc(c.c);else if(l&i.W&&m==="to"&&!q.ab&&!q.la&&!t.color&&!q.ua.length){n=this.fe;u=this.Kd;c=e.va(function(r){return!(r&&r.h&i.W&&(r.c in n||r.c in u))});l=c.length;c=[c[0]&&c[0].c,c[1]&&c[1].c];if(l<1||l>2||l>1&&(c[0]in n&&c[1]in n||c[0]in u&&c[1]in u))break;q.ab=c}else if(l&j&&m===","){if(t.color){q.ua.push(t);t={}}}else break}}else if(!g.V&&l&i.URL){g.Cb=m;g.V="image"}else if((c&&c.G()||c.h&f&&c.c in s)&&!g.ma){e.C();g.ma=new h.kb(e.va(function(r){return!(r&&r.G()||
+r.h&f&&r.c in s)},false))}else if(l&f)if(m in this.hb&&!g.bb)g.bb=m;else if(m in this.nc&&!g.Ya){g.Ya=m;if((c=e.next())&&c.h&f&&c.c in this.nc)g.Xa=c.c;else{g.Xa=m;e.C()}}else if(m in this.Yc&&!g.$c)g.$c=m;else return null;else if(l&k&&!p.color)p.color=h.aa(m);else if(l&j&&m==="/"&&!g.Za&&g.ma){c=e.next();if(c.h&f&&c.c in this.Zd)g.Za=new h.Ma(c.c);else if(q=b(c)){t=b(e.next());if(!t){t=q;e.C()}g.Za=new h.Ma(q,t)}else return null}else if(l&j&&m===","&&g.V){g.mc=a.substring(o,e.ch-1);o=e.ch;p.R.push(g);
+g={}}else return null}if(g.V){g.mc=a.substring(o);p.R.push(g)}p.bd=g.Xa}else this.yc(h.qa<9?function(){var r=this.fb,v=d[r.P+"X"],C=d[r.P+"Y"],y=d[r.ia],B=d[r.u];if(B!=="transparent")p.color=h.aa(B);if(y!=="none")p.R=[{V:"image",Cb:(new h.q(y)).next().c,bb:d[r.ka],ma:new h.kb((new h.q(v+" "+C)).all())}]}:function(){var r=this.fb,v=/\s*,\s*/,C=d[r.ia].split(v),y=d[r.u],B,F,G,K,J,w;if(y!=="transparent")p.color=h.aa(y);if((K=C.length)&&C[0]!=="none"){y=d[r.ka].split(v);B=d[r.P].split(v);F=d[r.Ra].split(v);
+G=d[r.Oa].split(v);r=d[r.Ua].split(v);p.R=[];for(v=0;v8,d=this.fb,e=this.d.runtimeStyle,c=e[d.ia],g=e[d.u],i=e[d.ka],j,f,k,l;if(c)e[d.ia]="";if(g)e[d.u]="";if(i)e[d.ka]="";if(b){j=e[d.Oa];f=e[d.Ra];l=e[d.P];k=
+e[d.Ua];if(j)e[d.Oa]="";if(f)e[d.Ra]="";if(l)e[d.P]="";if(k)e[d.Ua]=""}a=a.call(this);if(c)e[d.ia]=c;if(g)e[d.u]=g;if(i)e[d.ka]=i;if(b){if(j)e[d.Oa]=j;if(f)e[d.Ra]=f;if(l)e[d.P]=l;if(k)e[d.Ua]=k}return a},T:h.p.oa(function(){return this.xb()||this.yc(function(){var a=this.d.currentStyle,b=this.fb;return a[b.u]+" "+a[b.ia]+" "+a[b.ka]+" "+a[b.P+"X"]+" "+a[b.P+"Y"]})}),xb:h.p.oa(function(){var a=this.d;return a.style[this.Ia]||a.currentStyle.getAttribute(this.Aa)}),ud:function(a,b,d,e){var c=this.d,
+g=b.n();b=g.f;g=g.e;if(a!=="border-box")if((d=d.i())&&(d=d.O)){b-=d.l.a(c)+d.l.a(c);g-=d.t.a(c)+d.b.a(c)}if(a==="content-box")if(a=e.i()){b-=a.l.a(c)+a.l.a(c);g-=a.t.a(c)+a.b.a(c)}return{f:b,e:g}},ic:function(){var a=0;if(h.U<7){a=this.d;a=""+(a.style[h.qb+"PngFix"]||a.currentStyle.getAttribute(h.z+"png-fix"))==="true"}return a},j:h.p.oa(function(){return(this.xb()||this.ic())&&!!this.i()})});h.Jb=h.p.ba({sc:["Top","Right","Bottom","Left"],Ld:{thin:"1px",medium:"3px",thick:"5px"},ea:function(){var a=
+{},b={},d={},e=false,c=true,g=true,i=true;this.zc(function(){for(var j=this.d.currentStyle,f=0,k,l,m,o,s,q,t;f<4;f++){m=this.sc[f];t=m.charAt(0).toLowerCase();k=b[t]=j["border"+m+"Style"];l=j["border"+m+"Color"];m=j["border"+m+"Width"];if(f>0){if(k!==o)g=false;if(l!==s)c=false;if(m!==q)i=false}o=k;s=l;q=m;d[t]=h.aa(l);m=a[t]=h.m(b[t]==="none"?"0":this.Ld[m]||m);if(m.a(this.d)>0)e=true}});return e?{O:a,de:b,dd:d,qe:i,ed:c,ee:g}:null},T:h.p.oa(function(){var a=this.d,b=a.currentStyle,d;a.tagName in
+h.uc&&a.offsetParent.currentStyle.borderCollapse==="collapse"||this.zc(function(){d=b.borderWidth+"|"+b.borderStyle+"|"+b.borderColor});return d}),zc:function(a){var b=this.d.runtimeStyle,d=b.borderWidth,e=b.borderColor;if(d)b.borderWidth="";if(e)b.borderColor="";a=a.call(this);if(d)b.borderWidth=d;if(e)b.borderColor=e;return a}});(function(){h.lb=h.p.ba({Aa:"border-radius",Ia:"borderRadius",ea:function(b){var d=null,e,c,g,i,j=false;if(b){c=new h.q(b);var f=function(){for(var k=[],l;(g=c.next())&&
+g.G();){i=h.m(g.c);l=i.dc();if(l<0)return null;if(l>0)j=true;k.push(i)}return k.length>0&&k.length<5?{tl:k[0],tr:k[1]||k[0],br:k[2]||k[0],bl:k[3]||k[1]||k[0]}:null};if(b=f()){if(g){if(g.h&h.q.ya.xa&&g.c==="/")e=f()}else e=b;if(j&&b&&e)d={x:b,y:e}}}return d}});var a=h.m("0");a={tl:a,tr:a,br:a,bl:a};h.lb.Bc={x:a,y:a}})();h.Ib=h.p.ba({Aa:"border-image",Ia:"borderImage",hb:{stretch:1,round:1,repeat:1,space:1},ea:function(a){var b=null,d,e,c,g,i,j,f=0,k=h.q.ya,l=k.W,m=k.wa,o=k.Ta;if(a){d=new h.q(a);b=
+{};for(var s=function(n){return n&&n.h&k.xa&&n.c==="/"},q=function(n){return n&&n.h&l&&n.c==="fill"},t=function(){g=d.va(function(n){return!(n.h&(m|o))});if(q(d.next())&&!b.fill)b.fill=true;else d.C();if(s(d.next())){f++;i=d.va(function(n){return!n.G()&&!(n.h&l&&n.c==="auto")});if(s(d.next())){f++;j=d.va(function(n){return!n.Ea()})}}else d.C()};a=d.next();){e=a.h;c=a.c;if(e&(m|o)&&!g){d.C();t()}else if(q(a)&&!b.fill){b.fill=true;t()}else if(e&l&&this.hb[c]&&!b.repeat){b.repeat={e:c};if(a=d.next())if(a.h&
+l&&this.hb[a.c])b.repeat.wc=a.c;else d.C()}else if(e&k.URL&&!b.src)b.src=c;else return null}if(!b.src||!g||g.length<1||g.length>4||i&&i.length>4||f===1&&i.length<1||j&&j.length>4||f===2&&j.length<1)return null;if(!b.repeat)b.repeat={e:"stretch"};if(!b.repeat.wc)b.repeat.wc=b.repeat.e;a=function(n,u){return{t:u(n[0]),r:u(n[1]||n[0]),b:u(n[2]||n[0]),l:u(n[3]||n[1]||n[0])}};b.slice=a(g,function(n){return h.m(n.h&m?n.c+"px":n.c)});if(i&&i[0])b.O=a(i,function(n){return n.G()?h.m(n.c):n.c});if(j&&j[0])b.Ga=
+a(j,function(n){return n.Ea()?h.m(n.c):n.c})}return b}});h.Hc=h.p.ba({Aa:"box-shadow",Ia:"boxShadow",ea:function(a){var b,d=h.m,e=h.q.ya,c;if(a){c=new h.q(a);b={Ga:[],Db:[]};for(a=function(){for(var g,i,j,f,k,l;g=c.next();){j=g.c;i=g.h;if(i&e.xa&&j===",")break;else if(g.Ea()&&!k){c.C();k=c.va(function(m){return!m.Ea()})}else if(i&e.u&&!f)f=j;else if(i&e.W&&j==="inset"&&!l)l=true;else return false}g=k&&k.length;if(g>1&&g<5){(l?b.Db:b.Ga).push({ke:d(k[0].c),le:d(k[1].c),blur:d(k[2]?k[2].c:"0"),$d:d(k[3]?
+k[3].c:"0"),color:h.aa(f||"currentColor")});return true}return false};a(););}return b&&(b.Db.length||b.Ga.length)?b:null}});h.Nb=h.p.ba({ea:function(a){a=new h.q(a);for(var b=[],d;(d=a.next())&&d.G();)b.push(h.m(d.c));return b.length>0&&b.length<5?{t:b[0],r:b[1]||b[0],b:b[2]||b[0],l:b[3]||b[1]||b[0]}:null},T:h.p.oa(function(){var a=this.d,b=a.runtimeStyle,d=b.padding;if(d)b.padding="";a=a.currentStyle.padding;if(d)b.padding=d;return a})});h.Oc=h.p.ba({T:h.p.oa(function(){var a=this.d,b=a.runtimeStyle,
+d=a.currentStyle;a=b.visibility;b.visibility="";d=d.visibility+"|"+d.display;b.visibility=a;return d}),ea:function(){var a=this.T().split("|");return{xc:a[0]!=="hidden",Vb:a[1]!=="none"}},j:function(){return false}});h.Pc=function(){function a(c){return function(){var g=arguments,i,j=g.length,f,k,l;f=this[d+c]||(this[d+c]={});for(i=0;i';j.kc=1;i=[k,f,' id="',j.Xb,'" style="',j.Ad(),'" ',j.gd];c(j[d]);i.push(">");g("fill");i.push("");return i.join("")},k:function(){var c=this.B(),g=c&&c.parentNode;if(g){g.removeChild(c);delete this.Qb}}};return b}();h.v={sa:function(a){function b(d,e,c,g){this.d=d;this.o=e;this.g=c;this.parent=g}h.Fa(b.prototype,h.v,a);return b},ra:function(){return false},qc:h.pd,Gb:function(){this.j()?this.Ca():this.k()},
+Bb:function(){this.d.runtimeStyle.borderColor="transparent"},k:function(){}};h.Fa(h.v,{B:function(a,b){var d=this.wb||(this.wb={}),e=d[a];if(!e){e=d[a]=new h.Pc(a,b);this.parent.sd(e)}return e},Ba:function(a){var b=this.wb,d=b&&b[a];if(d){d.k();this.parent.Sd(d);delete b[a]}return!!d},zd:function(a){var b=this.d,d=this.o.n(),e=d.f,c=d.e,g,i,j,f,k,l;d=a.x.tl.a(b,e);g=a.y.tl.a(b,c);i=a.x.tr.a(b,e);j=a.y.tr.a(b,c);f=a.x.br.a(b,e);k=a.y.br.a(b,c);l=a.x.bl.a(b,e);a=a.y.bl.a(b,c);e=Math.min(e/(d+i),c/(j+
+k),e/(l+f),c/(g+a));if(e<1){d*=e;g*=e;i*=e;j*=e;f*=e;k*=e;l*=e;a*=e}return{x:{tl:d,tr:i,br:f,bl:l},y:{tl:g,tr:j,br:k,bl:a}}},Z:function(a,b,d,e,c,g){a=this.$(a,b,d,e,c,g);return"m"+a[0]+","+a[1]+"qy"+a[2]+","+a[3]+"l"+a[4]+","+a[5]+"qx"+a[6]+","+a[7]+"l"+a[8]+","+a[9]+"qy"+a[10]+","+a[11]+"l"+a[12]+","+a[13]+"qx"+a[14]+","+a[15]+"x"},$:function(a,b,d,e,c,g){var i=this.o.n(),j=i.f*c,f=i.e*c,k=Math;i=k.floor;var l=k.ceil,m=k.max;k=k.min;a*=c;b*=c;d*=c;e*=c;g||(g=this.g.F.i());if(g){g=this.zd(g);var o=
+g.x.tl*c,s=g.y.tl*c,q=g.x.tr*c,t=g.y.tr*c,n=g.x.br*c,u=g.y.br*c,p=g.x.bl*c;c=g.y.bl*c;e=[i(e),i(k(m(s,a),f-d)),i(k(m(o,e),j-b)),i(a),l(m(e,j-m(q,b))),i(a),l(j-b),i(k(m(t,a),f-d)),l(j-b),l(m(a,f-m(u,d))),l(m(e,j-m(n,b))),l(f-d),i(k(m(p,e),j-b)),l(f-d),i(e),l(m(a,f-m(c,d)))]}else{a=i(a);b=l(j-b);d=l(f-d);e=i(e);e=[e,a,e,a,b,a,b,a,b,d,b,d,e,d,e,d]}return e},Bb:function(){var a=this.d,b=a.currentStyle,d=a.runtimeStyle,e=a.tagName,c=h.U===6,g;if(c&&(e in h.Tb||e==="FIELDSET")||e==="BUTTON"||e==="INPUT"&&
+a.type in h.Hd){d.borderWidth="";e=this.g.s.sc;for(g=e.length;g--;){c=e[g];d["padding"+c]="";d["padding"+c]=h.m(b["padding"+c]).a(a)+h.m(b["border"+c+"Width"]).a(a)+(h.U!==8&&g%2?1:0)}d.borderWidth=0}else if(c){if(a.childNodes.length!==1||a.firstChild.tagName!=="ie6-mask"){b=H.createElement("ie6-mask");e=b.style;e.visibility="visible";for(e.zoom=1;e=a.firstChild;)b.appendChild(e);a.appendChild(b);d.visibility="hidden"}}else d.borderColor="transparent"},pe:function(){},k:function(){var a=this.wb,b;
+if(a)for(b in a)a.hasOwnProperty(b)&&this.Ba(b)}});h.Mc=h.v.sa({j:function(){var a=this.ad;for(var b in a)if(a.hasOwnProperty(b)&&a[b].j())return true;return false},ac:function(){var a=this.ec(),b=a,d;a=a.currentStyle;var e=a.position,c=0,g=0;g=this.o.n();var i=this.g.jb.i(),j=g.jc;if(e==="fixed"&&h.U>6){c=g.x*j;g=g.y*j;b=e}else{do b=b.offsetParent;while(b&&b.currentStyle.position==="static");if(b){d=b.getBoundingClientRect();b=b.currentStyle;c=(g.x-d.left)*j-(parseFloat(b.borderLeftWidth)||0);g=
+(g.y-d.top)*j-(parseFloat(b.borderTopWidth)||0)}else{b=H.documentElement;c=(g.x+b.scrollLeft-b.clientLeft)*j;g=(g.y+b.scrollTop-b.clientTop)*j}b="absolute"}return"direction:ltr;position:absolute;behavior:none !important;position:"+b+";left:"+c+"px;top:"+g+"px;z-index:"+(e==="static"?-1:a.zIndex)+";display:"+(i.xc&&i.Vb?"block":"none")},vc:function(){var a=this.bc();if(a&&(this.o.oc()||this.g.jb.L()))a.style.cssText=this.ac()},ec:function(){var a=this.d;return a.tagName in h.uc?a.offsetParent:a},bc:function(){var a=
+this.sb;if(!a)a=this.sb=H.getElementById("_pie"+h.Q.pa(this));return a},Gb:function(){var a=this.Wa,b,d,e,c,g,i;if(this.j())if(a)if(b=this.vb){d=0;for(e=a.length;d'];d=0;for(e=a.length;d");this.ec().insertAdjacentHTML("beforeBegin",b.join(""));this.vb=a;this.Wa=0}}else this.vc();else this.k()},Wd:function(a,b){return a.eb-b.eb},sd:function(a){(this.Wa||(this.Wa=[])).push(a)},Sd:function(a){var b=this.vb,d;if(b)for(d=b.length;d--;)if(b[d]===a){b.splice(d,1);break}},k:function(){var a=this.sb,b;if(a&&(b=a.parentNode))b.removeChild(a);delete this.sb;delete this.vb}});H.createElement("css3pie");h.Dc=h.v.sa({H:2,ra:function(){var a=this.g;return a.K.L()||a.F.L()},j:function(){var a=
+this.g;return a.D.j()||a.F.j()||a.K.j()||a.na.j()&&a.na.i().Db},Ca:function(){var a=this.o.n();if(a.f&&a.e){this.nd();this.od()}},nd:function(){var a=this.g.K.i(),b=this.o.n(),d=this.d,e=a&&a.color,c;if(e&&e.Y()>0){this.fc();c=this.B("bgColor",this.H);c.ta(b.f,b.e);c.fa("path",this.$b(b,a.bd));c.w("color",e.M(d));a=e.Y();a<1&&c.w("opacity",a)}else this.Ba("bgColor")},od:function(){var a=this.g.K.i(),b=this.o.n();a=a&&a.R;var d,e,c,g,i;if(a){this.fc();c=b.f;g=b.e;for(i=a.length;i--;){d=a[i];e=this.B("bgImage"+
+i,this.H+(0.5-i/1E3));e.fa("path",this.$b(b,d.Xa));e.ta(c,g);if(d.V==="linear-gradient")this.Xc(e,d);else{e.w("type","tile","color","none");this.Pd(e,d.Cb,i)}}}for(i=a?a.length:0;this.Ba("bgImage"+i++););},Pd:function(a,b,d){h.Q.Ac(b,function(e){var c=this.d,g=this.o.n(),i=g.f,j=g.e;if(i&&j){var f=this.g,k=f.K,l=k.i().R[d],m=k.ud(l.Ya,this.o,f.s,f.da);f=(l.Za||h.Ma.Jc).a(this.d,m.f,m.e,e.f,e.e);k=this.vd(l.Ya);c=l.ma?l.ma.coords(c,m.f-f.f,m.e-f.e):{x:0,y:0};l=l.bb;var o=0,s=0,q=i+1,t=j+1,n=h.U===
+8?0:1;m=Math.round(k.x+c.x)+0.5;k=Math.round(k.y+c.y)+0.5;a.w("src",b,"position",m/i+","+k/j,"size",f.f!==e.f||f.e!==e.e||g.jc!==1||screen.logicalXDPI/screen.deviceXDPI!==1?h.Qa.gb(f.f)+"pt,"+h.Qa.gb(f.e)+"pt":"");if(l&&l!=="repeat"){if(l==="repeat-x"||l==="no-repeat"){o=k+1;t=k+f.e+n}if(l==="repeat-y"||l==="no-repeat"){s=m+1;q=m+f.f+n}a.Ha("clip","rect("+o+"px,"+q+"px,"+t+"px,"+s+"px)")}}},this)},$b:function(a,b){var d=0,e=0,c=0,g=0,i=this.d,j=this.g,f;if(b&&b!=="border-box")if((f=j.s.i())&&(f=f.O)){d+=
+f.t.a(i);e+=f.r.a(i);c+=f.b.a(i);g+=f.l.a(i)}if(b==="content-box")if(b=j.da.i()){d+=b.t.a(i);e+=b.r.a(i);c+=b.b.a(i);g+=b.l.a(i)}return"m0,0r0,0m"+a.f*2+","+a.e*2+"r0,0"+this.Z(d,e,c,g,2)},vd:function(a){var b=this.d,d=this.g,e=0,c=0,g;if(a!=="border-box")if((g=d.s.i())&&(g=g.O)){e+=g.l.a(b);c+=g.t.a(b)}if(a==="content-box")if(a=d.da.i()){e+=a.l.a(b);c+=a.t.a(b)}return{x:e,y:c}},Xc:function(a,b){var d=this.d,e=this.o.n(),c=e.f,g=e.e;e=b.ua;var i=e.length,j=Math.PI,f=h.nb.xd(d,c,g,b),k=f.la;b=f.Jd;
+var l,m;for(c=k%90?Math.atan2(f.be-f.rd,(f.qd-f.ae)*c/g)/j*180-90:-k;c<0;)c+=360;c%=360;g=[];j=[];for(f=0;f0){k[0]=this.Z(0,0,0,0,2);p=a.t;if(p==="double")k.push(this.Z(j/3,l/3,m/3,g/3,2)+this.Z(j*2/3,l*2/3,m*2/3,g*2/3,2));else if(p in u){c=this.$(j,l,m,g,2);this.S(k,c[2],c[4],j*2,0,0,a.t);this.S(k,c[7],
+c[9],l*2,(e.f-l)*2,1,a.r);this.S(k,c[12],c[10],m*2,(e.e-m)*2,0,a.b);this.S(k,c[1],c[15],g*2,0,1,a.l)}k.push(this.Z(j,l,m,g,2));b.push(k.join(""),i.t.M(d))}}else{o=this.$(0,0,0,0,2);c=this.$(j,l,m,g,2);for(n in t)if(t.hasOwnProperty(n)&&i[n].Y()>0){p=t[n];var v=p[0],C=p[1],y=p[2],B=p[3],F=p[4],G=p[5],K=p[6],J=p[7],w=p[8],P=n==="t"||n==="l";p=a[n];k[0]="al"+o[v]+","+o[C]+","+f(o[y]-o[v])+","+f(o[B]-o[C])+","+(w+45)*65535+",-2949075ae"+o[F]+","+o[G]+","+f(o[K]-o[F])+","+f(o[J]-o[G])+","+w*65535+",-2949075";
+if(p in this.md){if(!s)if(p==="double"){s=this.$(j/3,l/3,m/3,g/3,2);q=this.$(j*2/3,l*2/3,m*2/3,g*2/3,2)}else s=q=this.$(j/2,l/2,m/2,g/2,2);k.push("ae"+s[F]+","+s[G]+","+f(s[K]-s[F])+","+f(s[J]-s[G])+","+(w-45)*65535+",2949075ae"+s[v]+","+s[C]+","+f(s[y]-s[v])+","+f(s[B]-s[C])+","+w*65535+",2949075x");if(p!=="double"){r=i[n].M(d)+((p==="groove"?P:!P)?" darken(128)":" lighten(128)");b.push(k.join(""),r);k.length=0}k.push("al"+q[v]+","+q[C]+","+f(q[y]-q[v])+","+f(q[B]-q[C])+","+(w+45)*65535+",-2949075ae"+
+q[F]+","+q[G]+","+f(q[K]-q[F])+","+f(q[J]-q[G])+","+w*65535+",-2949075")}k.push("ae"+c[F]+","+c[G]+","+f(c[K]-c[F])+","+f(c[J]-c[G])+","+(w-45)*65535+",2949075ae"+c[v]+","+c[C]+","+f(c[y]-c[v])+","+f(c[B]-c[C])+","+w*65535+",2949075x");if(p in u)n==="t"?this.S(k,c[2],c[4],j*2,0,0,p):n==="r"?this.S(k,c[7],c[9],l*2,(e.f-l)*2,1,p):n==="b"?this.S(k,c[12],c[10],m*2,(e.e-m)*2,0,p):this.S(k,c[1],c[15],g*2,0,1,p);r=i[n].M(d);if(p in this.Ub)r+=(p==="groove"||p==="outset"?P:!P)?" lighten(128)":" darken(128)";
+b.push(k.join(""),r);k.length=0}}}return b},k:function(){if(this.Yb||!this.g.D.j())this.d.runtimeStyle.borderColor="";h.v.k.call(this)}});h.Ec=h.v.sa({H:5,ra:function(){return this.g.D.L()},j:function(){return this.g.D.j()},Ca:function(){var a=this.g.D.i(),b=this.g.s.i(),d=this.o.n(),e=this.d;h.Q.Ac(a.src,function(c){function g(r,v,C,y,B,F,G,K,J){var w=Math.max;if(!u||!p||!y||!B||!K||!J)r.Ha("display","none");else{y=w(y,0);B=w(B,0);r.fa("path","m0,0l"+y*2+",0l"+y*2+","+B*2+"l0,"+B*2+"x");r.w("src",
+n,"type","tile","position","0,0","origin",(F-0.5)/u+","+(G-0.5)/p,"size",h.Qa.gb(y*u/K)+"pt,"+h.Qa.gb(B*p/J)+"pt");r.ta(y,B);r.Ha("left",v+"px","top",C+"px","display","")}}var i=d.f,j=d.e,f=h.m("0"),k=a.O||(b?b.O:{t:f,r:f,b:f,l:f});f=k.t.a(e);var l=k.r.a(e),m=k.b.a(e);k=k.l.a(e);var o=a.slice,s=o.t.a(e),q=o.r.a(e),t=o.b.a(e);o=o.l.a(e);var n=a.src,u=c.f,p=c.e;g(this.N("tl"),0,0,k,f,0,0,o,s);g(this.N("t"),k,0,i-k-l,f,o,0,u-o-q,s);g(this.N("tr"),i-l,0,l,f,u-q,0,q,s);g(this.N("r"),i-l,f,l,j-f-m,u-q,
+s,q,p-s-t);g(this.N("br"),i-l,j-m,l,m,u-q,p-t,q,t);g(this.N("b"),k,j-m,i-k-l,m,o,p-t,u-o-q,t);g(this.N("bl"),0,j-m,k,m,0,p-t,o,t);g(this.N("l"),0,f,k,j-f-m,0,s,o,p-s-t);g(this.N("c"),k,f,i-k-l,j-f-m,o,s,a.fill?u-o-q:0,p-s-t)},this)},N:function(a){return this.B("borderImage_"+a,this.H)},qc:function(){if(this.j()){var a=this.d,b=a.runtimeStyle,d=this.g.D.i().O;b.borderStyle="solid";if(d){b.borderTopWidth=d.t.a(a);b.borderRightWidth=d.r.a(a);b.borderBottomWidth=d.b.a(a);b.borderLeftWidth=d.l.a(a)}this.Bb()}},
+k:function(){var a=this.d.runtimeStyle;a.borderStyle="";if(this.Yb||!this.g.s.j())a.borderColor=a.borderWidth="";h.v.k.call(this)}});h.Gc=h.v.sa({H:1,ra:function(){var a=this.g;return a.na.L()||a.F.L()},j:function(){var a=this.g.na;return a.j()&&a.i().Ga[0]},Ca:function(){var a=this.d,b=this.g,d=b.na.i().Ga;b=b.F.i();var e=d.length,c=e,g=this.o.n(),i=g.f;g=g.e;for(var j,f,k,l,m,o,s,q,t,n;c--;){j=d[c];k=j.ke.a(a);l=j.le.a(a);m=j.$d.a(a);o=j.blur.a(a);j=j.color;s=j.Y();j=j.M(a);f=-m-o;if(!b&&o)b=h.lb.Bc;
+q=this.Z(f,f,f,f,2,b);f=this.B("shadow"+c,this.H+(0.5-c/1E3));if(o){t=(m+o)*2+i;n=(m+o)*2+g;m=t?o*2/t:0;o=n?o*2/n:0;if(m>0.5||o>0.5){t=0.5/Math.max(m,o);m*=t;o*=t;s*=t*t}f.w("type","gradienttitle","color2",j,"focusposition",m+","+o,"focussize",1-m*2+","+(1-o*2),"opacity",0,"o:opacity2",s)}else f.w("type","solid","opacity",s);f.fa("path",q);f.w("color",j);f.Ha("left",k+"px","top",l+"px");f.ta(i,g)}for(;this.Ba("shadow"+e++););}});h.Lc=h.v.sa({H:6,ra:function(){var a=this.g;return this.d.src!==this.Sc||
+a.F.L()},j:function(){var a=this.g;return a.F.j()||a.K.ic()},Ca:function(){this.Sc=g;this.Ed();var a=this.B("img",this.H),b=this.o.n(),d=b.f;b=b.e;var e=this.g.s.i(),c=e&&e.O;e=this.d;var g=e.src,i=Math.round,j=this.g.da.i();if(!c||h.U<7){c=h.m("0");c={t:c,r:c,b:c,l:c}}a.fa("path",this.Z(i(c.t.a(e)+j.t.a(e)),i(c.r.a(e)+j.r.a(e)),i(c.b.a(e)+j.b.a(e)),i(c.l.a(e)+j.l.a(e)),2));a.w("type","frame","src",g,"position",(d?0.5/d:0)+","+(b?0.5/b:0));a.ta(d,b)},Ed:function(){this.d.runtimeStyle.filter="alpha(opacity=0)"},
+k:function(){h.v.k.call(this);this.d.runtimeStyle.filter=""}});h.mb=function(){function a(n,u){n.className+=" "+u}function b(n){var u=t.slice.call(arguments,1),p=u.length;setTimeout(function(){if(n)for(;p--;)a(n,u[p])},0)}function d(n){var u=t.slice.call(arguments,1),p=u.length;setTimeout(function(){if(n)for(;p--;){var r=u[p];r=q[r]||(q[r]=new RegExp("\\b"+r+"\\b","g"));n.className=n.className.replace(r,"")}},0)}function e(n){function u(){if(!T){var x,z,E=h.qa,N=n.currentStyle,I=N.getAttribute(g)===
+"true",Z=N.getAttribute(j)!=="false",$=N.getAttribute(f)!=="false";R=N.getAttribute(i);R=E>7?R!=="false":R==="true";if(!U){U=1;n.runtimeStyle.zoom=1;N=n;for(var aa=1;N=N.previousSibling;)if(N.nodeType===1){aa=0;break}aa&&a(n,o)}D.cb();if(I&&(z=D.n())&&(x=H.documentElement||H.body)&&(z.y>x.clientHeight||z.x>x.clientWidth||z.y+z.e<0||z.x+z.f<0)){if(!X){X=1;h.pb.ca(u)}}else{T=1;X=U=0;h.pb.Ka(u);if(E===9){A={K:new h.Hb(n),D:new h.Ib(n),s:new h.Jb(n),da:new h.Nb(n)};Q=[A.K,A.s,A.D,A.da];L=new h.oe(n,D,
+A);M=[new h.me(n,D,A,L),new h.ne(n,D,A,L)]}else{A={K:new h.Hb(n),s:new h.Jb(n),D:new h.Ib(n),F:new h.lb(n),na:new h.Hc(n),da:new h.Nb(n),jb:new h.Oc(n)};Q=[A.K,A.s,A.D,A.F,A.na,A.da,A.jb];L=new h.Mc(n,D,A);M=[new h.Gc(n,D,A,L),new h.Dc(n,D,A,L),new h.Fc(n,D,A,L),new h.Ec(n,D,A,L)];n.tagName==="IMG"&&M.push(new h.Lc(n,D,A,L));L.ad=M}if(x=n.currentStyle.getAttribute(h.z+"watch-ancestors")){x=parseInt(x,10);z=0;for(I=n.parentNode;I&&(x==="NaN"||z++
+ } else {
+ definition();
+ }
+})(function () {
+
+
+ var call = Function.prototype.call;
+ var prototypeOfObject = Object.prototype;
+ var owns = call.bind(prototypeOfObject.hasOwnProperty);
+
+// If JS engine supports accessors creating shortcuts.
+ var defineGetter;
+ var defineSetter;
+ var lookupGetter;
+ var lookupSetter;
+ var supportsAccessors;
+ if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+ }
+
+// ES5 15.2.3.2
+// http://es5.github.com/#x15.2.3.2
+ if (!Object.getPrototypeOf) {
+ // https://github.com/kriskowal/es5-shim/issues#issue/2
+ // http://ejohn.org/blog/objectgetprototypeof/
+ // recommended by fschaefer on github
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor
+ ? object.constructor.prototype
+ : prototypeOfObject
+ );
+ };
+ }
+
+//ES5 15.2.3.3
+//http://es5.github.com/#x15.2.3.3
+
+ function doesGetOwnPropertyDescriptorWork(object) {
+ try {
+ object.sentinel = 0;
+ return Object.getOwnPropertyDescriptor(
+ object,
+ "sentinel"
+ ).value === 0;
+ } catch (exception) {
+ // returns falsy
+ }
+ }
+
+//check whether getOwnPropertyDescriptor works if it's given. Otherwise,
+//shim partially.
+ if (Object.defineProperty) {
+ var getOwnPropertyDescriptorWorksOnObject =
+ doesGetOwnPropertyDescriptorWork({});
+ var getOwnPropertyDescriptorWorksOnDom = typeof document == "undefined" ||
+ doesGetOwnPropertyDescriptorWork(document.createElement("div"));
+ if (!getOwnPropertyDescriptorWorksOnDom ||
+ !getOwnPropertyDescriptorWorksOnObject
+ ) {
+ var getOwnPropertyDescriptorFallback = Object.getOwnPropertyDescriptor;
+ }
+ }
+
+ if (!Object.getOwnPropertyDescriptor || getOwnPropertyDescriptorFallback) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a non-object: ";
+
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null) {
+ throw new TypeError(ERR_NON_OBJECT + object);
+ }
+
+ // make a valiant attempt to use the real getOwnPropertyDescriptor
+ // for I8's DOM elements.
+ if (getOwnPropertyDescriptorFallback) {
+ try {
+ return getOwnPropertyDescriptorFallback.call(Object, object, property);
+ } catch (exception) {
+ // try the shim if the real one doesn't work
+ }
+ }
+
+ // If object does not owns property return undefined immediately.
+ if (!owns(object, property)) {
+ return;
+ }
+
+ // If object has a property then it's for sure both `enumerable` and
+ // `configurable`.
+ var descriptor = { enumerable: true, configurable: true };
+
+ // If JS engine supports accessor properties then property may be a
+ // getter or setter.
+ if (supportsAccessors) {
+ // Unfortunately `__lookupGetter__` will return a getter even
+ // if object has own non getter property along with a same named
+ // inherited getter. To avoid misbehavior we temporary remove
+ // `__proto__` so that `__lookupGetter__` will return getter only
+ // if it's owned by an object.
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+
+ // Once we have getter and setter we can put values back.
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) {
+ descriptor.get = getter;
+ }
+ if (setter) {
+ descriptor.set = setter;
+ }
+ // If it was accessor property we're done and return here
+ // in order to avoid adding `value` to the descriptor.
+ return descriptor;
+ }
+ }
+
+ // If we got this far we know that object has an own property that is
+ // not an accessor so we set it as a value and return descriptor.
+ descriptor.value = object[property];
+ descriptor.writable = true;
+ return descriptor;
+ };
+ }
+
+// ES5 15.2.3.4
+// http://es5.github.com/#x15.2.3.4
+ if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+ }
+
+// ES5 15.2.3.5
+// http://es5.github.com/#x15.2.3.5
+ if (!Object.create) {
+
+ // Contributed by Brandon Benvie, October, 2012
+ var createEmpty;
+ var supportsProto = Object.prototype.__proto__ === null;
+ if (supportsProto || typeof document == 'undefined') {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ // In old IE __proto__ can't be used to manually set `null`, nor does
+ // any other method exist to make an object that inherits from nothing,
+ // aside from Object.prototype itself. Instead, create a new global
+ // object and *steal* its Object.prototype and strip it bare. This is
+ // used as the prototype to create nullary objects.
+ createEmpty = function () {
+ var iframe = document.createElement('iframe');
+ var parent = document.body || document.documentElement;
+ iframe.style.display = 'none';
+ parent.appendChild(iframe);
+ iframe.src = 'javascript:';
+ var empty = iframe.contentWindow.Object.prototype;
+ parent.removeChild(iframe);
+ iframe = null;
+ delete empty.constructor;
+ delete empty.hasOwnProperty;
+ delete empty.propertyIsEnumerable;
+ delete empty.isPrototypeOf;
+ delete empty.toLocaleString;
+ delete empty.toString;
+ delete empty.valueOf;
+ empty.__proto__ = null;
+
+ function Empty() {}
+ Empty.prototype = empty;
+ // short-circuit future calls
+ createEmpty = function () {
+ return new Empty();
+ };
+ return new Empty();
+ };
+ }
+
+ Object.create = function create(prototype, properties) {
+
+ var object;
+ function Type() {} // An empty constructor.
+
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype !== "object" && typeof prototype !== "function") {
+ // In the native implementation `parent` can be `null`
+ // OR *any* `instanceof Object` (Object|Function|Array|RegExp|etc)
+ // Use `typeof` tho, b/c in old IE, DOM elements are not `instanceof Object`
+ // like they are in modern browsers. Using `Object.create` on DOM elements
+ // is...err...probably inappropriate, but the native version allows for it.
+ throw new TypeError("Object prototype may only be an Object or null"); // same msg as Chrome
+ }
+ Type.prototype = prototype;
+ object = new Type();
+ // IE has no built-in implementation of `Object.getPrototypeOf`
+ // neither `__proto__`, but this manually setting `__proto__` will
+ // guarantee that `Object.getPrototypeOf` will work as expected with
+ // objects created using `Object.create`
+ object.__proto__ = prototype;
+ }
+
+ if (properties !== void 0) {
+ Object.defineProperties(object, properties);
+ }
+
+ return object;
+ };
+ }
+
+// ES5 15.2.3.6
+// http://es5.github.com/#x15.2.3.6
+
+// Patch for WebKit and IE8 standard mode
+// Designed by hax
+// related issue: https://github.com/kriskowal/es5-shim/issues#issue/5
+// IE8 Reference:
+// http://msdn.microsoft.com/en-us/library/dd282900.aspx
+// http://msdn.microsoft.com/en-us/library/dd229916.aspx
+// WebKit Bugs:
+// https://bugs.webkit.org/show_bug.cgi?id=36423
+
+ function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ // returns falsy
+ }
+ }
+
+// check whether defineProperty works if it's given. Otherwise,
+// shim partially.
+ if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty,
+ definePropertiesFallback = Object.defineProperties;
+ }
+ }
+
+ if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null) {
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ }
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null) {
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ }
+ // make a valiant attempt to use the real defineProperty
+ // for I8's DOM elements.
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ // try the shim if the real one doesn't work
+ }
+ }
+
+ // If it's a data property.
+ if (owns(descriptor, "value")) {
+ // fail silently if "writable", "enumerable", or "configurable"
+ // are requested but not supported
+ /*
+ // alternate approach:
+ if ( // can't implement these features; allow false but not true
+ !(owns(descriptor, "writable") ? descriptor.writable : true) ||
+ !(owns(descriptor, "enumerable") ? descriptor.enumerable : true) ||
+ !(owns(descriptor, "configurable") ? descriptor.configurable : true)
+ )
+ throw new RangeError(
+ "This implementation of Object.defineProperty does not " +
+ "support configurable, enumerable, or writable."
+ );
+ */
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ // As accessors are supported only on engines implementing
+ // `__proto__` we can safely override `__proto__` while defining
+ // a property to make sure that we don't hit an inherited
+ // accessor.
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ // Deleting a property anyway since getter / setter may be
+ // defined on object itself.
+ delete object[property];
+ object[property] = descriptor.value;
+ // Setting original `__proto__` back now.
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors) {
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ }
+ // If we got that far then getters and setters can be defined !!
+ if (owns(descriptor, "get")) {
+ defineGetter(object, property, descriptor.get);
+ }
+ if (owns(descriptor, "set")) {
+ defineSetter(object, property, descriptor.set);
+ }
+ }
+ return object;
+ };
+ }
+
+// ES5 15.2.3.7
+// http://es5.github.com/#x15.2.3.7
+ if (!Object.defineProperties || definePropertiesFallback) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ // make a valiant attempt to use the real defineProperties
+ if (definePropertiesFallback) {
+ try {
+ return definePropertiesFallback.call(Object, object, properties);
+ } catch (exception) {
+ // try the shim if the real one doesn't work
+ }
+ }
+
+ for (var property in properties) {
+ if (owns(properties, property) && property != "__proto__") {
+ Object.defineProperty(object, property, properties[property]);
+ }
+ }
+ return object;
+ };
+ }
+
+// ES5 15.2.3.8
+// http://es5.github.com/#x15.2.3.8
+ if (!Object.seal) {
+ Object.seal = function seal(object) {
+ // this is misleading and breaks feature-detection, but
+ // allows "securable" code to "gracefully" degrade to working
+ // but insecure code.
+ return object;
+ };
+ }
+
+// ES5 15.2.3.9
+// http://es5.github.com/#x15.2.3.9
+ if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ // this is misleading and breaks feature-detection, but
+ // allows "securable" code to "gracefully" degrade to working
+ // but insecure code.
+ return object;
+ };
+ }
+
+// detect a Rhino bug and patch it
+ try {
+ Object.freeze(function () {});
+ } catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+ }
+
+// ES5 15.2.3.10
+// http://es5.github.com/#x15.2.3.10
+ if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ // this is misleading and breaks feature-detection, but
+ // allows "securable" code to "gracefully" degrade to working
+ // but insecure code.
+ return object;
+ };
+ }
+
+// ES5 15.2.3.11
+// http://es5.github.com/#x15.2.3.11
+ if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+ }
+
+// ES5 15.2.3.12
+// http://es5.github.com/#x15.2.3.12
+ if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+ }
+
+// ES5 15.2.3.13
+// http://es5.github.com/#x15.2.3.13
+ if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ // 1. If Type(O) is not Object throw a TypeError exception.
+ if (Object(object) !== object) {
+ throw new TypeError(); // TODO message
+ }
+ // 2. Return the Boolean value of the [[Extensible]] internal property of O.
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+ }
+
+});
diff --git a/static/js/es5_shim_v2.2.0.js b/static/js/es5_shim_v2.2.0.js
new file mode 100644
index 0000000..a2cdf1d
--- /dev/null
+++ b/static/js/es5_shim_v2.2.0.js
@@ -0,0 +1,1346 @@
+// Copyright 2009-2012 by contributors, MIT License
+// vim: ts=4 sts=4 sw=4 expandtab
+
+//Add semicolon to prevent IIFE from being passed as argument to concated code.
+;
+// Module systems magic dance
+(function (definition) {
+ // RequireJS
+ if (typeof define == "function") {
+ define(definition);
+ // YUI3
+ } else if (typeof YUI == "function") {
+ YUI.add("es5", definition);
+ // CommonJS and