@ -0,0 +1,31 @@
|
||||
HELP.md
|
||||
target/
|
||||
!.mvn/wrapper/maven-wrapper.jar
|
||||
!**/src/main/**
|
||||
!**/src/test/**
|
||||
|
||||
### STS ###
|
||||
.apt_generated
|
||||
.classpath
|
||||
.factorypath
|
||||
.project
|
||||
.settings
|
||||
.springBeans
|
||||
.sts4-cache
|
||||
|
||||
### IntelliJ IDEA ###
|
||||
.idea
|
||||
*.iws
|
||||
*.iml
|
||||
*.ipr
|
||||
|
||||
### NetBeans ###
|
||||
/nbproject/private/
|
||||
/nbbuild/
|
||||
/dist/
|
||||
/nbdist/
|
||||
/.nb-gradle/
|
||||
build/
|
||||
|
||||
### VS Code ###
|
||||
.vscode/
|
@ -0,0 +1,117 @@
|
||||
/*
|
||||
* Copyright 2012-2019 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* https://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
import java.net.*;
|
||||
import java.io.*;
|
||||
import java.nio.channels.*;
|
||||
import java.util.Properties;
|
||||
|
||||
public class MavenWrapperDownloader {
|
||||
|
||||
private static final String WRAPPER_VERSION = "0.5.5";
|
||||
/**
|
||||
* Default URL to download the maven-wrapper.jar from, if no 'downloadUrl' is provided.
|
||||
*/
|
||||
private static final String DEFAULT_DOWNLOAD_URL = "https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/"
|
||||
+ WRAPPER_VERSION + "/maven-wrapper-" + WRAPPER_VERSION + ".jar";
|
||||
|
||||
/**
|
||||
* Path to the maven-wrapper.properties file, which might contain a downloadUrl property to
|
||||
* use instead of the default one.
|
||||
*/
|
||||
private static final String MAVEN_WRAPPER_PROPERTIES_PATH =
|
||||
".mvn/wrapper/maven-wrapper.properties";
|
||||
|
||||
/**
|
||||
* Path where the maven-wrapper.jar will be saved to.
|
||||
*/
|
||||
private static final String MAVEN_WRAPPER_JAR_PATH =
|
||||
".mvn/wrapper/maven-wrapper.jar";
|
||||
|
||||
/**
|
||||
* Name of the property which should be used to override the default download url for the wrapper.
|
||||
*/
|
||||
private static final String PROPERTY_NAME_WRAPPER_URL = "wrapperUrl";
|
||||
|
||||
public static void main(String args[]) {
|
||||
System.out.println("- Downloader started");
|
||||
File baseDirectory = new File(args[0]);
|
||||
System.out.println("- Using base directory: " + baseDirectory.getAbsolutePath());
|
||||
|
||||
// If the maven-wrapper.properties exists, read it and check if it contains a custom
|
||||
// wrapperUrl parameter.
|
||||
File mavenWrapperPropertyFile = new File(baseDirectory, MAVEN_WRAPPER_PROPERTIES_PATH);
|
||||
String url = DEFAULT_DOWNLOAD_URL;
|
||||
if(mavenWrapperPropertyFile.exists()) {
|
||||
FileInputStream mavenWrapperPropertyFileInputStream = null;
|
||||
try {
|
||||
mavenWrapperPropertyFileInputStream = new FileInputStream(mavenWrapperPropertyFile);
|
||||
Properties mavenWrapperProperties = new Properties();
|
||||
mavenWrapperProperties.load(mavenWrapperPropertyFileInputStream);
|
||||
url = mavenWrapperProperties.getProperty(PROPERTY_NAME_WRAPPER_URL, url);
|
||||
} catch (IOException e) {
|
||||
System.out.println("- ERROR loading '" + MAVEN_WRAPPER_PROPERTIES_PATH + "'");
|
||||
} finally {
|
||||
try {
|
||||
if(mavenWrapperPropertyFileInputStream != null) {
|
||||
mavenWrapperPropertyFileInputStream.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
// Ignore ...
|
||||
}
|
||||
}
|
||||
}
|
||||
System.out.println("- Downloading from: " + url);
|
||||
|
||||
File outputFile = new File(baseDirectory.getAbsolutePath(), MAVEN_WRAPPER_JAR_PATH);
|
||||
if(!outputFile.getParentFile().exists()) {
|
||||
if(!outputFile.getParentFile().mkdirs()) {
|
||||
System.out.println(
|
||||
"- ERROR creating output directory '" + outputFile.getParentFile().getAbsolutePath() + "'");
|
||||
}
|
||||
}
|
||||
System.out.println("- Downloading to: " + outputFile.getAbsolutePath());
|
||||
try {
|
||||
downloadFileFromURL(url, outputFile);
|
||||
System.out.println("Done");
|
||||
System.exit(0);
|
||||
} catch (Throwable e) {
|
||||
System.out.println("- Error downloading");
|
||||
e.printStackTrace();
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
private static void downloadFileFromURL(String urlString, File destination) throws Exception {
|
||||
if (System.getenv("MVNW_USERNAME") != null && System.getenv("MVNW_PASSWORD") != null) {
|
||||
String username = System.getenv("MVNW_USERNAME");
|
||||
char[] password = System.getenv("MVNW_PASSWORD").toCharArray();
|
||||
Authenticator.setDefault(new Authenticator() {
|
||||
@Override
|
||||
protected PasswordAuthentication getPasswordAuthentication() {
|
||||
return new PasswordAuthentication(username, password);
|
||||
}
|
||||
});
|
||||
}
|
||||
URL website = new URL(urlString);
|
||||
ReadableByteChannel rbc;
|
||||
rbc = Channels.newChannel(website.openStream());
|
||||
FileOutputStream fos = new FileOutputStream(destination);
|
||||
fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
|
||||
fos.close();
|
||||
rbc.close();
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,2 @@
|
||||
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.6.2/apache-maven-3.6.2-bin.zip
|
||||
wrapperUrl=https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar
|
@ -0,0 +1,310 @@
|
||||
#!/bin/sh
|
||||
# ----------------------------------------------------------------------------
|
||||
# Licensed to the Apache Software Foundation (ASF) under one
|
||||
# or more contributor license agreements. See the NOTICE file
|
||||
# distributed with this work for additional information
|
||||
# regarding copyright ownership. The ASF licenses this file
|
||||
# to you under the Apache License, Version 2.0 (the
|
||||
# "License"); you may not use this file except in compliance
|
||||
# with the License. You may obtain a copy of the License at
|
||||
#
|
||||
# https://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing,
|
||||
# software distributed under the License is distributed on an
|
||||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
# KIND, either express or implied. See the License for the
|
||||
# specific language governing permissions and limitations
|
||||
# under the License.
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
# ----------------------------------------------------------------------------
|
||||
# Maven2 Start Up Batch script
|
||||
#
|
||||
# Required ENV vars:
|
||||
# ------------------
|
||||
# JAVA_HOME - location of a JDK home dir
|
||||
#
|
||||
# Optional ENV vars
|
||||
# -----------------
|
||||
# M2_HOME - location of maven2's installed home dir
|
||||
# MAVEN_OPTS - parameters passed to the Java VM when running Maven
|
||||
# e.g. to debug Maven itself, use
|
||||
# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
|
||||
# MAVEN_SKIP_RC - flag to disable loading of mavenrc files
|
||||
# ----------------------------------------------------------------------------
|
||||
|
||||
if [ -z "$MAVEN_SKIP_RC" ] ; then
|
||||
|
||||
if [ -f /etc/mavenrc ] ; then
|
||||
. /etc/mavenrc
|
||||
fi
|
||||
|
||||
if [ -f "$HOME/.mavenrc" ] ; then
|
||||
. "$HOME/.mavenrc"
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
# OS specific support. $var _must_ be set to either true or false.
|
||||
cygwin=false;
|
||||
darwin=false;
|
||||
mingw=false
|
||||
case "`uname`" in
|
||||
CYGWIN*) cygwin=true ;;
|
||||
MINGW*) mingw=true;;
|
||||
Darwin*) darwin=true
|
||||
# Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home
|
||||
# See https://developer.apple.com/library/mac/qa/qa1170/_index.html
|
||||
if [ -z "$JAVA_HOME" ]; then
|
||||
if [ -x "/usr/libexec/java_home" ]; then
|
||||
export JAVA_HOME="`/usr/libexec/java_home`"
|
||||
else
|
||||
export JAVA_HOME="/Library/Java/Home"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -z "$JAVA_HOME" ] ; then
|
||||
if [ -r /etc/gentoo-release ] ; then
|
||||
JAVA_HOME=`java-config --jre-home`
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -z "$M2_HOME" ] ; then
|
||||
## resolve links - $0 may be a link to maven's home
|
||||
PRG="$0"
|
||||
|
||||
# need this for relative symlinks
|
||||
while [ -h "$PRG" ] ; do
|
||||
ls=`ls -ld "$PRG"`
|
||||
link=`expr "$ls" : '.*-> \(.*\)$'`
|
||||
if expr "$link" : '/.*' > /dev/null; then
|
||||
PRG="$link"
|
||||
else
|
||||
PRG="`dirname "$PRG"`/$link"
|
||||
fi
|
||||
done
|
||||
|
||||
saveddir=`pwd`
|
||||
|
||||
M2_HOME=`dirname "$PRG"`/..
|
||||
|
||||
# make it fully qualified
|
||||
M2_HOME=`cd "$M2_HOME" && pwd`
|
||||
|
||||
cd "$saveddir"
|
||||
# echo Using m2 at $M2_HOME
|
||||
fi
|
||||
|
||||
# For Cygwin, ensure paths are in UNIX format before anything is touched
|
||||
if $cygwin ; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME=`cygpath --unix "$M2_HOME"`
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
|
||||
[ -n "$CLASSPATH" ] &&
|
||||
CLASSPATH=`cygpath --path --unix "$CLASSPATH"`
|
||||
fi
|
||||
|
||||
# For Mingw, ensure paths are in UNIX format before anything is touched
|
||||
if $mingw ; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME="`(cd "$M2_HOME"; pwd)`"
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME="`(cd "$JAVA_HOME"; pwd)`"
|
||||
fi
|
||||
|
||||
if [ -z "$JAVA_HOME" ]; then
|
||||
javaExecutable="`which javac`"
|
||||
if [ -n "$javaExecutable" ] && ! [ "`expr \"$javaExecutable\" : '\([^ ]*\)'`" = "no" ]; then
|
||||
# readlink(1) is not available as standard on Solaris 10.
|
||||
readLink=`which readlink`
|
||||
if [ ! `expr "$readLink" : '\([^ ]*\)'` = "no" ]; then
|
||||
if $darwin ; then
|
||||
javaHome="`dirname \"$javaExecutable\"`"
|
||||
javaExecutable="`cd \"$javaHome\" && pwd -P`/javac"
|
||||
else
|
||||
javaExecutable="`readlink -f \"$javaExecutable\"`"
|
||||
fi
|
||||
javaHome="`dirname \"$javaExecutable\"`"
|
||||
javaHome=`expr "$javaHome" : '\(.*\)/bin'`
|
||||
JAVA_HOME="$javaHome"
|
||||
export JAVA_HOME
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -z "$JAVACMD" ] ; then
|
||||
if [ -n "$JAVA_HOME" ] ; then
|
||||
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
|
||||
# IBM's JDK on AIX uses strange locations for the executables
|
||||
JAVACMD="$JAVA_HOME/jre/sh/java"
|
||||
else
|
||||
JAVACMD="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
else
|
||||
JAVACMD="`which java`"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ ! -x "$JAVACMD" ] ; then
|
||||
echo "Error: JAVA_HOME is not defined correctly." >&2
|
||||
echo " We cannot execute $JAVACMD" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "$JAVA_HOME" ] ; then
|
||||
echo "Warning: JAVA_HOME environment variable is not set."
|
||||
fi
|
||||
|
||||
CLASSWORLDS_LAUNCHER=org.codehaus.plexus.classworlds.launcher.Launcher
|
||||
|
||||
# traverses directory structure from process work directory to filesystem root
|
||||
# first directory with .mvn subdirectory is considered project base directory
|
||||
find_maven_basedir() {
|
||||
|
||||
if [ -z "$1" ]
|
||||
then
|
||||
echo "Path not specified to find_maven_basedir"
|
||||
return 1
|
||||
fi
|
||||
|
||||
basedir="$1"
|
||||
wdir="$1"
|
||||
while [ "$wdir" != '/' ] ; do
|
||||
if [ -d "$wdir"/.mvn ] ; then
|
||||
basedir=$wdir
|
||||
break
|
||||
fi
|
||||
# workaround for JBEAP-8937 (on Solaris 10/Sparc)
|
||||
if [ -d "${wdir}" ]; then
|
||||
wdir=`cd "$wdir/.."; pwd`
|
||||
fi
|
||||
# end of workaround
|
||||
done
|
||||
echo "${basedir}"
|
||||
}
|
||||
|
||||
# concatenates all lines of a file
|
||||
concat_lines() {
|
||||
if [ -f "$1" ]; then
|
||||
echo "$(tr -s '\n' ' ' < "$1")"
|
||||
fi
|
||||
}
|
||||
|
||||
BASE_DIR=`find_maven_basedir "$(pwd)"`
|
||||
if [ -z "$BASE_DIR" ]; then
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
##########################################################################################
|
||||
# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
|
||||
# This allows using the maven wrapper in projects that prohibit checking in binary data.
|
||||
##########################################################################################
|
||||
if [ -r "$BASE_DIR/.mvn/wrapper/maven-wrapper.jar" ]; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found .mvn/wrapper/maven-wrapper.jar"
|
||||
fi
|
||||
else
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Couldn't find .mvn/wrapper/maven-wrapper.jar, downloading it ..."
|
||||
fi
|
||||
if [ -n "$MVNW_REPOURL" ]; then
|
||||
jarUrl="$MVNW_REPOURL/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
|
||||
else
|
||||
jarUrl="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
|
||||
fi
|
||||
while IFS="=" read key value; do
|
||||
case "$key" in (wrapperUrl) jarUrl="$value"; break ;;
|
||||
esac
|
||||
done < "$BASE_DIR/.mvn/wrapper/maven-wrapper.properties"
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Downloading from: $jarUrl"
|
||||
fi
|
||||
wrapperJarPath="$BASE_DIR/.mvn/wrapper/maven-wrapper.jar"
|
||||
if $cygwin; then
|
||||
wrapperJarPath=`cygpath --path --windows "$wrapperJarPath"`
|
||||
fi
|
||||
|
||||
if command -v wget > /dev/null; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found wget ... using wget"
|
||||
fi
|
||||
if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
|
||||
wget "$jarUrl" -O "$wrapperJarPath"
|
||||
else
|
||||
wget --http-user=$MVNW_USERNAME --http-password=$MVNW_PASSWORD "$jarUrl" -O "$wrapperJarPath"
|
||||
fi
|
||||
elif command -v curl > /dev/null; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Found curl ... using curl"
|
||||
fi
|
||||
if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then
|
||||
curl -o "$wrapperJarPath" "$jarUrl" -f
|
||||
else
|
||||
curl --user $MVNW_USERNAME:$MVNW_PASSWORD -o "$wrapperJarPath" "$jarUrl" -f
|
||||
fi
|
||||
|
||||
else
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo "Falling back to using Java to download"
|
||||
fi
|
||||
javaClass="$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.java"
|
||||
# For Cygwin, switch paths to Windows format before running javac
|
||||
if $cygwin; then
|
||||
javaClass=`cygpath --path --windows "$javaClass"`
|
||||
fi
|
||||
if [ -e "$javaClass" ]; then
|
||||
if [ ! -e "$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.class" ]; then
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo " - Compiling MavenWrapperDownloader.java ..."
|
||||
fi
|
||||
# Compiling the Java class
|
||||
("$JAVA_HOME/bin/javac" "$javaClass")
|
||||
fi
|
||||
if [ -e "$BASE_DIR/.mvn/wrapper/MavenWrapperDownloader.class" ]; then
|
||||
# Running the downloader
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo " - Running MavenWrapperDownloader.java ..."
|
||||
fi
|
||||
("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$MAVEN_PROJECTBASEDIR")
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
##########################################################################################
|
||||
# End of extension
|
||||
##########################################################################################
|
||||
|
||||
export MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}
|
||||
if [ "$MVNW_VERBOSE" = true ]; then
|
||||
echo $MAVEN_PROJECTBASEDIR
|
||||
fi
|
||||
MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS"
|
||||
|
||||
# For Cygwin, switch paths to Windows format before running java
|
||||
if $cygwin; then
|
||||
[ -n "$M2_HOME" ] &&
|
||||
M2_HOME=`cygpath --path --windows "$M2_HOME"`
|
||||
[ -n "$JAVA_HOME" ] &&
|
||||
JAVA_HOME=`cygpath --path --windows "$JAVA_HOME"`
|
||||
[ -n "$CLASSPATH" ] &&
|
||||
CLASSPATH=`cygpath --path --windows "$CLASSPATH"`
|
||||
[ -n "$MAVEN_PROJECTBASEDIR" ] &&
|
||||
MAVEN_PROJECTBASEDIR=`cygpath --path --windows "$MAVEN_PROJECTBASEDIR"`
|
||||
fi
|
||||
|
||||
# Provide a "standardized" way to retrieve the CLI args that will
|
||||
# work with both Windows and non-Windows executions.
|
||||
MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $@"
|
||||
export MAVEN_CMD_LINE_ARGS
|
||||
|
||||
WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
|
||||
|
||||
exec "$JAVACMD" \
|
||||
$MAVEN_OPTS \
|
||||
-classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \
|
||||
"-Dmaven.home=${M2_HOME}" "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \
|
||||
${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@"
|
@ -0,0 +1,182 @@
|
||||
@REM ----------------------------------------------------------------------------
|
||||
@REM Licensed to the Apache Software Foundation (ASF) under one
|
||||
@REM or more contributor license agreements. See the NOTICE file
|
||||
@REM distributed with this work for additional information
|
||||
@REM regarding copyright ownership. The ASF licenses this file
|
||||
@REM to you under the Apache License, Version 2.0 (the
|
||||
@REM "License"); you may not use this file except in compliance
|
||||
@REM with the License. You may obtain a copy of the License at
|
||||
@REM
|
||||
@REM https://www.apache.org/licenses/LICENSE-2.0
|
||||
@REM
|
||||
@REM Unless required by applicable law or agreed to in writing,
|
||||
@REM software distributed under the License is distributed on an
|
||||
@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
@REM KIND, either express or implied. See the License for the
|
||||
@REM specific language governing permissions and limitations
|
||||
@REM under the License.
|
||||
@REM ----------------------------------------------------------------------------
|
||||
|
||||
@REM ----------------------------------------------------------------------------
|
||||
@REM Maven2 Start Up Batch script
|
||||
@REM
|
||||
@REM Required ENV vars:
|
||||
@REM JAVA_HOME - location of a JDK home dir
|
||||
@REM
|
||||
@REM Optional ENV vars
|
||||
@REM M2_HOME - location of maven2's installed home dir
|
||||
@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands
|
||||
@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a key stroke before ending
|
||||
@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven
|
||||
@REM e.g. to debug Maven itself, use
|
||||
@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
|
||||
@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files
|
||||
@REM ----------------------------------------------------------------------------
|
||||
|
||||
@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on'
|
||||
@echo off
|
||||
@REM set title of command window
|
||||
title %0
|
||||
@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on'
|
||||
@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO%
|
||||
|
||||
@REM set %HOME% to equivalent of $HOME
|
||||
if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%")
|
||||
|
||||
@REM Execute a user defined script before this one
|
||||
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre
|
||||
@REM check for pre script, once with legacy .bat ending and once with .cmd ending
|
||||
if exist "%HOME%\mavenrc_pre.bat" call "%HOME%\mavenrc_pre.bat"
|
||||
if exist "%HOME%\mavenrc_pre.cmd" call "%HOME%\mavenrc_pre.cmd"
|
||||
:skipRcPre
|
||||
|
||||
@setlocal
|
||||
|
||||
set ERROR_CODE=0
|
||||
|
||||
@REM To isolate internal variables from possible post scripts, we use another setlocal
|
||||
@setlocal
|
||||
|
||||
@REM ==== START VALIDATION ====
|
||||
if not "%JAVA_HOME%" == "" goto OkJHome
|
||||
|
||||
echo.
|
||||
echo Error: JAVA_HOME not found in your environment. >&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the >&2
|
||||
echo location of your Java installation. >&2
|
||||
echo.
|
||||
goto error
|
||||
|
||||
:OkJHome
|
||||
if exist "%JAVA_HOME%\bin\java.exe" goto init
|
||||
|
||||
echo.
|
||||
echo Error: JAVA_HOME is set to an invalid directory. >&2
|
||||
echo JAVA_HOME = "%JAVA_HOME%" >&2
|
||||
echo Please set the JAVA_HOME variable in your environment to match the >&2
|
||||
echo location of your Java installation. >&2
|
||||
echo.
|
||||
goto error
|
||||
|
||||
@REM ==== END VALIDATION ====
|
||||
|
||||
:init
|
||||
|
||||
@REM Find the project base dir, i.e. the directory that contains the folder ".mvn".
|
||||
@REM Fallback to current working directory if not found.
|
||||
|
||||
set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR%
|
||||
IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir
|
||||
|
||||
set EXEC_DIR=%CD%
|
||||
set WDIR=%EXEC_DIR%
|
||||
:findBaseDir
|
||||
IF EXIST "%WDIR%"\.mvn goto baseDirFound
|
||||
cd ..
|
||||
IF "%WDIR%"=="%CD%" goto baseDirNotFound
|
||||
set WDIR=%CD%
|
||||
goto findBaseDir
|
||||
|
||||
:baseDirFound
|
||||
set MAVEN_PROJECTBASEDIR=%WDIR%
|
||||
cd "%EXEC_DIR%"
|
||||
goto endDetectBaseDir
|
||||
|
||||
:baseDirNotFound
|
||||
set MAVEN_PROJECTBASEDIR=%EXEC_DIR%
|
||||
cd "%EXEC_DIR%"
|
||||
|
||||
:endDetectBaseDir
|
||||
|
||||
IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig
|
||||
|
||||
@setlocal EnableExtensions EnableDelayedExpansion
|
||||
for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a
|
||||
@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS%
|
||||
|
||||
:endReadAdditionalConfig
|
||||
|
||||
SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
|
||||
set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
|
||||
set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
|
||||
|
||||
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
|
||||
|
||||
FOR /F "tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO (
|
||||
IF "%%A"=="wrapperUrl" SET DOWNLOAD_URL=%%B
|
||||
)
|
||||
|
||||
@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
|
||||
@REM This allows using the maven wrapper in projects that prohibit checking in binary data.
|
||||
if exist %WRAPPER_JAR% (
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Found %WRAPPER_JAR%
|
||||
)
|
||||
) else (
|
||||
if not "%MVNW_REPOURL%" == "" (
|
||||
SET DOWNLOAD_URL="%MVNW_REPOURL%/io/takari/maven-wrapper/0.5.5/maven-wrapper-0.5.5.jar"
|
||||
)
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Couldn't find %WRAPPER_JAR%, downloading it ...
|
||||
echo Downloading from: %DOWNLOAD_URL%
|
||||
)
|
||||
|
||||
powershell -Command "&{"^
|
||||
"$webclient = new-object System.Net.WebClient;"^
|
||||
"if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^
|
||||
"$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^
|
||||
"}"^
|
||||
"[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%DOWNLOAD_URL%', '%WRAPPER_JAR%')"^
|
||||
"}"
|
||||
if "%MVNW_VERBOSE%" == "true" (
|
||||
echo Finished downloading %WRAPPER_JAR%
|
||||
)
|
||||
)
|
||||
@REM End of extension
|
||||
|
||||
@REM Provide a "standardized" way to retrieve the CLI args that will
|
||||
@REM work with both Windows and non-Windows executions.
|
||||
set MAVEN_CMD_LINE_ARGS=%*
|
||||
|
||||
%MAVEN_JAVA_EXE% %JVM_CONFIG_MAVEN_PROPS% %MAVEN_OPTS% %MAVEN_DEBUG_OPTS% -classpath %WRAPPER_JAR% "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
|
||||
if ERRORLEVEL 1 goto error
|
||||
goto end
|
||||
|
||||
:error
|
||||
set ERROR_CODE=1
|
||||
|
||||
:end
|
||||
@endlocal & set ERROR_CODE=%ERROR_CODE%
|
||||
|
||||
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPost
|
||||
@REM check for post script, once with legacy .bat ending and once with .cmd ending
|
||||
if exist "%HOME%\mavenrc_post.bat" call "%HOME%\mavenrc_post.bat"
|
||||
if exist "%HOME%\mavenrc_post.cmd" call "%HOME%\mavenrc_post.cmd"
|
||||
:skipRcPost
|
||||
|
||||
@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on'
|
||||
if "%MAVEN_BATCH_PAUSE%" == "on" pause
|
||||
|
||||
if "%MAVEN_TERMINATE_CMD%" == "on" exit %ERROR_CODE%
|
||||
|
||||
exit /B %ERROR_CODE%
|
@ -0,0 +1,15 @@
|
||||
package com.yeqifu;
|
||||
|
||||
import org.mybatis.spring.annotation.MapperScan;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
|
||||
@SpringBootApplication
|
||||
@MapperScan(basePackages = {"com.yeqifu.sys.mapper"})
|
||||
public class WarehouseApplication {
|
||||
|
||||
public static void main(String[] args) {
|
||||
SpringApplication.run(WarehouseApplication.class, args);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package com.yeqifu.sys.common;
|
||||
|
||||
import com.yeqifu.sys.entity.User;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author: 落亦-
|
||||
* @Date: 2019/11/21 20:41
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class ActiverUser {
|
||||
|
||||
private User user;
|
||||
|
||||
private List<String> roles;
|
||||
|
||||
private List<String> permission;
|
||||
|
||||
}
|
@ -0,0 +1,15 @@
|
||||
package com.yeqifu.sys.common;
|
||||
|
||||
/**
|
||||
* @Author: 落亦-
|
||||
* @Date: 2019/11/21 21:39
|
||||
*/
|
||||
public class Constast {
|
||||
|
||||
/**
|
||||
* 状态码
|
||||
*/
|
||||
public static final Integer OK=200;
|
||||
public static final Integer ERROR=-1;
|
||||
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
package com.yeqifu.sys.common;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @Author: 落亦-
|
||||
* @Date: 2019/11/21 21:35
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class ResultObj {
|
||||
|
||||
public static final ResultObj LOGIN_SUCCESS=new ResultObj(Constast.OK,"登陆成功");
|
||||
public static final ResultObj LOGIN_ERROR_PASS=new ResultObj(Constast.ERROR,"用户名或密码错误");
|
||||
public static final ResultObj LOGIN_ERROR_CODE=new ResultObj(Constast.ERROR,"验证码错误");
|
||||
|
||||
private Integer code;
|
||||
private String msg;
|
||||
|
||||
}
|
@ -0,0 +1,33 @@
|
||||
package com.yeqifu.sys.common;
|
||||
|
||||
import org.springframework.web.context.request.RequestContextHolder;
|
||||
import org.springframework.web.context.request.ServletRequestAttributes;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpSession;
|
||||
|
||||
/**
|
||||
* @Author: 落亦-
|
||||
* @Date: 2019/11/21 21:43
|
||||
*/
|
||||
public class WebUtils {
|
||||
|
||||
/**
|
||||
* 得到request
|
||||
* @return
|
||||
*/
|
||||
public static HttpServletRequest getRequest(){
|
||||
ServletRequestAttributes requestAttributes = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
|
||||
HttpServletRequest request = requestAttributes.getRequest();
|
||||
return request;
|
||||
}
|
||||
|
||||
/**
|
||||
* 得到session
|
||||
* @return
|
||||
*/
|
||||
public static HttpSession getSession(){
|
||||
return getRequest().getSession();
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,41 @@
|
||||
package com.yeqifu.sys.controller;
|
||||
|
||||
import com.yeqifu.sys.common.ActiverUser;
|
||||
import com.yeqifu.sys.common.ResultObj;
|
||||
import com.yeqifu.sys.common.WebUtils;
|
||||
import org.apache.shiro.SecurityUtils;
|
||||
import org.apache.shiro.authc.AuthenticationException;
|
||||
import org.apache.shiro.authc.AuthenticationToken;
|
||||
import org.apache.shiro.authc.UsernamePasswordToken;
|
||||
import org.apache.shiro.subject.Subject;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* 登陆前端控制器
|
||||
* @Author: 落亦-
|
||||
* @Date: 2019/11/21 21:33
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("login")
|
||||
public class LoginController {
|
||||
|
||||
@RequestMapping("login")
|
||||
public ResultObj login(String loginname, String pwd){
|
||||
|
||||
Subject subject = SecurityUtils.getSubject();
|
||||
AuthenticationToken token = new UsernamePasswordToken(loginname,pwd);
|
||||
try {
|
||||
subject.login(token);
|
||||
ActiverUser activerUser = (ActiverUser) subject.getPrincipal();
|
||||
WebUtils.getSession().setAttribute("user",activerUser.getUser());
|
||||
|
||||
return ResultObj.LOGIN_SUCCESS;
|
||||
} catch (AuthenticationException e) {
|
||||
e.printStackTrace();
|
||||
return ResultObj.LOGIN_ERROR_PASS;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,33 @@
|
||||
package com.yeqifu.sys.controller;
|
||||
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
/**
|
||||
* 系统进行跳转的路由
|
||||
* @Author: 落亦-
|
||||
* @Date: 2019/11/21 21:19
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("sys")
|
||||
public class SystemController {
|
||||
|
||||
/**
|
||||
* 跳转到登陆页面
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping("toLogin")
|
||||
public String toLogin(){
|
||||
return "system/index/login";
|
||||
}
|
||||
|
||||
/**
|
||||
* 跳转到首页
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping("index")
|
||||
public String index(){
|
||||
return "system/index/index";
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
package com.yeqifu.sys.controller;
|
||||
|
||||
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* InnoDB free: 9216 kB; (`deptid`) REFER `warehouse/sys_dept`(`id`) ON UPDATE CASC 前端控制器
|
||||
* </p>
|
||||
*
|
||||
* @author luoyi-
|
||||
* @since 2019-11-21
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/sys/user")
|
||||
public class UserController {
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,16 @@
|
||||
package com.yeqifu.sys.mapper;
|
||||
|
||||
import com.yeqifu.sys.entity.User;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* InnoDB free: 9216 kB; (`deptid`) REFER `warehouse/sys_dept`(`id`) ON UPDATE CASC Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author luoyi-
|
||||
* @since 2019-11-21
|
||||
*/
|
||||
public interface UserMapper extends BaseMapper<User> {
|
||||
|
||||
}
|
@ -0,0 +1,62 @@
|
||||
package com.yeqifu.sys.realm;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.yeqifu.sys.common.ActiverUser;
|
||||
import com.yeqifu.sys.entity.User;
|
||||
import com.yeqifu.sys.service.IUserService;
|
||||
import org.apache.shiro.authc.AuthenticationException;
|
||||
import org.apache.shiro.authc.AuthenticationInfo;
|
||||
import org.apache.shiro.authc.AuthenticationToken;
|
||||
import org.apache.shiro.authc.SimpleAuthenticationInfo;
|
||||
import org.apache.shiro.authz.AuthorizationInfo;
|
||||
import org.apache.shiro.realm.AuthorizingRealm;
|
||||
import org.apache.shiro.subject.PrincipalCollection;
|
||||
import org.apache.shiro.util.ByteSource;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
/**
|
||||
* @Author: 落亦-
|
||||
* @Date: 2019/11/21 20:44
|
||||
*/
|
||||
public class UserRealm extends AuthorizingRealm {
|
||||
|
||||
@Autowired
|
||||
private IUserService userService;
|
||||
|
||||
@Override
|
||||
public String getName(){
|
||||
return this.getClass().getSimpleName();
|
||||
}
|
||||
|
||||
/**
|
||||
* 授权
|
||||
* @param principalCollection
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principalCollection) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 认证
|
||||
* @param authenticationToken
|
||||
* @return
|
||||
* @throws AuthenticationException
|
||||
*/
|
||||
@Override
|
||||
protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken authenticationToken) throws AuthenticationException {
|
||||
|
||||
QueryWrapper<User> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.eq("loginname",authenticationToken.getPrincipal().toString());
|
||||
User user = userService.getOne(queryWrapper);
|
||||
if (null!=user){
|
||||
ActiverUser activerUser = new ActiverUser();
|
||||
activerUser.setUser(user);
|
||||
ByteSource credentialsSalt=ByteSource.Util.bytes(user.getSalt());
|
||||
SimpleAuthenticationInfo info = new SimpleAuthenticationInfo(activerUser,user.getPwd(),credentialsSalt,this.getName());
|
||||
return info;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.yeqifu.sys.service;
|
||||
|
||||
import com.yeqifu.sys.entity.User;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* InnoDB free: 9216 kB; (`deptid`) REFER `warehouse/sys_dept`(`id`) ON UPDATE CASC 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author luoyi-
|
||||
* @since 2019-11-21
|
||||
*/
|
||||
public interface IUserService extends IService<User> {
|
||||
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.yeqifu.sys.service.impl;
|
||||
|
||||
import com.yeqifu.sys.entity.User;
|
||||
import com.yeqifu.sys.mapper.UserMapper;
|
||||
import com.yeqifu.sys.service.IUserService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* InnoDB free: 9216 kB; (`deptid`) REFER `warehouse/sys_dept`(`id`) ON UPDATE CASC 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author luoyi-
|
||||
* @since 2019-11-21
|
||||
*/
|
||||
@Service
|
||||
public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements IUserService {
|
||||
|
||||
}
|
@ -0,0 +1 @@
|
||||
|
@ -0,0 +1,56 @@
|
||||
|
||||
#配置数据源
|
||||
spring:
|
||||
datasource:
|
||||
druid:
|
||||
driver-class-name: com.mysql.jdbc.Driver
|
||||
url: jdbc:mysql://127.0.0.1:3306/warehouse?useUnicode=true&characterEncoding=utf8
|
||||
username: root
|
||||
password: 123456
|
||||
max-active: 20
|
||||
max-wait: 5000
|
||||
initial-size: 1
|
||||
filters: stat,log4j,wall
|
||||
validation-query: SELECT 'X' #验证连接
|
||||
enable: true
|
||||
#监控配置
|
||||
stat-view-servlet:
|
||||
enabled: true
|
||||
login-username: root
|
||||
login-password: 123456
|
||||
url-pattern: /druid/*
|
||||
|
||||
#thymeleaf的配置
|
||||
thymeleaf:
|
||||
cache: false
|
||||
enabled: true
|
||||
|
||||
jackson:
|
||||
date-format: yyyy-MM-dd HH:mm:ss
|
||||
|
||||
#配置mybatisplus
|
||||
mybatis-plus:
|
||||
mapper-locations:
|
||||
-classpath: mapper/*/*Mapper.xml
|
||||
global-config:
|
||||
db-config:
|
||||
id-type: auto
|
||||
configuration:
|
||||
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||||
|
||||
#shiro的配置
|
||||
shiro:
|
||||
hash-algorithm-name: md5
|
||||
hash-iterations: 2
|
||||
anon-urls:
|
||||
- /index.html*
|
||||
- /sys/toLogin*
|
||||
- /login/login*
|
||||
- /resources/**
|
||||
login-url: /index.html
|
||||
log-out-url: /login/logout*
|
||||
authc-ulrs:
|
||||
- /**
|
||||
|
||||
server:
|
||||
port: 8088
|
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yeqifu.sys.mapper.UserMapper">
|
||||
|
||||
</mapper>
|
@ -0,0 +1,12 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Title</title>
|
||||
</head>
|
||||
<body>
|
||||
<script type="text/javascript">
|
||||
window.location.href="/sys/toLogin";
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,20 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2018 Admin
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
@ -0,0 +1,158 @@
|
||||
/*公共样式*/
|
||||
.header .layui-nav-child{ z-index:99999; top:60px; left: auto; right: 0;}
|
||||
.seraph{ font-size:16px !important;}
|
||||
.main_body{ min-width:320px; }
|
||||
.layui-nav .layui-nav-item a{ cursor:pointer;}
|
||||
.layui-nav .layui-nav-item>a{ color:rgba(255,255,255,1); max-height:60px;}
|
||||
.layui-layer-tab .layui-layer-title span{ padding:0 !important;}
|
||||
iframe{ position:absolute; height:100%; width:100%; border:none;}
|
||||
.top_menu.layui-nav .layui-nav-child dd.layui-this a,.closeBox.layui-nav .layui-nav-child dd.layui-this a,.closeBox .layui-nav-child dd.layui-this,.top_menu .layui-nav-child dd.layui-this{ background:none; color:#333;}
|
||||
.layui-nav .layui-nav-child a:hover,.layui-nav .layui-nav-child dd.layui-this a:hover{background-color:#5FB878;color:#fff;}
|
||||
|
||||
/*模拟加载层图标样式*/
|
||||
.layui-layer-dialog .layui-layer-content .layui-layer-ico16{ background-size:100% 100% !important; }
|
||||
/*样式改变的过渡*/
|
||||
.layui-body,.layui-footer,.layui-layout-admin .layui-side,.logo,.topLevelMenus li.layui-nav-item,.topLevelMenus li.layui-nav-item:hover{ transition: all 0.3s ease-in-out;-webkit-transition: all 0.3s ease-in-out;-o-transition: all 0.3s ease-in-out;-moz-transition: all 0.3s ease-in-out;-ms-transition: all 0.3s ease-in-out; }
|
||||
/*隐藏*/
|
||||
*[mobile],.component .layui-select-title i.layui-edge{ display:none;}
|
||||
|
||||
/*打开页面动画*/
|
||||
.layui-tab-item.layui-show{ animation:moveTop 1s; -webkit-animation:moveTop 1s; animation-fill-mode:both; -webkit-animation-fill-mode:both; position:relative; height:100%; -webkit-overflow-scrolling: touch; overflow:auto; }
|
||||
@keyframes moveTop{
|
||||
0% {opacity: 0;-webkit-transform: translateY(20px);-ms-transform: translateY(20px);transform: translateY(20px);}
|
||||
100% {opacity: 1;-webkit-transform: translateY(0);-ms-transform: translateY(0);transform: translateY(0);}
|
||||
}
|
||||
@-o-keyframes moveTop{
|
||||
0% {opacity: 0;-webkit-transform: translateY(20px);-ms-transform: translateY(20px);transform: translateY(20px);}
|
||||
100% {opacity: 1;-webkit-transform: translateY(0);-ms-transform: translateY(0);transform: translateY(0);}
|
||||
}
|
||||
@-moz-keyframes moveTop{
|
||||
0% {opacity: 0;-webkit-transform: translateY(20px);-ms-transform: translateY(20px);transform: translateY(20px);}
|
||||
100% {opacity: 1;-webkit-transform: translateY(0);-ms-transform: translateY(0);transform: translateY(0);}
|
||||
}
|
||||
@-webkit-keyframes moveTop{
|
||||
0% {opacity: 0;-webkit-transform: translateY(20px);-ms-transform: translateY(20px);transform: translateY(20px);}
|
||||
100% {opacity: 1;-webkit-transform: translateY(0);-ms-transform: translateY(0);transform: translateY(0);}
|
||||
}
|
||||
/*锁屏*/
|
||||
.admin-header-lock{width: 320px; height: 170px; padding: 20px; position: relative; text-align: center;}
|
||||
.admin-header-lock-img{width:70px; height:70px; margin: 0 auto;}
|
||||
.admin-header-lock-img img{width:70px; height:70px; border-radius: 100%; box-shadow:0 0 30px #44576b;}
|
||||
.admin-header-lock-name{color: #009688;margin: 8px 0 15px 0;}
|
||||
.input_btn{ overflow: hidden; margin-bottom: 10px; }
|
||||
.admin-header-lock-input{width: 170px; color: #fff;background-color: #009688; float: left; margin:0 10px 0 40px; border:none;}
|
||||
.admin-header-lock-input::-webkit-input-placeholder {color:#fff;}
|
||||
.admin-header-lock-input::-moz-placeholder {color:#fff;}
|
||||
.admin-header-lock-input:-ms-input-placeholder {color:#fff;}
|
||||
.admin-header-lock-input:-moz-placeholder {color:#fff;}
|
||||
#unlock{ float: left; }
|
||||
#lock-box p{ color:#e60000; }
|
||||
/*顶部*/
|
||||
.header{ z-index:2000;}
|
||||
.logo{ color: #fff; float: left; line-height:60px; font-size:20px; padding:0 25px; text-align: center; width:150px;}
|
||||
.hideMenu{ float:left; width:20px; height:20px; margin-top:15px; font-size:17px; line-height:20px; text-align:center; padding:5px 5px; color:#fff; background-color:#1AA094; }
|
||||
.hideMenu:hover{ color:#fff; }
|
||||
.layui-nav cite{ margin-left: 5px;}
|
||||
/*顶部右侧*/
|
||||
.topLevelMenus{float:left;}
|
||||
.topLevelMenus li.layui-nav-item:hover{ background-color:rgba(221,221,221,0.2);}
|
||||
.layui-nav .layui-this:after{ bottom:-5px!important;}
|
||||
.header .layui-nav-bar{top:60px !important;}
|
||||
.topLevelMenus .layui-nav-item.layui-this{ background-color:rgba(0,0,0,0.5);}
|
||||
.top_menu.layui-nav .layui-this:after{ width:0px; }
|
||||
.top_menu .layui-nav-bar,.mobileTopLevelMenus .layui-nav-bar{background-color:rgba(0,0,0,0.7);}
|
||||
|
||||
/*左侧导航*/
|
||||
.layui-nav{background-color: inherit !important;}
|
||||
.showMenu.layui-layout-admin .layui-side{ left:-200px; }
|
||||
.showMenu .layui-body,.showMenu .layui-footer{ left:0; }
|
||||
/*左侧用户头像*/
|
||||
.top_menu{ background-color:inherit !important; position:absolute; right:0;top:0; }
|
||||
.layui-layout-admin .layui-side{ left:0; overflow:hidden;}
|
||||
.user-photo{width: 200px; height: 120px; padding:15px 0 5px;}
|
||||
.user-photo a.img{ display: block; width:80px; height:80px; margin: 0 auto 10px;}
|
||||
.user-photo a.img img{ display: block; border: none; width: 100%; height: 100%; border-radius: 50%; -webkit-border-radius: 50%; -moz-border-radius: 50%; border: 4px solid #44576b; box-sizing:border-box;}
|
||||
.user-photo p{ display: block; width: 100%; height: 25px; color: #ffffff; text-align: center; font-size: 12px; white-space: nowrap;line-height: 25px; overflow: hidden;}
|
||||
/*左侧导航重定义*/
|
||||
.layui-nav-item.layui-nav-itemed{ background-color:#2B2E37 !important;}
|
||||
.layui-nav-itemed:before{ width:5px; height:100%; background-color:#009688; position:absolute; content:''; left:0; top:0;}
|
||||
.layui-nav-itemed .layui-nav-child a{ padding-left:40px;}
|
||||
/*左侧搜索框*/
|
||||
.component{ width:180px; height:30px; margin:0 auto 5px; position:relative;}
|
||||
.component .layui-input{ height:30px; line-height: 30px; font-size:12px; border:none; transition: all 0.3s; background:rgba(255,255,255,0.05); }
|
||||
.component .layui-input:focus{ background:#fff; color:#000; }
|
||||
.component .layui-form-select dl{ top:33px; background:#fff; }
|
||||
.component .layui-icon{ position: absolute; right:8px; top:8px; color:#000; }
|
||||
.component dl dd{ color:#000 !important;}
|
||||
.component dl dd.layui-this{ color:#fff !important;}
|
||||
.component dl dd.layui-select-tips{ color:#999 !important;}
|
||||
|
||||
/*layui-body*/
|
||||
.layui-body{overflow:hidden; border-top:5px solid #1AA094;border-left:2px solid #1AA094; background:#fff;}
|
||||
#top_tabs_box{ padding-right:138px; height:40px; border-bottom:1px solid #e2e2e2; }
|
||||
#top_tabs{ position: absolute; border-bottom:none;}
|
||||
.layui-tab-title .layui-this{ background-color:#1AA094; color:#fff; }
|
||||
.layui-tab-title .layui-this:after{ border:none; }
|
||||
.layui-tab-title li cite{ font-style: normal; padding-left:5px; }
|
||||
.clildFrame.layui-tab-content{ top:41px; position:absolute; bottom:0; width:100%; padding:0;}
|
||||
/*多窗口页面操作下拉*/
|
||||
.closeBox{ position:absolute; right:0; background-color:#fff !important; color:#000; border-left:1px solid #e2e2e2; border-bottom:1px solid #e2e2e2; }
|
||||
.closeBox .layui-nav-item{ line-height:40px; }
|
||||
.closeBox .layui-nav-item>a,.closeBox .layui-nav-item>a:hover{ color:#000; }
|
||||
.closeBox .layui-nav-child{ top:42px; left:-12px; }
|
||||
.closeBox .layui-nav-bar{ display:none; }
|
||||
.closeBox a i.caozuo{ font-size: 20px; position:absolute; top:1px; left:0; }
|
||||
.closeBox a span.layui-nav-more{ border-color:#333 transparent transparent;}
|
||||
.closeBox a span.layui-nav-more.layui-nav-mored{ border-color:transparent transparent #333;}
|
||||
/*功能设定*/
|
||||
.functionSrtting_box{ padding-top:15px;}
|
||||
.functionSrtting_box .layui-form-label{ width:81px;}
|
||||
.functionSrtting_box .layui-word-aux{ position:absolute;left:60px; top:9px; font-size: 12px;}
|
||||
/*换肤*/
|
||||
.skins_box{ padding:10px 34px 0; }
|
||||
.skinBtn{ text-align:center; }
|
||||
/*橙色*/
|
||||
.orange .layui-layout-admin .layui-header{ background-color:orange !important; }
|
||||
.orange .layui-bg-black{ background-color:#e47214 !important; }
|
||||
/*蓝色*/
|
||||
.blue .layui-layout-admin .layui-header{ background-color:#3396d8 !important; }
|
||||
.blue .layui-bg-black,.blue .hideMenu{ background-color:#146aa2 !important; }
|
||||
/*自定义*/
|
||||
.skinCustom{ visibility:hidden; }
|
||||
.skinCustom input{ width:48%; margin:5px 2% 5px 0; float:left; }
|
||||
.orange .layui-nav-tree .layui-nav-child a,.blue .layui-nav-tree .layui-nav-child a{ color:#fff; }
|
||||
.orange .top_menu.layui-nav .layui-nav-more,.blue .top_menu.layui-nav .layui-nav-more{border-color:#fff transparent transparent !important;}
|
||||
.orange .top_menu.layui-nav-itemed .layui-nav-more,.orange .top_menu.layui-nav .layui-nav-mored,.blue .top_menu.layui-nav-itemed .layui-nav-more,.blue .top_menu.layui-nav .layui-nav-mored{border-color:transparent transparent #fff !important;}
|
||||
/*底部*/
|
||||
.footer{ text-align: center; line-height:44px;border-left: 2px solid #1AA094; z-index:999;}
|
||||
|
||||
/*响应式样式*/
|
||||
@media screen and (max-width:1080px){
|
||||
.mobileTopLevelMenus[mobile]{display:inline-block;}
|
||||
.site-mobile .site-tree-mobile,.topLevelMenus[pc]{display:none !important;}
|
||||
}
|
||||
@media screen and (max-width: 720px){
|
||||
.hideMenu{ display: none !important; }
|
||||
.mobileTopLevelMenus[mobile]{ padding:0;}
|
||||
.top_menu>li[pc]{ display: none !important; }
|
||||
/*左侧导航*/
|
||||
.layui-layout-admin .layui-side{ left:-260px; }
|
||||
.site-mobile .layui-side{ left: 0; z-index:1100; }
|
||||
.site-tree-mobile {display: block!important; position: fixed; z-index: 100000; bottom: 15px; left: 15px; width:40px; height:40px; line-height:40px; border-radius: 2px; text-align: center; background-color: rgba(0,0,0,.7); color: #fff;}
|
||||
.site-mobile .site-mobile-shade { content: ''; position: fixed; top: 0; bottom: 0; left: 0; right: 0; background-color: rgba(0,0,0,.8); z-index: 999;}
|
||||
.layui-body,.layui-layout-admin .layui-footer{ left:-2px; }
|
||||
}
|
||||
@media screen and (max-width:480px){
|
||||
.logo{ width:120px; font-size: 18px;}
|
||||
#userInfo>a{ padding:0 10px;}
|
||||
.mobileTopLevelMenus[mobile] li>a{ padding:0 17px 0 15px;}
|
||||
.logo,.layui-nav.top_menu{ padding:0 5px;}
|
||||
.adminName,.top_menu dd[pc]{ display: none !important; }
|
||||
*[mobile],.top_menu .layui-nav-item.showNotice[pc]{ display:inline-block !important; }
|
||||
}
|
||||
|
||||
/*修改顶部高度*/
|
||||
.header .layui-nav-child,.layui-body,.layui-layout-admin .layui-side,.header .layui-nav-bar{ top:50px !important;}
|
||||
.header .layui-nav .layui-nav-item,.header .layui-nav .layui-nav-item>a,.header,.logo{ line-height:50px !important; max-height:50px; !important;}
|
||||
.mobileTopLevelMenus{ float:left;}
|
||||
.hideMenu{ margin-top: 10px;}
|
@ -0,0 +1,171 @@
|
||||
/*公共样式*/
|
||||
.childrenBody{ padding:10px;}
|
||||
.layui-table-view{ margin:0 !important;}
|
||||
.magb0{margin-bottom:0 !important;}
|
||||
.magt0{ margin-top:0 !important;}
|
||||
.magt3{ margin-top:3px !important;}
|
||||
.magt10{ margin-top:10px !important;}
|
||||
.magb15{ margin-bottom:15px !important;}
|
||||
.magt30{ margin-top:30px !important;}
|
||||
.layui-left{text-align:left;}
|
||||
.layui-block{ width:100% !important;}
|
||||
.layui-center{text-align:center;}
|
||||
.layui-right{text-align:right;}
|
||||
.layui-elem-quote.title{ padding:10px 15px; margin-bottom:0;}
|
||||
.layui-bg-white{ background-color:#fff !important;}
|
||||
.border{ border:1px solid #e6e6e6 !important; padding:10px; border-top:none;}
|
||||
.main_btn .layui-btn{ margin:2px 5px 2px 0;}
|
||||
.layui-timeline-axis{ left:-4px;}
|
||||
.layui-elem-quote{ word-break: break-all;}
|
||||
.icons li,.icons li:hover,.loginBody .seraph,.loginBody .seraph:hover,.loginBody .layui-form-item.layui-input-focus label,.loginBody .layui-form-item label,.loginBody .layui-form-item.layui-input-focus input,.loginBody .layui-form-item input{transition: all 0.3s ease-in-out;-webkit-transition: all 0.3s ease-in-out;}
|
||||
.icons li:hover i,.icons li i{transition: font-size 0.3s ease-in-out;-webkit-transition: font-size 0.3s ease-in-out;}
|
||||
.loginBody .layui-input-focus .layui-input::-webkit-input-placeholder{transition: color 0.2s linear 0.2s;-webkit-transition: color 0.2s linear 0.2s;}
|
||||
.loginBody .layui-input-focus .layui-input::-moz-placeholder{transition: color 0.2s linear 0.2s;}
|
||||
.loginBody .layui-input-focus .layui-input:-ms-input-placeholder{transition: color 0.2s linear 0.2s;}
|
||||
.loginBody .layui-input-focus .layui-input::placeholder{transition: color 0.2s linear 0.2s;-webkit-transition: color 0.2s linear 0.2s;}
|
||||
/*后台首页*/
|
||||
.panel_box{ margin-bottom:5px;}
|
||||
.panel{ text-align:center; height:90px;}
|
||||
.panel_box a{display:block; border-radius:5px; overflow:hidden; height:80px; background-color:#f2f2f2 !important; }
|
||||
.panel_icon{ width:40%; display: inline-block; line-height:80px; float:left; position:relative; height:100%;}
|
||||
.panel_icon i{ font-size:40px !important; color:#fff; display: inline-block;}
|
||||
.panel_word{ width:60%; display: inline-block; float:right; margin:13px 0 14px; }
|
||||
.panel_word span{ font-size:25px; display:block; height:34px; }
|
||||
.panel .loginTime{ font-size:15px; color:#1E9FFF; line-height:17px;}
|
||||
.panel em{ font-style:normal;}
|
||||
.history_box{ min-height:500px; height:500px; overflow-y:scroll; padding:10px !important;}
|
||||
.history_box .layui-timeline .layui-timeline-item:last-child{ padding-bottom:0;}
|
||||
@media screen and (max-width:1200px) {
|
||||
.history_box { height: auto !important; overflow-y: inherit; }
|
||||
}
|
||||
/*修改密码*/
|
||||
.pwdTips{ min-height:auto; margin:40px 0 15px 110px;}
|
||||
/*个人资料*/
|
||||
form input.layui-input[disabled]{ background:#f2f2f2; color:#595963!important; }
|
||||
.user_right{ text-align: center; }
|
||||
.user_right p{ margin:10px 0 25px; font-size: 12px; text-align: center; color: #FF5722;}
|
||||
.user_right img#userFace{ width:200px; height:200px; margin-top:20px; cursor:pointer; box-shadow:0 0 50px #44576b; }
|
||||
.userAddress.layui-form-item .layui-input-inline{ width:23%; }
|
||||
.userAddress.layui-form-item .layui-input-inline:last-child{ margin-right:0; }
|
||||
/*下拉多选*/
|
||||
.layui-form-item select[multiple]+.layui-form-select dd{ padding:0;}
|
||||
.layui-form-item select[multiple]+.layui-form-select .layui-form-checkbox[lay-skin=primary]{ margin:0 !important; display:block; line-height:36px !important; position:relative; padding-left:26px;}
|
||||
.layui-form-item select[multiple]+.layui-form-select .layui-form-checkbox[lay-skin=primary] span{line-height:36px !important; float:none;}
|
||||
.layui-form-item select[multiple]+.layui-form-select .layui-form-checkbox[lay-skin=primary] i{ position:absolute; left:10px; top:0; margin-top:9px;}
|
||||
.multiSelect{ line-height:normal; height:auto; padding:4px 10px; overflow:hidden;min-height:38px; margin-top:-38px; left:0; z-index:99;position:relative;background:none;}
|
||||
.multiSelect a{ padding:2px 5px; background:#908e8e; border-radius:2px; color:#fff; display:block; line-height:20px; height:20px; margin:2px 5px 2px 0; float:left;}
|
||||
.multiSelect a span{ float:left;}
|
||||
.multiSelect a i{ float:left; display:block; margin:2px 0 0 2px; border-radius:2px; width:8px; height:8px; background:url(../images/close.png) no-repeat center; background-size:65%; padding:4px;}
|
||||
.multiSelect a i:hover{ background-color:#545556;}
|
||||
/*404页面*/
|
||||
.noFind{ text-align:center; padding-top:2%;}
|
||||
.noFind i{ line-height:1em; font-size:12em !important; color: #393D50; display:block;}
|
||||
.ufo{ text-align:center; height:100%; position:relative;}
|
||||
.noFind .page_icon,.noFind .ufo_icon{ opacity:1; position:absolute; left:50%; transform:translateX(-50%); -ms-transform:translateX(-50%); -moz-transform:translateX(-50%); -webkit-transform:translateX(-50%); -o-transform:translateX(-50%);}
|
||||
.noFind .page_icon{ top:300px; animation:pageGo 0.3s ease-in 0.3s forwards; -webkit-animation:pageGo 0.3s ease-in 0.3s forwards; -o-animation:pageGo 0.3s ease-in 0.3s forwards; -moz-animation:pageGo 0.3s ease-in 0.3s forwards;}
|
||||
.noFind .ufo_icon{ top:100px; animation:ufo 1s ease-in 0.6s forwards; -webkit-animation:ufo 1s ease-in 0.6s forwards; -o-animation:ufo 1s ease-in 0.6s forwards; -moz-animation:ufo 1s ease-in 0.6s forwards;}
|
||||
.page404{ margin-top:10%; opacity:0; font-size:0; animation:page404 0.5s ease-in 1.7s forwards; -webkit-animation:page404 0.5s ease-in 1.7s forwards; -o-animation:page404 0.5s ease-in 1.7s forwards; -moz-animation:page404 0.5s ease-in 1.7s forwards;}
|
||||
.page404 p{ font-size: 20px; font-weight: 300; color: #999;}
|
||||
/*页面被吸走*/
|
||||
@keyframes pageGo{from{font-size: 12em; top:300px;} to{font-size:0; opacity:0; top: 100px;}}
|
||||
@-moz-keyframes pageGo{from{font-size: 12em; top:300px;} to{font-size:0; opacity:0; top:100px}}
|
||||
@-webkit-keyframes pageGo{from{font-size: 12em; top:300px;} to{font-size:0; opacity:0; top:100px}}
|
||||
@-o-keyframes pageGo{from{font-size: 12em; top:300px;} to{font-size:0; opacity:0; top:100px}}
|
||||
/*ufo飞走*/
|
||||
@keyframes ufo{0%{font-size: 14em; top:100px;} 20%{font-size: 12em; top:50px;} 100%{font-size:0; opacity:0; top:-100px; left:80%;}}
|
||||
@-moz-keyframes ufo{0%{font-size: 14em; top:100px;} 20%{font-size: 12em; top:50px;} 100%{font-size:0; opacity:0; top:-100px; left:80%;}}
|
||||
@-webkit-keyframes ufo{0%{font-size: 14em; top:100px;} 20%{font-size: 12em; top:50px;} 100%{font-size:0; opacity:0; top:-100px; left:80%;}}
|
||||
@-o-keyframes ufo{0%{font-size: 14em; top:100px;} 20%{font-size: 12em; top:50px;} 100%{font-size:0; opacity:0; top:-100px; left:80%;}}
|
||||
/*404显示*/
|
||||
@keyframes page404{from{opacity:0; font-size:2em;} to{opacity:1;font-size:2em;}}
|
||||
@-moz-keyframes page404{from{opacity:0; font-size:2em;} to{opacity:1;font-size:2em;}}
|
||||
@-webkit-keyframes page404{from{opacity:0; font-size:2em;} to{opacity:1;font-size:2em;}}
|
||||
@-o-keyframes page404{from{opacity:0; font-size:2em;} to{opacity:1;font-size:2em;}}
|
||||
/*图标管理*/
|
||||
.iconsLength{ margin:0 5px;}
|
||||
.icons li{ margin:5px 0; text-align:center; height:120px; cursor:pointer;}
|
||||
.icons li i{ display:block; font-size:35px; margin:10px 0; line-height:60px; height:60px;}
|
||||
.icons li:hover{ background:rgba(13,10,49,.9); border-radius:5px; color:#fff;}
|
||||
.icons li:hover i{ font-size:50px;}
|
||||
#copyText{ width:0;height:0; opacity:0; position:absolute; left:-9999px; top:-9999px;}
|
||||
/*开发文档*/
|
||||
h2.method{ font-size:18px; line-height:45px; padding-left:5px;}
|
||||
/*登录*/
|
||||
.loginHtml,.loginBody{ height:100%;}
|
||||
.loginBody{ background:url("../images/login_bg.jpg") no-repeat center center;}
|
||||
.loginBody form.layui-form{ padding:0 20px; width:300px; height:335px; position:absolute; left:50%; top:50%; margin:-150px 0 0 -150px; -webkit-box-sizing:border-box;-moz-box-sizing:border-box; -o-box-sizing:border-box; box-sizing:border-box; background:#fff;-webkit-border-radius:5px; -moz-border-radius:5px; border-radius:5px; box-shadow:0 0 50px #009688;}
|
||||
.login_face{ margin:-55px auto 20px; width:100px; height:100px; -webkit-border-radius:50%; -moz-border-radius:50%; border-radius:50%; border:5px solid #fff; overflow:hidden;box-shadow:0 0 30px #009688;}
|
||||
.login_face img{ width:100%;}
|
||||
.loginBody .layui-form-item{ position:relative;}
|
||||
.loginBody .layui-form-item label{ position:absolute; color:#757575; left:10px; top:9px; line-height:20px; background:#fff; padding:0 5px; font-size:14px; cursor:text;}
|
||||
.loginBody .layui-form-item.layui-input-focus label{ top:-10px; font-size:12px; color:#ff6700;}
|
||||
.loginBody .layui-form-item.layui-input-active label{ top:-10px; font-size:12px;}
|
||||
.loginBody .layui-input::-webkit-input-placeholder{color:#fff;}
|
||||
.loginBody .layui-input::-moz-placeholder{color:#fff;}
|
||||
.loginBody .layui-input:-ms-input-placeholder{color:#fff;}
|
||||
.loginBody .layui-input::placeholder{color:#fff;}
|
||||
.loginBody .layui-form-item.layui-input-focus input{ border-color:#ff6700 !important;}
|
||||
.loginBody .layui-input-focus .layui-input::-webkit-input-placeholder{color:#757575;}
|
||||
.loginBody .layui-input-focus .layui-input::-moz-placeholder{color:#757575;}
|
||||
.loginBody .layui-input-focus .layui-input:-ms-input-placeholder{color:#757575;}
|
||||
.loginBody .layui-input-focus .layui-input::placeholder{color:#757575;}
|
||||
.loginBody .seraph{ font-size:30px; text-align:center;}
|
||||
.loginBody .seraph.icon-qq:hover{ color:#0288d1;}
|
||||
.loginBody .seraph.icon-wechat:hover{ color:#00d20d;}
|
||||
.loginBody .seraph.icon-sina:hover{ color:#d32f2f;}
|
||||
.imgCode{ position:relative;}
|
||||
#imgCode img{ position:absolute; top:1px; right:1px; cursor:pointer;}
|
||||
/*用户等级*/
|
||||
.layui-table-view .layui-table span.seraph{ font-size:25px !important;}
|
||||
.vip1{ color:#994a2b;}
|
||||
.vip2{ color:#899396;}
|
||||
.vip3{ color:#bd6a08;}
|
||||
.vip4{ color:#a3b8c4;}
|
||||
.vip5{ color:#63c3ea;}
|
||||
.vip6{ color:#b563ed;}
|
||||
.vip7{ color:#ff9831;}
|
||||
.vip8{ color:#A757A8;}
|
||||
.vip9{ color:#0ff;}
|
||||
.vip10{ color:#f00;}
|
||||
/*新闻添加*/
|
||||
.layui-elem-quote .layui-inline{ margin:3px 0;}
|
||||
.category .layui-form-checkbox{ margin:5px 0;}
|
||||
.border .layui-form-item{ margin-bottom:10px;}
|
||||
.border .layui-form-label{ width:50px;}
|
||||
.border .layui-form-label i{ position:absolute; top:10px; left:3px;}
|
||||
.border .layui-input-block{ margin-left:80px;}
|
||||
.thumbBox{ height:151px; overflow:hidden; border:1px solid #e6e6e6; border-radius:2px; cursor:pointer; position:relative; text-align:center; line-height:153px;}
|
||||
.thumbImg{ max-width:100%; max-height:100%; border:none;}
|
||||
.thumbBox:after{ position:absolute; width:100%; height:100%;line-height:153px; z-index:-1; text-align:center; font-size:20px; content:"缩略图"; left:0; top:0; color:#9F9F9F;}
|
||||
/*图片管理*/
|
||||
#Images li{ width:19%; margin:0.5% 0.5%; float: left; overflow:hidden;}
|
||||
#Images li img{ width:100%; cursor:pointer; }
|
||||
#Images li .operate{ display: block; height: 40px; width:100%; background:#f4f5f9; }
|
||||
#Images li .operate .check{ float:left; margin-left:11px; height:18px; padding:11px 0; width:74%; position:relative;}
|
||||
#Images li .operate .check .layui-form-checkbox[lay-skin=primary]{ width:100%;}
|
||||
#Images li .operate .check .layui-form-checkbox[lay-skin=primary] span{ padding:0 5px 0 25px; width:100%; box-sizing:border-box;}
|
||||
#Images li .operate .check .layui-form-checkbox[lay-skin=primary] i{position:absolute; left:0; top:0;}
|
||||
#Images li .operate .img_del{ float:right; margin:9px 11px 0 0; font-size: 22px !important; cursor:pointer; }
|
||||
#Images li .operate .img_del:hover{ color:#f00; }
|
||||
@media screen and (max-width:1050px){#Images li{ width:24%;}}
|
||||
@media screen and (max-width: 750px){#Images li{ width:49%;}}
|
||||
@media screen and (max-width:432px){#Images li{ width:99%;}}
|
||||
/*系统日志*/
|
||||
.layui-btn-green{ background-color:#5FB878 !important;}
|
||||
/*友情链接*/
|
||||
.linkLogo{ width:80px; height:40px; overflow:hidden; border:1px solid #e6e6e6; border-radius:2px; cursor:pointer; margin:0 auto; position:relative; text-align:center; line-height:42px;}
|
||||
.linkLogoImg{ max-width:90%; max-height:90%;}
|
||||
.linkLogo:after{ position:absolute; width:100%; height:100%;line-height:42px; z-index:-1; text-align:center; font-size:12px; content:"上传LOGO"; left:0; top:0; color:#9F9F9F;}
|
||||
.linksAdd .layui-form-label{ width:60px; padding-left:0;}
|
||||
.linksAdd .layui-input-block{ margin-left:75px;}
|
||||
.linksAdd .layui-input-block input{ padding:0 5px;}
|
||||
/*响应式*/
|
||||
@media screen and (max-width:450px) {
|
||||
#userFaceBtn{ height: 30px;line-height: 30px; padding: 0 10px; font-size: 12px;}
|
||||
.user_right img#userFace{ width:100px; height:100px; margin-top:0;}
|
||||
.layui-col-xs12 .layui-form-label{ width:60px; padding-left:0;}
|
||||
.layui-col-xs12 .layui-input-block,.layui-col-xs12 .layui-input-inline{ margin-left:75px;}
|
||||
.layui-col-xs12 .layui-input-inline{ left:0 !important; width:auto !important;}
|
||||
.noFind{ padding-top:0;}
|
||||
*[pc]{ display:none;}
|
||||
}
|
After Width: | Height: | Size: 4.2 KiB |
After Width: | Height: | Size: 37 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 24 KiB |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 2.8 KiB |
After Width: | Height: | Size: 173 KiB |
After Width: | Height: | Size: 3.8 KiB |
After Width: | Height: | Size: 6.2 KiB |
After Width: | Height: | Size: 6.1 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 6.3 KiB |
After Width: | Height: | Size: 8.0 KiB |
After Width: | Height: | Size: 22 KiB |
@ -0,0 +1,259 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>layui后台管理模板 2.0</title>
|
||||
<meta name="renderer" content="webkit">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
||||
<meta http-equiv="Access-Control-Allow-Origin" content="*">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
|
||||
<meta name="apple-mobile-web-app-status-bar-style" content="black">
|
||||
<meta name="apple-mobile-web-app-capable" content="yes">
|
||||
<meta name="format-detection" content="telephone=no">
|
||||
<link rel="icon" href="/favicon.ico">
|
||||
<link rel="stylesheet" href="/resources/layui/css/layui.css" media="all" />
|
||||
<link rel="stylesheet" href="/resources/css/index.css" media="all" />
|
||||
</head>
|
||||
<body class="main_body">
|
||||
<div class="layui-layout layui-layout-admin">
|
||||
<!-- 顶部 -->
|
||||
<div class="layui-header header">
|
||||
<div class="layui-main mag0">
|
||||
<a href="#" class="logo">仓库管理</a>
|
||||
<!-- 显示/隐藏菜单 -->
|
||||
<a href="javascript:;" class="seraph hideMenu icon-caidan"></a>
|
||||
<!-- 顶部右侧菜单 -->
|
||||
<ul class="layui-nav top_menu">
|
||||
<li class="layui-nav-item" pc>
|
||||
<a href="javascript:;" class="clearCache"><i class="layui-icon" data-icon=""></i><cite>清除缓存</cite><span class="layui-badge-dot"></span></a>
|
||||
</li>
|
||||
<li class="layui-nav-item lockcms" pc>
|
||||
<a href="javascript:;"><i class="seraph icon-lock"></i><cite>锁屏</cite></a>
|
||||
</li>
|
||||
<li class="layui-nav-item" id="userInfo">
|
||||
<a href="javascript:;"><img src="/resources/images/face.jpg" class="layui-nav-img userAvatar" width="35" height="35"><cite class="adminName">驊驊龔頾</cite></a>
|
||||
<dl class="layui-nav-child">
|
||||
<dd><a href="javascript:;" data-url="/resouces/page/user/userInfo.html"><i class="seraph icon-ziliao" data-icon="icon-ziliao"></i><cite>个人资料</cite></a></dd>
|
||||
<dd><a href="javascript:;" data-url="/resouces/page/user/changePwd.html"><i class="seraph icon-xiugai" data-icon="icon-xiugai"></i><cite>修改密码</cite></a></dd>
|
||||
<dd><a href="page/login/login.html" class="signOut"><i class="seraph icon-tuichu"></i><cite>退出</cite></a></dd>
|
||||
</dl>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 左侧导航 -->
|
||||
<div class="layui-side layui-bg-black">
|
||||
<div class="user-photo">
|
||||
<a class="img" title="我的头像" ><img src="images/face.jpg" class="userAvatar"></a>
|
||||
<p>你好!<span class="userName">超级管理员</span>, 欢迎登录</p>
|
||||
</div>
|
||||
<!-- 搜索 -->
|
||||
<div class="layui-form component">
|
||||
<select name="search" id="search" lay-search lay-filter="searchPage">
|
||||
<option value="">搜索页面或功能</option>
|
||||
<option value="1">layer</option>
|
||||
<option value="2">form</option>
|
||||
</select>
|
||||
<i class="layui-icon"></i>
|
||||
</div>
|
||||
<div class="navBar layui-side-scroll" id="navBar">
|
||||
<ul class="layui-nav layui-nav-tree">
|
||||
<li class="layui-nav-item layui-this">
|
||||
<a href="javascript:;" data-url="page/main.html"><i class="layui-icon" data-icon=""></i><cite>后台首页</cite></a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 右侧内容 -->
|
||||
<div class="layui-body layui-form">
|
||||
<div class="layui-tab mag0" lay-filter="bodyTab" id="top_tabs_box">
|
||||
<ul class="layui-tab-title top_tab" id="top_tabs">
|
||||
<li class="layui-this" lay-id=""><i class="layui-icon"></i> <cite>后台首页</cite></li>
|
||||
</ul>
|
||||
<ul class="layui-nav closeBox">
|
||||
<li class="layui-nav-item">
|
||||
<a href="javascript:;"><i class="layui-icon caozuo"></i> 页面操作</a>
|
||||
<dl class="layui-nav-child">
|
||||
<dd><a href="javascript:;" class="refresh refreshThis"><i class="layui-icon"></i> 刷新当前</a></dd>
|
||||
<dd><a href="javascript:;" class="closePageOther"><i class="seraph icon-prohibit"></i> 关闭其他</a></dd>
|
||||
<dd><a href="javascript:;" class="closePageAll"><i class="seraph icon-guanbi"></i> 关闭全部</a></dd>
|
||||
</dl>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="layui-tab-content clildFrame">
|
||||
<div class="layui-tab-item layui-show">
|
||||
<iframe src="/resources/page/main.html"></iframe>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 底部 -->
|
||||
<div class="layui-footer footer">
|
||||
<p><span>copyright @2019 WHSXT</span></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 移动导航 -->
|
||||
<div class="site-tree-mobile"><i class="layui-icon"></i></div>
|
||||
<div class="site-mobile-shade"></div>
|
||||
|
||||
<script type="text/javascript" src="/resources/layui/layui.js"></script>
|
||||
<script type="text/javascript" src="/resources/js/cache.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
var $,tab,dataStr,layer;
|
||||
layui.config({
|
||||
base : "/resources/js/"
|
||||
}).extend({
|
||||
"bodyTab" : "bodyTab"
|
||||
})
|
||||
layui.use(['bodyTab','form','element','layer','jquery'],function(){
|
||||
var form = layui.form,
|
||||
element = layui.element;
|
||||
$ = layui.$;
|
||||
layer = parent.layer === undefined ? layui.layer : top.layer;
|
||||
tab = layui.bodyTab({
|
||||
openTabNum : "50", //最大可打开窗口数量
|
||||
url : "/resources/json/navs2.json" //获取菜单json地址
|
||||
});
|
||||
|
||||
//通过顶部菜单获取左侧二三级菜单 注:此处只做演示之用,实际开发中通过接口传参的方式获取导航数据
|
||||
function getData(json){
|
||||
$.getJSON(tab.tabConfig.url,function(data){
|
||||
dataStr = data;
|
||||
//重新渲染左侧菜单
|
||||
tab.render();
|
||||
})
|
||||
}
|
||||
//页面加载时判断左侧菜单是否显示
|
||||
//通过顶部菜单获取左侧菜单
|
||||
$(".topLevelMenus li,.mobileTopLevelMenus dd").click(function(){
|
||||
if($(this).parents(".mobileTopLevelMenus").length != "0"){
|
||||
$(".topLevelMenus li").eq($(this).index()).addClass("layui-this").siblings().removeClass("layui-this");
|
||||
}else{
|
||||
$(".mobileTopLevelMenus dd").eq($(this).index()).addClass("layui-this").siblings().removeClass("layui-this");
|
||||
}
|
||||
$(".layui-layout-admin").removeClass("showMenu");
|
||||
$("body").addClass("site-mobile");
|
||||
getData($(this).data("menu"));
|
||||
//渲染顶部窗口
|
||||
tab.tabMove();
|
||||
})
|
||||
|
||||
//隐藏左侧导航
|
||||
$(".hideMenu").click(function(){
|
||||
if($(".topLevelMenus li.layui-this a").data("url")){
|
||||
layer.msg("此栏目状态下左侧菜单不可展开"); //主要为了避免左侧显示的内容与顶部菜单不匹配
|
||||
return false;
|
||||
}
|
||||
$(".layui-layout-admin").toggleClass("showMenu");
|
||||
//渲染顶部窗口
|
||||
tab.tabMove();
|
||||
})
|
||||
|
||||
//通过顶部菜单获取左侧二三级菜单 注:此处只做演示之用,实际开发中通过接口传参的方式获取导航数据
|
||||
getData("contentManagement");
|
||||
|
||||
//手机设备的简单适配
|
||||
$('.site-tree-mobile').on('click', function(){
|
||||
$('body').addClass('site-mobile');
|
||||
});
|
||||
$('.site-mobile-shade').on('click', function(){
|
||||
$('body').removeClass('site-mobile');
|
||||
});
|
||||
|
||||
// 添加新窗口
|
||||
$("body").on("click",".layui-nav .layui-nav-item a:not('.mobileTopLevelMenus .layui-nav-item a')",function(){
|
||||
//如果不存在子级
|
||||
if($(this).siblings().length == 0){
|
||||
addTab($(this));
|
||||
$('body').removeClass('site-mobile'); //移动端点击菜单关闭菜单层
|
||||
}
|
||||
$(this).parent("li").siblings().removeClass("layui-nav-itemed");
|
||||
})
|
||||
|
||||
//清除缓存
|
||||
$(".clearCache").click(function(){
|
||||
window.sessionStorage.clear();
|
||||
window.localStorage.clear();
|
||||
var index = layer.msg('清除缓存中,请稍候',{icon: 16,time:false,shade:0.8});
|
||||
setTimeout(function(){
|
||||
layer.close(index);
|
||||
layer.msg("缓存清除成功!");
|
||||
},1000);
|
||||
})
|
||||
|
||||
//刷新后还原打开的窗口
|
||||
if(cacheStr == "true") {
|
||||
if (window.sessionStorage.getItem("menu") != null) {
|
||||
menu = JSON.parse(window.sessionStorage.getItem("menu"));
|
||||
curmenu = window.sessionStorage.getItem("curmenu");
|
||||
var openTitle = '';
|
||||
for (var i = 0; i < menu.length; i++) {
|
||||
openTitle = '';
|
||||
if (menu[i].icon) {
|
||||
if (menu[i].icon.split("-")[0] == 'icon') {
|
||||
openTitle += '<i class="seraph ' + menu[i].icon + '"></i>';
|
||||
} else {
|
||||
openTitle += '<i class="layui-icon">' + menu[i].icon + '</i>';
|
||||
}
|
||||
}
|
||||
openTitle += '<cite>' + menu[i].title + '</cite>';
|
||||
openTitle += '<i class="layui-icon layui-unselect layui-tab-close" data-id="' + menu[i].layId + '">ဆ</i>';
|
||||
element.tabAdd("bodyTab", {
|
||||
title: openTitle,
|
||||
content: "<iframe src='" + menu[i].href + "' data-id='" + menu[i].layId + "'></frame>",
|
||||
id: menu[i].layId
|
||||
})
|
||||
//定位到刷新前的窗口
|
||||
if (curmenu != "undefined") {
|
||||
if (curmenu == '' || curmenu == "null") { //定位到后台首页
|
||||
element.tabChange("bodyTab", '');
|
||||
} else if (JSON.parse(curmenu).title == menu[i].title) { //定位到刷新前的页面
|
||||
element.tabChange("bodyTab", menu[i].layId);
|
||||
}
|
||||
} else {
|
||||
element.tabChange("bodyTab", menu[menu.length - 1].layId);
|
||||
}
|
||||
}
|
||||
//渲染顶部窗口
|
||||
tab.tabMove();
|
||||
}
|
||||
}else{
|
||||
window.sessionStorage.removeItem("menu");
|
||||
window.sessionStorage.removeItem("curmenu");
|
||||
}
|
||||
})
|
||||
|
||||
//打开新窗口
|
||||
function addTab(_this){
|
||||
tab.tabAdd(_this);
|
||||
}
|
||||
|
||||
//捐赠弹窗
|
||||
function donation(){
|
||||
layer.tab({
|
||||
area : ['260px', '367px'],
|
||||
tab : [{
|
||||
title : "微信",
|
||||
content : "<div style='padding:30px;overflow:hidden;background:#d2d0d0;'><img src='images/wechat.jpg'></div>"
|
||||
},{
|
||||
title : "支付宝",
|
||||
content : "<div style='padding:30px;overflow:hidden;background:#d2d0d0;'><img src='images/alipay.jpg'></div>"
|
||||
}]
|
||||
})
|
||||
}
|
||||
|
||||
//图片管理弹窗
|
||||
function showImg(){
|
||||
$.getJSON('json/images.json', function(json){
|
||||
var res = json;
|
||||
layer.photos({
|
||||
photos: res,
|
||||
anim: 5
|
||||
});
|
||||
});
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,54 @@
|
||||
layui.define(["form","jquery"],function(exports){
|
||||
var form = layui.form,
|
||||
$ = layui.jquery,
|
||||
Address = {
|
||||
provinces : function() {
|
||||
//加载省数据
|
||||
var proHtml = '',that = this;
|
||||
$.get("../../json/address.json", function (data) {
|
||||
for (var i = 0; i < data.length; i++) {
|
||||
proHtml += '<option value="' + data[i].code + '">' + data[i].name + '</option>';
|
||||
}
|
||||
//初始化省数据
|
||||
$("select[name=province]").append(proHtml);
|
||||
form.render();
|
||||
form.on('select(province)', function (proData) {
|
||||
$("select[name=area]").html('<option value="">请选择县/区</option>');
|
||||
var value = proData.value;
|
||||
if (value > 0) {
|
||||
that.citys(data[$(this).index() - 1].childs);
|
||||
} else {
|
||||
$("select[name=city]").attr("disabled", "disabled");
|
||||
}
|
||||
});
|
||||
})
|
||||
},
|
||||
//加载市数据
|
||||
citys : function(citys) {
|
||||
var cityHtml = '<option value="">请选择市</option>',that = this;
|
||||
for (var i = 0; i < citys.length; i++) {
|
||||
cityHtml += '<option value="' + citys[i].code + '">' + citys[i].name + '</option>';
|
||||
}
|
||||
$("select[name=city]").html(cityHtml).removeAttr("disabled");
|
||||
form.render();
|
||||
form.on('select(city)', function (cityData) {
|
||||
var value = cityData.value;
|
||||
if (value > 0) {
|
||||
that.areas(citys[$(this).index() - 1].childs);
|
||||
} else {
|
||||
$("select[name=area]").attr("disabled", "disabled");
|
||||
}
|
||||
});
|
||||
},
|
||||
//加载县/区数据
|
||||
areas : function(areas) {
|
||||
var areaHtml = '<option value="">请选择县/区</option>';
|
||||
for (var i = 0; i < areas.length; i++) {
|
||||
areaHtml += '<option value="' + areas[i].code + '">' + areas[i].name + '</option>';
|
||||
}
|
||||
$("select[name=area]").html(areaHtml).removeAttr("disabled");
|
||||
form.render();
|
||||
}
|
||||
};
|
||||
exports("address",Address);
|
||||
})
|
@ -0,0 +1,58 @@
|
||||
layui.config({
|
||||
base : "../../js/"
|
||||
}).use(['form','jquery',"address"],function() {
|
||||
var form = layui.form,
|
||||
$ = layui.jquery,
|
||||
address = layui.address;
|
||||
|
||||
//判断是否设置过头像,如果设置过则修改顶部、左侧和个人资料中的头像,否则使用默认头像
|
||||
if(window.sessionStorage.getItem('userFace')){
|
||||
$("#userFace").attr("src",window.sessionStorage.getItem('userFace'));
|
||||
$(".userAvatar").attr("src",$(".userAvatar").attr("src").split("images/")[0] + "images/" + window.sessionStorage.getItem('userFace').split("images/")[1]);
|
||||
}else{
|
||||
$("#userFace").attr("src","../../images/face.jpg");
|
||||
}
|
||||
|
||||
//判断是否修改过用户信息,如果修改过则填充修改后的信息
|
||||
var menuText = $("#top_tabs",parent.document).text(); //判断打开的窗口是否存在“个人资料”页面
|
||||
var citys,areas;
|
||||
if(window.sessionStorage.getItem('userInfo')){
|
||||
//获取省信息
|
||||
address.provinces();
|
||||
var userInfo = JSON.parse(window.sessionStorage.getItem('userInfo'));
|
||||
var citys;
|
||||
$(".realName").val(userInfo.realName); //用户名
|
||||
$(".userSex input[value="+userInfo.sex+"]").attr("checked","checked"); //性别
|
||||
$(".userPhone").val(userInfo.userPhone); //手机号
|
||||
$(".userBirthday").val(userInfo.userBirthday); //出生年月
|
||||
//填充省份信息,同时调取市级信息列表
|
||||
$.get("../../json/address.json", function (addressData) {
|
||||
$(".userAddress select[name='province']").val(userInfo.province); //省
|
||||
var value = userInfo.province;
|
||||
if (value > 0) {
|
||||
address.citys(addressData[$(".userAddress select[name='province'] option[value='"+userInfo.province+"']").index()-1].childs);
|
||||
citys = addressData[$(".userAddress select[name='province'] option[value='"+userInfo.province+"']").index()-1].childs;
|
||||
} else {
|
||||
$('.userAddress select[name=city]').attr("disabled","disabled");
|
||||
}
|
||||
$(".userAddress select[name='city']").val(userInfo.city); //市
|
||||
//填充市级信息,同时调取区县信息列表
|
||||
var value = userInfo.city;
|
||||
if (value > 0) {
|
||||
address.areas(citys[$(".userAddress select[name=city] option[value='"+userInfo.city+"']").index()-1].childs);
|
||||
} else {
|
||||
$('.userAddress select[name=area]').attr("disabled","disabled");
|
||||
}
|
||||
$(".userAddress select[name='area']").val(userInfo.area); //区
|
||||
form.render();
|
||||
})
|
||||
for(key in userInfo){
|
||||
if(key.indexOf("like") != -1){
|
||||
$(".userHobby input[name='"+key+"']").attr("checked","checked");
|
||||
}
|
||||
}
|
||||
$(".userEmail").val(userInfo.userEmail); //用户邮箱
|
||||
$(".myself").val(userInfo.myself); //自我评价
|
||||
form.render();
|
||||
}
|
||||
})
|
@ -0,0 +1,167 @@
|
||||
var $,tab,dataStr,layer;
|
||||
layui.config({
|
||||
base : "js/"
|
||||
}).extend({
|
||||
"bodyTab" : "bodyTab"
|
||||
})
|
||||
layui.use(['bodyTab','form','element','layer','jquery'],function(){
|
||||
var form = layui.form,
|
||||
element = layui.element;
|
||||
$ = layui.$;
|
||||
layer = parent.layer === undefined ? layui.layer : top.layer;
|
||||
tab = layui.bodyTab({
|
||||
openTabNum : "50", //最大可打开窗口数量
|
||||
url : "json/navs.json" //获取菜单json地址
|
||||
});
|
||||
|
||||
//通过顶部菜单获取左侧二三级菜单 注:此处只做演示之用,实际开发中通过接口传参的方式获取导航数据
|
||||
function getData(json){
|
||||
$.getJSON(tab.tabConfig.url,function(data){
|
||||
if(json == "contentManagement"){
|
||||
dataStr = data.contentManagement;
|
||||
//重新渲染左侧菜单
|
||||
tab.render();
|
||||
}else if(json == "memberCenter"){
|
||||
dataStr = data.memberCenter;
|
||||
//重新渲染左侧菜单
|
||||
tab.render();
|
||||
}else if(json == "systemeSttings"){
|
||||
dataStr = data.systemeSttings;
|
||||
//重新渲染左侧菜单
|
||||
tab.render();
|
||||
}else if(json == "seraphApi"){
|
||||
dataStr = data.seraphApi;
|
||||
//重新渲染左侧菜单
|
||||
tab.render();
|
||||
}
|
||||
})
|
||||
}
|
||||
//页面加载时判断左侧菜单是否显示
|
||||
//通过顶部菜单获取左侧菜单
|
||||
$(".topLevelMenus li,.mobileTopLevelMenus dd").click(function(){
|
||||
if($(this).parents(".mobileTopLevelMenus").length != "0"){
|
||||
$(".topLevelMenus li").eq($(this).index()).addClass("layui-this").siblings().removeClass("layui-this");
|
||||
}else{
|
||||
$(".mobileTopLevelMenus dd").eq($(this).index()).addClass("layui-this").siblings().removeClass("layui-this");
|
||||
}
|
||||
$(".layui-layout-admin").removeClass("showMenu");
|
||||
$("body").addClass("site-mobile");
|
||||
getData($(this).data("menu"));
|
||||
//渲染顶部窗口
|
||||
tab.tabMove();
|
||||
})
|
||||
|
||||
//隐藏左侧导航
|
||||
$(".hideMenu").click(function(){
|
||||
if($(".topLevelMenus li.layui-this a").data("url")){
|
||||
layer.msg("此栏目状态下左侧菜单不可展开"); //主要为了避免左侧显示的内容与顶部菜单不匹配
|
||||
return false;
|
||||
}
|
||||
$(".layui-layout-admin").toggleClass("showMenu");
|
||||
//渲染顶部窗口
|
||||
tab.tabMove();
|
||||
})
|
||||
|
||||
//通过顶部菜单获取左侧二三级菜单 注:此处只做演示之用,实际开发中通过接口传参的方式获取导航数据
|
||||
getData("contentManagement");
|
||||
|
||||
//手机设备的简单适配
|
||||
$('.site-tree-mobile').on('click', function(){
|
||||
$('body').addClass('site-mobile');
|
||||
});
|
||||
$('.site-mobile-shade').on('click', function(){
|
||||
$('body').removeClass('site-mobile');
|
||||
});
|
||||
|
||||
// 添加新窗口
|
||||
$("body").on("click",".layui-nav .layui-nav-item a:not('.mobileTopLevelMenus .layui-nav-item a')",function(){
|
||||
//如果不存在子级
|
||||
if($(this).siblings().length == 0){
|
||||
addTab($(this));
|
||||
$('body').removeClass('site-mobile'); //移动端点击菜单关闭菜单层
|
||||
}
|
||||
$(this).parent("li").siblings().removeClass("layui-nav-itemed");
|
||||
})
|
||||
|
||||
//清除缓存
|
||||
$(".clearCache").click(function(){
|
||||
window.sessionStorage.clear();
|
||||
window.localStorage.clear();
|
||||
var index = layer.msg('清除缓存中,请稍候',{icon: 16,time:false,shade:0.8});
|
||||
setTimeout(function(){
|
||||
layer.close(index);
|
||||
layer.msg("缓存清除成功!");
|
||||
},1000);
|
||||
})
|
||||
|
||||
//刷新后还原打开的窗口
|
||||
if(cacheStr == "true") {
|
||||
if (window.sessionStorage.getItem("menu") != null) {
|
||||
menu = JSON.parse(window.sessionStorage.getItem("menu"));
|
||||
curmenu = window.sessionStorage.getItem("curmenu");
|
||||
var openTitle = '';
|
||||
for (var i = 0; i < menu.length; i++) {
|
||||
openTitle = '';
|
||||
if (menu[i].icon) {
|
||||
if (menu[i].icon.split("-")[0] == 'icon') {
|
||||
openTitle += '<i class="seraph ' + menu[i].icon + '"></i>';
|
||||
} else {
|
||||
openTitle += '<i class="layui-icon">' + menu[i].icon + '</i>';
|
||||
}
|
||||
}
|
||||
openTitle += '<cite>' + menu[i].title + '</cite>';
|
||||
openTitle += '<i class="layui-icon layui-unselect layui-tab-close" data-id="' + menu[i].layId + '">ဆ</i>';
|
||||
element.tabAdd("bodyTab", {
|
||||
title: openTitle,
|
||||
content: "<iframe src='" + menu[i].href + "' data-id='" + menu[i].layId + "'></frame>",
|
||||
id: menu[i].layId
|
||||
})
|
||||
//定位到刷新前的窗口
|
||||
if (curmenu != "undefined") {
|
||||
if (curmenu == '' || curmenu == "null") { //定位到后台首页
|
||||
element.tabChange("bodyTab", '');
|
||||
} else if (JSON.parse(curmenu).title == menu[i].title) { //定位到刷新前的页面
|
||||
element.tabChange("bodyTab", menu[i].layId);
|
||||
}
|
||||
} else {
|
||||
element.tabChange("bodyTab", menu[menu.length - 1].layId);
|
||||
}
|
||||
}
|
||||
//渲染顶部窗口
|
||||
tab.tabMove();
|
||||
}
|
||||
}else{
|
||||
window.sessionStorage.removeItem("menu");
|
||||
window.sessionStorage.removeItem("curmenu");
|
||||
}
|
||||
})
|
||||
|
||||
//打开新窗口
|
||||
function addTab(_this){
|
||||
tab.tabAdd(_this);
|
||||
}
|
||||
|
||||
//捐赠弹窗
|
||||
function donation(){
|
||||
layer.tab({
|
||||
area : ['260px', '367px'],
|
||||
tab : [{
|
||||
title : "微信",
|
||||
content : "<div style='padding:30px;overflow:hidden;background:#d2d0d0;'><img src='images/wechat.jpg'></div>"
|
||||
},{
|
||||
title : "支付宝",
|
||||
content : "<div style='padding:30px;overflow:hidden;background:#d2d0d0;'><img src='images/alipay.jpg'></div>"
|
||||
}]
|
||||
})
|
||||
}
|
||||
|
||||
//图片管理弹窗
|
||||
function showImg(){
|
||||
$.getJSON('json/images.json', function(json){
|
||||
var res = json;
|
||||
layer.photos({
|
||||
photos: res,
|
||||
anim: 5
|
||||
});
|
||||
});
|
||||
}
|
@ -0,0 +1,193 @@
|
||||
{
|
||||
"title": "图片管理",
|
||||
"id": "Images",
|
||||
"start": 0,
|
||||
"data": [
|
||||
{
|
||||
"src": "images/userface1.jpg",
|
||||
"thumb": "images/userface1.jpg",
|
||||
"alt": "美女生活照1",
|
||||
"pid":"1"
|
||||
},
|
||||
{
|
||||
"src": "images/userface2.jpg",
|
||||
"thumb": "images/userface2.jpg",
|
||||
"alt": "美女生活照2",
|
||||
"pid":"2"
|
||||
},
|
||||
{
|
||||
"src": "images/userface3.jpg",
|
||||
"thumb": "images/userface3.jpg",
|
||||
"alt": "美女生活照3",
|
||||
"pid":"3"
|
||||
},
|
||||
{
|
||||
"src": "images/userface4.jpg",
|
||||
"thumb": "images/userface4.jpg",
|
||||
"alt": "美女生活照4",
|
||||
"pid":"4"
|
||||
},
|
||||
{
|
||||
"src": "images/userface5.jpg",
|
||||
"thumb": "images/userface5.jpg",
|
||||
"alt": "美女生活照5",
|
||||
"pid":"5"
|
||||
},
|
||||
{
|
||||
"src": "images/userface1.jpg",
|
||||
"thumb": "images/userface1.jpg",
|
||||
"alt": "美女生活照6",
|
||||
"pid":"6"
|
||||
},
|
||||
{
|
||||
"src": "images/userface2.jpg",
|
||||
"thumb": "images/userface2.jpg",
|
||||
"alt": "美女生活照7",
|
||||
"pid":"7"
|
||||
},
|
||||
{
|
||||
"src": "images/userface3.jpg",
|
||||
"thumb": "images/userface3.jpg",
|
||||
"alt": "美女生活照8",
|
||||
"pid":"8"
|
||||
},
|
||||
{
|
||||
"src": "images/userface4.jpg",
|
||||
"thumb": "images/userface4.jpg",
|
||||
"alt": "美女生活照9",
|
||||
"pid":"9"
|
||||
},
|
||||
{
|
||||
"src": "images/userface5.jpg",
|
||||
"thumb": "images/userface5.jpg",
|
||||
"alt": "美女生活照10",
|
||||
"pid":"10"
|
||||
},
|
||||
{
|
||||
"src": "images/userface1.jpg",
|
||||
"thumb": "images/userface1.jpg",
|
||||
"alt": "美女生活照11",
|
||||
"pid":"11"
|
||||
},
|
||||
{
|
||||
"src": "images/userface2.jpg",
|
||||
"thumb": "images/userface2.jpg",
|
||||
"alt": "美女生活照12",
|
||||
"pid":"12"
|
||||
},
|
||||
{
|
||||
"src": "images/userface3.jpg",
|
||||
"thumb": "images/userface3.jpg",
|
||||
"alt": "美女生活照13",
|
||||
"pid":"13"
|
||||
},
|
||||
{
|
||||
"src": "images/userface4.jpg",
|
||||
"thumb": "images/userface4.jpg",
|
||||
"alt": "美女生活照14",
|
||||
"pid":"14"
|
||||
},
|
||||
{
|
||||
"src": "images/userface5.jpg",
|
||||
"thumb": "images/userface5.jpg",
|
||||
"alt": "美女生活照15",
|
||||
"pid":"15"
|
||||
},
|
||||
{
|
||||
"src": "images/userface1.jpg",
|
||||
"thumb": "images/userface1.jpg",
|
||||
"alt": "美女生活照16",
|
||||
"pid":"16"
|
||||
},
|
||||
{
|
||||
"src": "images/userface2.jpg",
|
||||
"thumb": "images/userface2.jpg",
|
||||
"alt": "美女生活照17",
|
||||
"pid":"17"
|
||||
},
|
||||
{
|
||||
"src": "images/userface3.jpg",
|
||||
"thumb": "images/userface3.jpg",
|
||||
"alt": "美女生活照18",
|
||||
"pid":"18"
|
||||
},
|
||||
{
|
||||
"src": "images/userface4.jpg",
|
||||
"thumb": "images/userface4.jpg",
|
||||
"alt": "美女生活照19",
|
||||
"pid":"19"
|
||||
},
|
||||
{
|
||||
"src": "images/userface5.jpg",
|
||||
"thumb": "images/userface5.jpg",
|
||||
"alt": "美女生活照20",
|
||||
"pid":"20"
|
||||
},
|
||||
{
|
||||
"src": "images/userface1.jpg",
|
||||
"thumb": "images/userface1.jpg",
|
||||
"alt": "美女生活照21",
|
||||
"pid":"21"
|
||||
},
|
||||
{
|
||||
"src": "images/userface2.jpg",
|
||||
"thumb": "images/userface2.jpg",
|
||||
"alt": "美女生活照22",
|
||||
"pid":"22"
|
||||
},
|
||||
{
|
||||
"src": "images/userface3.jpg",
|
||||
"thumb": "images/userface3.jpg",
|
||||
"alt": "美女生活照23",
|
||||
"pid":"23"
|
||||
},
|
||||
{
|
||||
"src": "images/userface4.jpg",
|
||||
"thumb": "images/userface4.jpg",
|
||||
"alt": "美女生活照24",
|
||||
"pid":"24"
|
||||
},
|
||||
{
|
||||
"src": "images/userface5.jpg",
|
||||
"thumb": "images/userface5.jpg",
|
||||
"alt": "美女生活照25",
|
||||
"pid":"25"
|
||||
},
|
||||
{
|
||||
"src": "images/userface1.jpg",
|
||||
"thumb": "images/userface1.jpg",
|
||||
"alt": "美女生活照26",
|
||||
"pid":"26"
|
||||
},
|
||||
{
|
||||
"src": "images/userface2.jpg",
|
||||
"thumb": "images/userface2.jpg",
|
||||
"alt": "美女生活照27",
|
||||
"pid":"27"
|
||||
},
|
||||
{
|
||||
"src": "images/userface3.jpg",
|
||||
"thumb": "images/userface3.jpg",
|
||||
"alt": "美女生活照28",
|
||||
"pid":"28"
|
||||
},
|
||||
{
|
||||
"src": "images/userface4.jpg",
|
||||
"thumb": "images/userface4.jpg",
|
||||
"alt": "美女生活照29",
|
||||
"pid":"29"
|
||||
},
|
||||
{
|
||||
"src": "images/userface5.jpg",
|
||||
"thumb": "images/userface5.jpg",
|
||||
"alt": "美女生活照30",
|
||||
"pid":"30"
|
||||
},
|
||||
{
|
||||
"src": "images/userface3.jpg",
|
||||
"thumb": "images/userface3.jpg",
|
||||
"alt": "美女生活照31",
|
||||
"pid":"31"
|
||||
}
|
||||
]
|
||||
}
|
@ -0,0 +1,40 @@
|
||||
{
|
||||
"code": 0,
|
||||
"msg": "",
|
||||
"count": 4,
|
||||
"data": [
|
||||
{
|
||||
"linkId": "1",
|
||||
"logo": "../../images/layui.png",
|
||||
"websiteName": "layui - 经典模块化前端框架",
|
||||
"websiteUrl": "http://www.layui.com",
|
||||
"masterEmail": "xianxin@layui.com",
|
||||
"addTime": "2017-05-14",
|
||||
"showAddress": "checked"
|
||||
},{
|
||||
"linkId": "2",
|
||||
"logo": "../../images/fly.png",
|
||||
"websiteName": "fly - 前端框架官方社区",
|
||||
"websiteUrl": "http://fly.layui.com",
|
||||
"masterEmail": "xianxin@layui.com",
|
||||
"addTime": "2017-05-14",
|
||||
"showAddress": ""
|
||||
},{
|
||||
"linkId": "3",
|
||||
"logo": "../../images/mayun.png",
|
||||
"websiteName": "layuicms2.0 - 码云 - 开源中国",
|
||||
"websiteUrl": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"masterEmail": "git@oschina.cn",
|
||||
"addTime": "2017-05-14",
|
||||
"showAddress": ""
|
||||
},{
|
||||
"linkId": "4",
|
||||
"logo": "../../images/git.png",
|
||||
"websiteName": "layuicms2.0 - Github",
|
||||
"websiteUrl": "https://github.com/BrotherMa/layuiCMS2.0",
|
||||
"masterEmail": "github@github.cn",
|
||||
"addTime": "2017-05-14",
|
||||
"showAddress": ""
|
||||
}
|
||||
]
|
||||
}
|
@ -0,0 +1,15 @@
|
||||
{
|
||||
"code": 0,
|
||||
"msg": "",
|
||||
"data": [
|
||||
{
|
||||
"src": "../../images/fly.png"
|
||||
},{
|
||||
"src": "../../images/git.png"
|
||||
},{
|
||||
"src": "../../images/layui.png"
|
||||
},{
|
||||
"src": "../../images/mayun.png"
|
||||
}
|
||||
]
|
||||
}
|
@ -0,0 +1,158 @@
|
||||
{
|
||||
"code": 0,
|
||||
"msg": "",
|
||||
"count": 15,
|
||||
"data": [
|
||||
{
|
||||
"logId": "1",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "2",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "POST",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"89",
|
||||
"isAbnormal": "异常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "3",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "admin",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "4",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "异常",
|
||||
"operator": "admin",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "5",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "POST",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"55",
|
||||
"newsLook": "开放浏览",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "6",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method": "POST",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "admin",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "7",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "异常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "8",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "POST",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"15",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "9",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "admin",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "10",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"25",
|
||||
"isAbnormal": "异常",
|
||||
"operator": "admin",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "11",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "POST",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "12",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "13",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"12",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "admin",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "14",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "POST",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "异常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
},
|
||||
{
|
||||
"logId": "15",
|
||||
"url": "https://gitee.com/layuicms/layuicms2.0",
|
||||
"method" : "GET",
|
||||
"ip": "192.169.39.11",
|
||||
"timeConsuming":"125",
|
||||
"isAbnormal": "正常",
|
||||
"operator": "驊驊龔頾",
|
||||
"operatingTime": "2017-04-14 00:00:00"
|
||||
}
|
||||
]
|
||||
}
|
@ -0,0 +1,94 @@
|
||||
{
|
||||
"contentManagement": [
|
||||
{
|
||||
"title": "文章列表",
|
||||
"icon": "icon-text",
|
||||
"href": "page/news/newsList.html",
|
||||
"spread": false
|
||||
},
|
||||
{
|
||||
"title": "图片管理",
|
||||
"icon": "",
|
||||
"href": "page/img/images.html",
|
||||
"spread": false
|
||||
},
|
||||
{
|
||||
"title": "其他页面",
|
||||
"icon": "",
|
||||
"href": "",
|
||||
"spread": false,
|
||||
"children": [
|
||||
{
|
||||
"title": "404页面",
|
||||
"icon": "",
|
||||
"href": "page/404.html",
|
||||
"spread": false
|
||||
},
|
||||
{
|
||||
"title": "登录",
|
||||
"icon": "",
|
||||
"href": "page/login/login.html",
|
||||
"spread": false,
|
||||
"target": "_blank"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"memberCenter": [
|
||||
{
|
||||
"title": "用户中心",
|
||||
"icon": "",
|
||||
"href": "page/user/userList.html",
|
||||
"spread": false
|
||||
},
|
||||
{
|
||||
"title": "会员等级",
|
||||
"icon": "icon-vip",
|
||||
"href": "page/user/userGrade.html",
|
||||
"spread": false
|
||||
}
|
||||
],
|
||||
"systemeSttings": [
|
||||
{
|
||||
"title": "系统基本参数",
|
||||
"icon": "",
|
||||
"href": "page/systemSetting/basicParameter.html",
|
||||
"spread": false
|
||||
},{
|
||||
"title": "系统日志",
|
||||
"icon": "icon-log",
|
||||
"href": "page/systemSetting/logs.html",
|
||||
"spread": false
|
||||
},{
|
||||
"title": "友情链接",
|
||||
"icon": "",
|
||||
"href": "page/systemSetting/linkList.html",
|
||||
"spread": false
|
||||
},{
|
||||
"title": "图标管理",
|
||||
"icon": "",
|
||||
"href": "page/systemSetting/icons.html",
|
||||
"spread": false
|
||||
}
|
||||
],
|
||||
"seraphApi": [
|
||||
{
|
||||
"title": "三级联动模块",
|
||||
"icon": "icon-mokuai",
|
||||
"href": "page/doc/addressDoc.html",
|
||||
"spread": false
|
||||
},{
|
||||
"title": "bodyTab模块",
|
||||
"icon": "icon-mokuai",
|
||||
"href": "page/doc/bodyTabDoc.html",
|
||||
"spread": false
|
||||
},{
|
||||
"title": "三级菜单",
|
||||
"icon": "icon-mokuai",
|
||||
"href": "page/doc/navDoc.html",
|
||||
"spread": false
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,35 @@
|
||||
[
|
||||
{
|
||||
"title": "文章列表",
|
||||
"icon": "icon-text",
|
||||
"href": "page/news/newsList.html",
|
||||
"spread": false
|
||||
},
|
||||
{
|
||||
"title": "图片管理",
|
||||
"icon": "",
|
||||
"href": "page/img/images.html",
|
||||
"spread": false
|
||||
},
|
||||
{
|
||||
"title": "其他页面",
|
||||
"icon": "",
|
||||
"href": "",
|
||||
"spread": false,
|
||||
"children": [
|
||||
{
|
||||
"title": "404页面",
|
||||
"icon": "",
|
||||
"href": "page/404.html",
|
||||
"spread": false
|
||||
},
|
||||
{
|
||||
"title": "登录",
|
||||
"icon": "",
|
||||
"href": "page/login/login.html",
|
||||
"spread": false,
|
||||
"target": "_blank"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
@ -0,0 +1,8 @@
|
||||
{
|
||||
"code": 0,
|
||||
"msg": "",
|
||||
"data":{
|
||||
"src": "../../images/userface1.jpg",
|
||||
"title" : "文章内容图片"
|
||||
}
|
||||
}
|
@ -0,0 +1,63 @@
|
||||
{
|
||||
"code": 0,
|
||||
"msg": "",
|
||||
"count": 1000,
|
||||
"data": [
|
||||
{
|
||||
"id": 1,
|
||||
"gradeIcon": "icon-vip1",
|
||||
"gradeName": "倔强青铜",
|
||||
"gradePoint": "0",
|
||||
"gradeGold": "0",
|
||||
"gradeValue": "0"
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"gradeIcon": "icon-vip2",
|
||||
"gradeName": "秩序白银",
|
||||
"gradePoint": "100",
|
||||
"gradeGold": "200",
|
||||
"gradeValue": "500"
|
||||
},
|
||||
{
|
||||
"id": 3,
|
||||
"gradeIcon": "icon-vip3",
|
||||
"gradeName": "荣耀黄金",
|
||||
"gradePoint": "300",
|
||||
"gradeGold": "300",
|
||||
"gradeValue": "1000"
|
||||
},
|
||||
{
|
||||
"id": 4,
|
||||
"gradeIcon": "icon-vip4",
|
||||
"gradeName": "尊贵铂金",
|
||||
"gradePoint": "800",
|
||||
"gradeGold": "400",
|
||||
"gradeValue": "2000"
|
||||
},
|
||||
{
|
||||
"id": 5,
|
||||
"gradeIcon": "icon-vip5",
|
||||
"gradeName": "永恒钻石",
|
||||
"gradePoint": "1500",
|
||||
"gradeGold": "500",
|
||||
"gradeValue": "5000"
|
||||
},
|
||||
{
|
||||
"id": 6,
|
||||
"gradeIcon": "icon-vip6",
|
||||
"gradeName": "至尊星耀",
|
||||
"gradePoint": "3000",
|
||||
"gradeGold": "600",
|
||||
"gradeValue": "10000"
|
||||
},
|
||||
{
|
||||
"id": 7,
|
||||
"gradeIcon": "icon-vip7",
|
||||
"gradeName": "最强王者",
|
||||
"gradePoint": "5000",
|
||||
"gradeGold": "700",
|
||||
"gradeValue": "35000"
|
||||
}
|
||||
]
|
||||
}
|
@ -0,0 +1,17 @@
|
||||
{
|
||||
"code": 0,
|
||||
"msg": "",
|
||||
"data": [
|
||||
{
|
||||
"src": "../../images/userface1.jpg"
|
||||
},{
|
||||
"src": "../../images/userface2.jpg"
|
||||
},{
|
||||
"src": "../../images/userface3.jpg"
|
||||
},{
|
||||
"src": "../../images/userface4.jpg"
|
||||
},{
|
||||
"src": "../../images/userface5.jpg"
|
||||
}
|
||||
]
|
||||
}
|
@ -0,0 +1,2 @@
|
||||
/** layui-v2.5.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}
|
After Width: | Height: | Size: 5.8 KiB |
After Width: | Height: | Size: 11 KiB |
After Width: | Height: | Size: 5.7 KiB |
After Width: | Height: | Size: 701 B |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 277 KiB |
After Width: | Height: | Size: 2.6 KiB |
After Width: | Height: | Size: 5.4 KiB |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 3.3 KiB |
After Width: | Height: | Size: 7.3 KiB |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 6.6 KiB |
After Width: | Height: | Size: 4.3 KiB |
After Width: | Height: | Size: 2.9 KiB |
After Width: | Height: | Size: 3.0 KiB |
After Width: | Height: | Size: 3.1 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 9.6 KiB |
After Width: | Height: | Size: 3.7 KiB |
After Width: | Height: | Size: 7.9 KiB |
After Width: | Height: | Size: 3.1 KiB |
After Width: | Height: | Size: 3.2 KiB |
After Width: | Height: | Size: 4.3 KiB |