publish:升级工程到.Net core 2.1/Bootstrap4.7

This commit is contained in:
Argo-MacBookPro 2018-08-13 14:49:54 +08:00
parent 90f876d0f8
commit 4cd87d8122
296 changed files with 34774 additions and 39641 deletions

297
.gitignore vendored
View File

@ -1,66 +1,128 @@
###### -- File Created With Git Source Control Provider 2015 -- ######
###### -- From https://github.com/github/gitignore -- ######
###### -- Warning Regenerating this file will erase all your custom ignores, unless you add them below the Custom Ignore section at the bottom -- ######
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
#Assiant files
.vs
CenterControlSetup
dll
packages
##
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
# User-specific files
*.suo
*.user
*.userosscache
*.sln.docstates
# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs
# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
build/
x86/
bld/
[Bb]in/
[Oo]bj/
[Ll]og/
# Enable "build/" folder in the NuGet Packages folder since NuGet packages use it for MSBuild targets
!packages/*/build/
# Visual Studio 2015/2017 cache/options directory
.vs/
# Uncomment if you have tasks that create the project's static files in wwwroot
#wwwroot/
# Visual Studio 2017 auto generated files
Generated\ Files/
# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*
# NUNIT
*.VisualState.xml
TestResult.xml
# Build Results of an ATL Project
[Dd]ebugPS/
[Rr]eleasePS/
dlldata.c
# Benchmark Results
BenchmarkDotNet.Artifacts/
# .NET Core
project.lock.json
project.fragment.lock.json
artifacts/
# StyleCop
StyleCopReport.xml
# Files built by Visual Studio
*_i.c
*_p.c
*_i.h
*.ilk
*.meta
*.ncb
*.obj
*.iobj
*.pch
*.pdb
*.ipdb
*.pgc
*.pgd
*.suo
*.sln.docstates
*.rsp
*.sbr
*.tlb
*.tli
*.bak
*.tlh
*.tmp
*.tmp_proj
*.log
*.cache
*.vspscc
*.vssscc
.builds
*.ilk
*.pidb
*.svclog
*.scc
[Dd]ebug*/
# Chutzpah Test files
_Chutzpah*
# Visual C++ cache files
ipch/
*.aps
*.lib
*.ncb
*.opendb
*.opensdf
*.sbr
*.sdf
*.cachefile
[Rr]elease*/
*.VC.db
*.VC.VC.opendb
# Visual Studio profiler
*.psess
*.vsp
*.vspx
*.sap
# Visual Studio Trace Files
*.e2e
# TFS 2012 Local Workspace
$tf/
# Guidance Automation Toolkit
*.gpState
# ReSharper is a .NET coding add-in
[Tt]est[Rr]esult*
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
# JustCode is a .NET coding add-in
.JustCode
# TeamCity is a build add-in
_TeamCity*
@ -68,9 +130,25 @@ _TeamCity*
# DotCover is a Code Coverage Tool
*.dotCover
# AxoCover is a Code Coverage Tool
.axoCover/*
!.axoCover/settings.json
# Visual Studio code coverage results
*.coverage
*.coveragexml
# NCrunch
*.ncrunch*
_NCrunch_*
.*crunch*.local.xml
nCrunchTemp_*
# MightyMoose
*.mm.*
AutoTest.Net/
# Web workbench (sass)
.sass-cache/
# Installshield output folder
[Ee]xpress/
@ -89,70 +167,175 @@ DocProject/Help/html
publish/
# Publish Web Output
*.Publish.xml
*.[Pp]ublish.xml
*.azurePubxml
# Note: Comment the next line if you want to checkin your web deploy settings,
# but database connection strings (with potential passwords) will be unencrypted
*.pubxml
*.publishproj
# NuGet Packages Directory
## TODO: If you have NuGet Package Restore enabled, uncomment the next line
#packages/
# Microsoft Azure Web App publish settings. Comment the next line if you want to
# checkin your Azure Web App publish settings, but sensitive information contained
# in these scripts will be unencrypted
PublishScripts/
# Windows Azure Build Output
*.vssscc
# NuGet Packages
*.nupkg
# The packages folder can be ignored because of Package Restore
**/[Pp]ackages/*
# except build/, which is used as an MSBuild target.
!**/[Pp]ackages/build/
# Uncomment if necessary however generally it will be regenerated when needed
#!**/[Pp]ackages/repositories.config
# NuGet v3's project.json files produces more ignorable files
*.nuget.props
*.nuget.targets
# Microsoft Azure Build Output
csx/
*.build.csdef
# Windows Store app package directory
# Microsoft Azure Emulator
ecf/
rcf/
# Windows Store app package directories and files
AppPackages/
BundleArtifacts/
Package.StoreAssociation.xml
_pkginfo.txt
*.appx
# Visual Studio cache files
# files ending in .cache can be ignored
*.[Cc]ache
# but keep track of directories ending in .cache
!*.[Cc]ache/
# Others
sql/
*.Cache
ClientBin/
[Ss]tyle[Cc]op.*
$tf*/
~$*
*~
*.dbmdl
*.[Pp]ublish.xml
*.dbproj.schemaview
*.jfm
*.pfx
*.publishsettings
orleans.codegen.cs
# Including strong name files can present a security risk
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
#*.snk
# Since there are multiple workflows, uncomment next line to ignore bower_components
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
#bower_components/
# RIA/Silverlight projects
Generated_Code/
# Backup & report files from converting an old project file to a newer
# Visual Studio version. Backup files are not needed, because we have git ;-)
# Backup & report files from converting an old project file
# to a newer Visual Studio version. Backup files are not needed,
# because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm
ServiceFabricBackup/
*.rptproj.bak
# SQL Server files
App_Data/*.mdf
App_Data/*.ldf
*.mdf
*.ldf
*.ndf
# =========================
# Windows detritus
# =========================
# Business Intelligence projects
*.rdl.data
*.bim.layout
*.bim_*.settings
*.rptproj.rsuser
# Windows image file caches
Thumbs.db
ehthumbs.db
# Microsoft Fakes
FakesAssemblies/
# Folder config file
Desktop.ini
# GhostDoc plugin setting file
*.GhostDoc.xml
# Recycle Bin used on file shares
$RECYCLE.BIN/
# Node.js Tools for Visual Studio
.ntvs_analysis.dat
node_modules/
# Mac crap
.DS_Store
# Visual Studio 6 build log
*.plg
# Dotfuscator
Dotfuscated/
# Visual Studio 6 workspace options file
*.opt
#AutoUpdate
*/UpdateServer/v*
*/UpdateServer/*.dll
*/UpdateServer/*.exe
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
*.vbw
# Visual Studio LightSwitch build output
**/*.HTMLClient/GeneratedArtifacts
**/*.DesktopClient/GeneratedArtifacts
**/*.DesktopClient/ModelManifest.xml
**/*.Server/GeneratedArtifacts
**/*.Server/ModelManifest.xml
_Pvt_Extensions
# Paket dependency manager
.paket/paket.exe
paket-files/
# FAKE - F# Make
.fake/
# JetBrains Rider
.idea/
*.sln.iml
# CodeRush
.cr/
# Python Tools for Visual Studio (PTVS)
__pycache__/
*.pyc
# Cake - Uncomment if you are using it
# tools/**
# !tools/packages.config
# Tabs Studio
*.tss
# Telerik's JustMock configuration file
*.jmconfig
# BizTalk build output
*.btp.cs
*.btm.cs
*.odx.cs
*.xsd.cs
# OpenCover UI analysis results
OpenCover/
# Azure Stream Analytics local run output
ASALocalRun/
# MSBuild Binary and Structured Log
*.binlog
# NVidia Nsight GPU debugger configuration file
*.nvuser
# MFractors (Xamarin productivity tool) working folder
.mfractor/
# MAC Files
**/.DS_Store
# Windows db files
**/[tT]humbs.db
###### -- Custom Ignore Section, Make sure all files you add to the git repo are below this line -- ######
#uploader
uploader/

View File

@ -1 +0,0 @@
请不要删除此目录

View File

@ -1,29 +0,0 @@
using Bootstrap.DataAccess;
using Longbow.Caching;
using Longbow.ExceptionManagement;
using Longbow.ExceptionManagement.Configuration;
using System;
using System.Collections.Specialized;
namespace Bootstrap.Admin
{
/// <summary>
///
/// </summary>
public class DBPublisher : IExceptionPublisher
{
/// <summary>
///
/// </summary>
/// <param name="ex"></param>
/// <param name="additionalInfo"></param>
/// <param name="publisherElement"></param>
public void Publish(Exception ex, NameValueCollection additionalInfo, ExceptionPublisherElement publisherElement)
{
if (publisherElement.Mode == PublisherMode.Off) return;
ExceptionHelper.Log(ex, additionalInfo);
CacheManager.Clear(k => k == ExceptionHelper.RetrieveExceptionsDataKey);
NotificationHelper.MessagePool.Add(new MessageBody() { Category = "Notification", Message = ex.Message });
}
}
}

View File

@ -1,24 +0,0 @@
using Bootstrap.Security.Mvc;
using Longbow.Web.Mvc;
using System;
using System.Web.Mvc;
namespace Bootstrap.Admin
{
/// <summary>
///
/// </summary>
public static class FilterConfig
{
/// <summary>
///
/// </summary>
/// <param name="filters"></param>
public static void RegisterGlobalFilters(GlobalFilterCollection filters)
{
if (filters == null) throw new ArgumentNullException("filters");
filters.Add(new LgbHandleErrorAttribute());
filters.Add(new BAAuthorizeAttribute());
}
}
}

View File

@ -1,19 +0,0 @@
using System.Web.Mvc;
using System.Web.Routing;
namespace Bootstrap.Admin
{
public class RouteConfig
{
public static void RegisterRoutes(RouteCollection routes)
{
routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
routes.MapRoute(
name: "Default",
url: "{controller}/{action}/{id}",
defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
);
}
}
}

View File

@ -1,25 +0,0 @@
using Bootstrap.Security.Mvc;
using System.Web.Http;
namespace Bootstrap.Admin
{
public static class WebApiConfig
{
public static void Register(HttpConfiguration config)
{
// Web API configuration and services
config.Filters.Add(new BAAPIAuthorizaAttribute());
// Web API routes
config.MapHttpAttributeRoutes();
config.Routes.MapHttpRoute(
name: "DefaultApi",
routeTemplate: "api/{controller}/{id}",
defaults: new { id = RouteParameter.Optional }
);
var json = GlobalConfiguration.Configuration.Formatters.JsonFormatter.SerializerSettings;
json.DateFormatString = "yyyy'-'MM'-'dd' 'HH':'mm':'ss";
}
}
}

View File

@ -1,390 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>
</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{7B2B7043-3CB2-4C5A-BDF2-8C47F1A5471A}</ProjectGuid>
<ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Bootstrap.Admin</RootNamespace>
<AssemblyName>Bootstrap.Admin</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<UseIISExpress>true</UseIISExpress>
<IISExpressSSLPort />
<IISExpressAnonymousAuthentication />
<IISExpressWindowsAuthentication />
<IISExpressUseClassicPipelineMode />
<UseGlobalApplicationHostFile />
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
<Use64BitIISExpress />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Bootstrap.Security.Mvc, Version=4.1.0.0, Culture=neutral, PublicKeyToken=c20f2177a7066899, processorArchitecture=MSIL" />
<Reference Include="Longbow, Version=4.1.0.0, Culture=neutral, PublicKeyToken=c20f2177a7066899, processorArchitecture=MSIL" />
<Reference Include="Longbow.ComponentModel, Version=4.1.0.0, Culture=neutral, PublicKeyToken=c20f2177a7066899, processorArchitecture=MSIL" />
<Reference Include="Longbow.ExceptionManagement, Version=4.1.0.0, Culture=neutral, PublicKeyToken=c20f2177a7066899, processorArchitecture=MSIL" />
<Reference Include="Longbow.Web.Mvc, Version=4.1.0.0, Culture=neutral, PublicKeyToken=c20f2177a7066899, processorArchitecture=MSIL" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.9.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System.Net.Http" />
<Reference Include="System.Web.DynamicData" />
<Reference Include="System.Web.Entity" />
<Reference Include="System.Web.ApplicationServices" />
<Reference Include="System.ComponentModel.DataAnnotations" />
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Core" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Web.Extensions" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Drawing" />
<Reference Include="System.Web" />
<Reference Include="System.Xml" />
<Reference Include="System.Configuration" />
<Reference Include="System.Web.Services" />
<Reference Include="System.EnterpriseServices" />
</ItemGroup>
<ItemGroup>
<Reference Include="System.Web.Razor">
<HintPath>..\packages\Microsoft.AspNet.Razor.3.2.3\lib\net45\System.Web.Razor.dll</HintPath>
</Reference>
<Reference Include="System.Web.Webpages">
<HintPath>..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Webpages.dll</HintPath>
</Reference>
<Reference Include="System.Web.Webpages.Deployment">
<HintPath>..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Webpages.Deployment.dll</HintPath>
</Reference>
<Reference Include="System.Web.Webpages.Razor">
<HintPath>..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Webpages.Razor.dll</HintPath>
</Reference>
<Reference Include="System.Web.Helpers">
<HintPath>..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Helpers.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Web.Infrastructure">
<HintPath>..\packages\Microsoft.Web.Infrastructure.1.0.0.0\lib\net40\Microsoft.Web.Infrastructure.dll</HintPath>
</Reference>
<Reference Include="System.Web.Mvc">
<HintPath>..\packages\Microsoft.AspNet.Mvc.5.2.3\lib\net45\System.Web.Mvc.dll</HintPath>
</Reference>
<Reference Include="System.Net.Http.Formatting">
<HintPath>..\packages\Microsoft.AspNet.WebApi.Client.5.2.3\lib\net45\System.Net.Http.Formatting.dll</HintPath>
</Reference>
<Reference Include="System.Web.Http">
<HintPath>..\packages\Microsoft.AspNet.WebApi.Core.5.2.3\lib\net45\System.Web.Http.dll</HintPath>
</Reference>
<Reference Include="System.Web.Http.WebHost">
<HintPath>..\packages\Microsoft.AspNet.WebApi.WebHost.5.2.3\lib\net45\System.Web.Http.WebHost.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Content Include="App_Data\ErrorLog\Readme.txt" />
<Content Include="Content\bootstrap-theme.css" />
<Content Include="Content\bootstrap-theme.min.css" />
<Content Include="Content\bootstrap.css" />
<Content Include="Content\bootstrap.min.css" />
<Content Include="Content\api.css" />
<Content Include="Content\bootstrap-datetimepicker.css" />
<Content Include="Content\bootstrap-datetimepicker.min.css" />
<Content Include="Content\fileinput.css" />
<Content Include="Content\fileinput.min.css" />
<Content Include="Content\IE8.css" />
<Content Include="Content\images\bg2.jpg" />
<Content Include="Content\images\bg4.jpg" />
<Content Include="Content\images\bg3.png" />
<Content Include="Content\login-responsive.css" />
<Content Include="Content\nprogress.css" />
<Content Include="Content\font-awesome.css" />
<Content Include="Content\font-awesome.min.css" />
<Content Include="Content\html\api.html" />
<Content Include="Content\images\error_icon.png" />
<Content Include="Content\toastr.css" />
<Content Include="Content\toastr.min.css" />
<Content Include="favicon.ico" />
<Content Include="Content\admin-responsive.css" />
<Content Include="Content\admin.css" />
<Content Include="Content\blue.css" />
<Content Include="Content\fa.css" />
<Content Include="Content\bootstrap-table.css" />
<Content Include="Content\bootstrap-table.min.css" />
<Content Include="Content\jquery.nestable.css" />
<Content Include="Content\lock.css" />
<Content Include="Content\login.css" />
<Content Include="Content\register.css" />
<Content Include="Content\tasks.css" />
<Content Include="Content\html\RegResult.html" />
<Content Include="Content\images\bg.jpg" />
<Content Include="Content\images\loading-sm.gif" />
<Content Include="Content\images\loading.gif" />
<Content Include="Content\images\lock-bg.jpg" />
<Content Include="Content\images\logo.jpg" />
<Content Include="Content\images\logo1.jpg" />
<Content Include="Content\images\logo2.jpg" />
<Content Include="Content\images\logo3.jpg" />
<Content Include="Content\images\logo4.jpg" />
<Content Include="Content\images\logo5.jpg" />
<Content Include="Content\images\logo6.jpg" />
<Content Include="Content\images\uploader\Admin.jpg" />
<Content Include="Content\images\uploader\default.jpg" />
<Content Include="Content\images\uploader\readme.txt" />
<Content Include="Content\site-responsive.css" />
<Content Include="Content\images\error.png" />
<Content Include="Content\images\nav-expand.png" />
<Content Include="Content\site.css" />
<Content Include="Content\sweetalert.css" />
<Content Include="Content\images\success.png" />
<Content Include="fonts\fontawesome-webfont.svg" />
<Content Include="fonts\glyphicons-halflings-regular.svg" />
<Content Include="Global.asax" />
<Content Include="Scripts\additional-methods.js" />
<Content Include="Scripts\additional-methods.min.js" />
<Content Include="Scripts\bootstrap-datetimepicker.js" />
<Content Include="Scripts\bootstrap-datetimepicker.min.js" />
<Content Include="Scripts\bootstrap-datetimepicker.zh-CN.js" />
<Content Include="Scripts\bootstrap-table-zh-CN.js" />
<Content Include="Scripts\bootstrap-table-zh-CN.min.js" />
<Content Include="Scripts\bootstrap-table.js" />
<Content Include="Scripts\bootstrap-table.min.js" />
<Content Include="Scripts\bootstrap.js" />
<Content Include="Scripts\bootstrap.min.js" />
<Content Include="Scripts\bootstrap3-typeahead.js" />
<Content Include="Scripts\bootstrap3-typeahead.min.js" />
<Content Include="Scripts\common-scripts.js" />
<Content Include="Scripts\Content.js" />
<Content Include="Scripts\Dicts.js" />
<Content Include="Scripts\Exceptions.js" />
<Content Include="Scripts\fileinput.js" />
<Content Include="Scripts\fileinput.min.js" />
<Content Include="Scripts\fileinput.zh.js" />
<Content Include="Scripts\framework.js" />
<Content Include="Scripts\Groups.js" />
<Content Include="Scripts\icon.js" />
<Content Include="Scripts\Profiles.js" />
<Content Include="fonts\glyphicons-halflings-regular.woff2" />
<Content Include="fonts\glyphicons-halflings-regular.woff" />
<Content Include="fonts\glyphicons-halflings-regular.ttf" />
<Content Include="fonts\glyphicons-halflings-regular.eot" />
<Content Include="Content\bootstrap.min.css.map" />
<Content Include="Content\bootstrap.css.map" />
<Content Include="Content\bootstrap-theme.min.css.map" />
<Content Include="Content\bootstrap-theme.css.map" />
<Content Include="fonts\FontAwesome.otf" />
<Content Include="fonts\fontawesome-webfont.woff2" />
<Content Include="fonts\fontawesome-webfont.woff" />
<Content Include="fonts\fontawesome-webfont.ttf" />
<Content Include="fonts\fontawesome-webfont.eot" />
<Content Include="..\..\Keys\Longbow.Utility.snk">
<Link>Longbow.Utility.snk</Link>
</Content>
<None Include="Scripts\jquery-3.1.1.intellisense.js" />
<Content Include="Scripts\jquery-3.1.1.js" />
<Content Include="Scripts\jquery-3.1.1.min.js" />
<Content Include="Scripts\jquery-3.1.1.slim.js" />
<Content Include="Scripts\jquery-3.1.1.slim.min.js" />
<None Include="Scripts\jquery.validate-vsdoc.js" />
<Content Include="Scripts\jquery.dcjqaccordion.2.7.js" />
<Content Include="Scripts\jquery.nestable.js" />
<Content Include="Scripts\jquery.nicescroll.min.js" />
<Content Include="Scripts\jquery.scrollTo.js" />
<Content Include="Scripts\jquery.scrollTo.min.js" />
<Content Include="Scripts\jquery.validate.js" />
<Content Include="Scripts\jquery.validate.min.js" />
<Content Include="Scripts\lock.js" />
<Content Include="Scripts\log.js" />
<Content Include="Scripts\Login.js" />
<Content Include="Scripts\Logs.js" />
<Content Include="Scripts\Longbow.Common.js" />
<Content Include="Scripts\longbow.dataentity.js" />
<Content Include="Scripts\Menus.js" />
<Content Include="Scripts\message.js" />
<Content Include="Scripts\messages_zh.js" />
<Content Include="Scripts\messages_zh.min.js" />
<Content Include="Scripts\noti.js" />
<Content Include="Scripts\nprogress.js" />
<Content Include="Scripts\Settings.js" />
<Content Include="Scripts\register.js" />
<Content Include="Scripts\Roles.js" />
<Content Include="Scripts\sweetalert.js" />
<Content Include="Scripts\sweetalert.min.js" />
<Content Include="Scripts\tasks.js" />
<Content Include="Scripts\apidoc.js" />
<Content Include="Scripts\toastr.min.js" />
<Content Include="Scripts\Users.js" />
<Content Include="packages.config" />
<Content Include="Scripts\jquery-3.1.1.slim.min.map" />
<Content Include="Scripts\jquery-3.1.1.min.map" />
<Content Include="Views\Shared\Readme.txt" />
<Content Include="Web.config">
<SubType>Designer</SubType>
</Content>
<Content Include="Views\Shared\_Layout.cshtml" />
<Content Include="Views\Home\Index.cshtml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\bldver.cs">
<Link>bldver.cs</Link>
</Compile>
<Compile Include="App_Start\DBPublisher.cs" />
<Compile Include="App_Start\FilterConfig.cs" />
<Compile Include="App_Start\RouteConfig.cs" />
<Compile Include="App_Start\WebApiConfig.cs" />
<Compile Include="Controllers\AdminController.cs" />
<Compile Include="Controllers\DictsController.cs" />
<Compile Include="Controllers\ExceptionsController.cs" />
<Compile Include="Controllers\GroupsController.cs" />
<Compile Include="Controllers\HomeController.cs" />
<Compile Include="Controllers\ProfilesController.cs" />
<Compile Include="Controllers\LoginController.cs" />
<Compile Include="Controllers\LogsController.cs" />
<Compile Include="Controllers\MenusController.cs" />
<Compile Include="Controllers\MessagesController.cs" />
<Compile Include="Controllers\NotificationsController.cs" />
<Compile Include="Controllers\SettingsController.cs" />
<Compile Include="Controllers\RolesController.cs" />
<Compile Include="Controllers\TasksController.cs" />
<Compile Include="Controllers\UsersController.cs" />
<Compile Include="Controllers\WSController.cs" />
<Compile Include="Global.asax.cs">
<DependentUpon>Global.asax</DependentUpon>
</Compile>
<Compile Include="Models\ProfilesModel.cs" />
<Compile Include="Models\LockModel.cs" />
<Compile Include="Models\MessageCountModel.cs" />
<Compile Include="Models\QueryDictOption.cs" />
<Compile Include="Models\QueryExceptionOption.cs" />
<Compile Include="Models\QueryGroupOption.cs" />
<Compile Include="Models\QueryLogOption.cs" />
<Compile Include="Models\QueryMenuOption.cs" />
<Compile Include="Models\QueryRoleOption.cs" />
<Compile Include="Models\QueryUserOption.cs" />
<Compile Include="Models\HeaderBarModel.cs" />
<Compile Include="Models\LoginModel.cs" />
<Compile Include="Models\ModelBase.cs" />
<Compile Include="Models\NavigatorBarModel.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<Content Include="Views\web.config" />
<Content Include="Views\Shared\_Normal.cshtml" />
<Content Include="Views\Shared\_Admin.cshtml" />
<Content Include="Views\Admin\Index.cshtml" />
<Content Include="Views\Shared\_Default.cshtml" />
<Content Include="Views\Admin\Users.cshtml" />
<Content Include="Views\_ViewStart.cshtml" />
<Content Include="Views\Shared\Header.cshtml" />
<Content Include="Views\Shared\Navigator.cshtml" />
<Content Include="Views\Home\Login.cshtml" />
<Content Include="Views\Shared\UnAuthorized.cshtml" />
<Content Include="Views\Shared\AwesomeIcon.cshtml" />
<Content Include="Views\Admin\FAIcon.cshtml" />
<Content Include="Views\Admin\Groups.cshtml" />
<Content Include="Views\Admin\Roles.cshtml" />
<Content Include="Views\Admin\Menus.cshtml" />
<Content Include="Views\Admin\Dicts.cshtml" />
<Content Include="Views\Shared\RoleConfig.cshtml" />
<Content Include="Views\Shared\IconView.cshtml" />
<Content Include="Views\Shared\UserConfig.cshtml" />
<Content Include="Views\Shared\GroupConfig.cshtml" />
<Content Include="Views\Admin\Logs.cshtml" />
<Content Include="Views\Admin\Settings.cshtml" />
<Content Include="Views\Shared\Footer.cshtml" />
<Content Include="Views\Shared\NavigatorConfig.cshtml" />
<Content Include="Views\Shared\SubNavigation.cshtml" />
<Content Include="Views\Home\Lock.cshtml" />
<Content Include="Views\Home\Register.cshtml" />
<Content Include="Views\Admin\Notifications.cshtml" />
<Content Include="Views\Admin\Profiles.cshtml" />
<Content Include="Views\Admin\Exceptions.cshtml" />
<Content Include="Views\Admin\Messages.cshtml" />
<Content Include="Views\Admin\Tasks.cshtml" />
<Content Include="Views\Admin\Mobile.cshtml" />
<Content Include="Views\Shared\_Mobile.cshtml" />
<Content Include="Views\Home\Mobile.cshtml" />
<Content Include="Views\Shared\SubMenu.cshtml" />
<Content Include="Views\Admin\Api.cshtml" />
<Content Include="Views\Shared\_ButtonBarGroup.cshtml" />
<Content Include="Scripts\toastr.js.map" />
<None Include="Web.Debug.config">
<DependentUpon>Web.config</DependentUpon>
</None>
<None Include="Web.Release.config">
<DependentUpon>Web.config</DependentUpon>
</None>
</ItemGroup>
<ItemGroup />
<ItemGroup>
<ProjectReference Include="..\Bootstrap.DataAccess\Bootstrap.DataAccess.csproj">
<Project>{af16ca71-b8c6-4f51-b38c-0c0300fdebd7}</Project>
<Name>Bootstrap.DataAccess</Name>
</ProjectReference>
</ItemGroup>
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
</PropertyGroup>
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>netcoreapp2.1</TargetFramework>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>..\Keys\Longbow.Utility.snk</AssemblyOriginatorKeyFile>
<MvcRazorCompileOnPublish>true</MvcRazorCompileOnPublish>
</PropertyGroup>
<PropertyGroup>
<AssemblyOriginatorKeyFile>..\..\Keys\Longbow.Utility.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<PropertyGroup>
<DelaySign>false</DelaySign>
</PropertyGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<Import Project="$(VSToolsPath)\WebApplications\Microsoft.WebApplication.targets" Condition="'$(VSToolsPath)' != ''" />
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" Condition="false" />
<ProjectExtensions>
<VisualStudio>
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
<WebProjectProperties>
<UseIIS>True</UseIIS>
<AutoAssignPort>True</AutoAssignPort>
<DevelopmentServerPort>53737</DevelopmentServerPort>
<DevelopmentServerVPath>/</DevelopmentServerVPath>
<IISUrl>http://localhost:53233/</IISUrl>
<NTLMAuthentication>False</NTLMAuthentication>
<UseCustomServer>False</UseCustomServer>
<CustomServerUrl>
</CustomServerUrl>
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
</WebProjectProperties>
</FlavorProperties>
</VisualStudio>
</ProjectExtensions>
<PropertyGroup>
<PostBuildEvent>cscript /Nologo $(SolutionDir)Scripts\Publish.vbs $(TargetDir) $(TargetName) $(TargetExt) $(SolutionDir) $(OutDir) $(ConfigurationName)</PostBuildEvent>
</PropertyGroup>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
<ItemGroup>
<PackageReference Include="Bootstrap.Security.Mvc" Version="1.0.0" />
<PackageReference Include="Longbow.Web" Version="1.0.1" />
<PackageReference Include="Microsoft.AspNetCore.App" />
<PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="2.1.0" PrivateAssets="All" />
</ItemGroup>
<ItemGroup>
<None Include="..\Keys\Longbow.Utility.snk" Link="Longbow.Utility.snk" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Bootstrap.DataAccess\Bootstrap.DataAccess.csproj" />
</ItemGroup>
<ItemGroup>
<Content Update="wwwroot\css\bootstrap.css">
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content>
<Content Update="wwwroot\css\bootstrap.min.css">
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content>
</ItemGroup>
</Project>

View File

@ -1 +0,0 @@


File diff suppressed because one or more lines are too long

View File

@ -1,587 +0,0 @@
/*!
* Bootstrap v3.3.7 (http://getbootstrap.com)
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*/
.btn-default,
.btn-primary,
.btn-success,
.btn-info,
.btn-warning,
.btn-danger {
text-shadow: 0 -1px 0 rgba(0, 0, 0, .2);
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);
}
.btn-default:active,
.btn-primary:active,
.btn-success:active,
.btn-info:active,
.btn-warning:active,
.btn-danger:active,
.btn-default.active,
.btn-primary.active,
.btn-success.active,
.btn-info.active,
.btn-warning.active,
.btn-danger.active {
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-default.disabled,
.btn-primary.disabled,
.btn-success.disabled,
.btn-info.disabled,
.btn-warning.disabled,
.btn-danger.disabled,
.btn-default[disabled],
.btn-primary[disabled],
.btn-success[disabled],
.btn-info[disabled],
.btn-warning[disabled],
.btn-danger[disabled],
fieldset[disabled] .btn-default,
fieldset[disabled] .btn-primary,
fieldset[disabled] .btn-success,
fieldset[disabled] .btn-info,
fieldset[disabled] .btn-warning,
fieldset[disabled] .btn-danger {
-webkit-box-shadow: none;
box-shadow: none;
}
.btn-default .badge,
.btn-primary .badge,
.btn-success .badge,
.btn-info .badge,
.btn-warning .badge,
.btn-danger .badge {
text-shadow: none;
}
.btn:active,
.btn.active {
background-image: none;
}
.btn-default {
text-shadow: 0 1px 0 #fff;
background-image: -webkit-linear-gradient(top, #fff 0%, #e0e0e0 100%);
background-image: -o-linear-gradient(top, #fff 0%, #e0e0e0 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#e0e0e0));
background-image: linear-gradient(to bottom, #fff 0%, #e0e0e0 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #dbdbdb;
border-color: #ccc;
}
.btn-default:hover,
.btn-default:focus {
background-color: #e0e0e0;
background-position: 0 -15px;
}
.btn-default:active,
.btn-default.active {
background-color: #e0e0e0;
border-color: #dbdbdb;
}
.btn-default.disabled,
.btn-default[disabled],
fieldset[disabled] .btn-default,
.btn-default.disabled:hover,
.btn-default[disabled]:hover,
fieldset[disabled] .btn-default:hover,
.btn-default.disabled:focus,
.btn-default[disabled]:focus,
fieldset[disabled] .btn-default:focus,
.btn-default.disabled.focus,
.btn-default[disabled].focus,
fieldset[disabled] .btn-default.focus,
.btn-default.disabled:active,
.btn-default[disabled]:active,
fieldset[disabled] .btn-default:active,
.btn-default.disabled.active,
.btn-default[disabled].active,
fieldset[disabled] .btn-default.active {
background-color: #e0e0e0;
background-image: none;
}
.btn-primary {
background-image: -webkit-linear-gradient(top, #337ab7 0%, #265a88 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #265a88 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#265a88));
background-image: linear-gradient(to bottom, #337ab7 0%, #265a88 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff265a88', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #245580;
}
.btn-primary:hover,
.btn-primary:focus {
background-color: #265a88;
background-position: 0 -15px;
}
.btn-primary:active,
.btn-primary.active {
background-color: #265a88;
border-color: #245580;
}
.btn-primary.disabled,
.btn-primary[disabled],
fieldset[disabled] .btn-primary,
.btn-primary.disabled:hover,
.btn-primary[disabled]:hover,
fieldset[disabled] .btn-primary:hover,
.btn-primary.disabled:focus,
.btn-primary[disabled]:focus,
fieldset[disabled] .btn-primary:focus,
.btn-primary.disabled.focus,
.btn-primary[disabled].focus,
fieldset[disabled] .btn-primary.focus,
.btn-primary.disabled:active,
.btn-primary[disabled]:active,
fieldset[disabled] .btn-primary:active,
.btn-primary.disabled.active,
.btn-primary[disabled].active,
fieldset[disabled] .btn-primary.active {
background-color: #265a88;
background-image: none;
}
.btn-success {
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #419641 100%);
background-image: -o-linear-gradient(top, #5cb85c 0%, #419641 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#419641));
background-image: linear-gradient(to bottom, #5cb85c 0%, #419641 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #3e8f3e;
}
.btn-success:hover,
.btn-success:focus {
background-color: #419641;
background-position: 0 -15px;
}
.btn-success:active,
.btn-success.active {
background-color: #419641;
border-color: #3e8f3e;
}
.btn-success.disabled,
.btn-success[disabled],
fieldset[disabled] .btn-success,
.btn-success.disabled:hover,
.btn-success[disabled]:hover,
fieldset[disabled] .btn-success:hover,
.btn-success.disabled:focus,
.btn-success[disabled]:focus,
fieldset[disabled] .btn-success:focus,
.btn-success.disabled.focus,
.btn-success[disabled].focus,
fieldset[disabled] .btn-success.focus,
.btn-success.disabled:active,
.btn-success[disabled]:active,
fieldset[disabled] .btn-success:active,
.btn-success.disabled.active,
.btn-success[disabled].active,
fieldset[disabled] .btn-success.active {
background-color: #419641;
background-image: none;
}
.btn-info {
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
background-image: -o-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#2aabd2));
background-image: linear-gradient(to bottom, #5bc0de 0%, #2aabd2 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #28a4c9;
}
.btn-info:hover,
.btn-info:focus {
background-color: #2aabd2;
background-position: 0 -15px;
}
.btn-info:active,
.btn-info.active {
background-color: #2aabd2;
border-color: #28a4c9;
}
.btn-info.disabled,
.btn-info[disabled],
fieldset[disabled] .btn-info,
.btn-info.disabled:hover,
.btn-info[disabled]:hover,
fieldset[disabled] .btn-info:hover,
.btn-info.disabled:focus,
.btn-info[disabled]:focus,
fieldset[disabled] .btn-info:focus,
.btn-info.disabled.focus,
.btn-info[disabled].focus,
fieldset[disabled] .btn-info.focus,
.btn-info.disabled:active,
.btn-info[disabled]:active,
fieldset[disabled] .btn-info:active,
.btn-info.disabled.active,
.btn-info[disabled].active,
fieldset[disabled] .btn-info.active {
background-color: #2aabd2;
background-image: none;
}
.btn-warning {
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
background-image: -o-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#eb9316));
background-image: linear-gradient(to bottom, #f0ad4e 0%, #eb9316 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #e38d13;
}
.btn-warning:hover,
.btn-warning:focus {
background-color: #eb9316;
background-position: 0 -15px;
}
.btn-warning:active,
.btn-warning.active {
background-color: #eb9316;
border-color: #e38d13;
}
.btn-warning.disabled,
.btn-warning[disabled],
fieldset[disabled] .btn-warning,
.btn-warning.disabled:hover,
.btn-warning[disabled]:hover,
fieldset[disabled] .btn-warning:hover,
.btn-warning.disabled:focus,
.btn-warning[disabled]:focus,
fieldset[disabled] .btn-warning:focus,
.btn-warning.disabled.focus,
.btn-warning[disabled].focus,
fieldset[disabled] .btn-warning.focus,
.btn-warning.disabled:active,
.btn-warning[disabled]:active,
fieldset[disabled] .btn-warning:active,
.btn-warning.disabled.active,
.btn-warning[disabled].active,
fieldset[disabled] .btn-warning.active {
background-color: #eb9316;
background-image: none;
}
.btn-danger {
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
background-image: -o-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c12e2a));
background-image: linear-gradient(to bottom, #d9534f 0%, #c12e2a 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-color: #b92c28;
}
.btn-danger:hover,
.btn-danger:focus {
background-color: #c12e2a;
background-position: 0 -15px;
}
.btn-danger:active,
.btn-danger.active {
background-color: #c12e2a;
border-color: #b92c28;
}
.btn-danger.disabled,
.btn-danger[disabled],
fieldset[disabled] .btn-danger,
.btn-danger.disabled:hover,
.btn-danger[disabled]:hover,
fieldset[disabled] .btn-danger:hover,
.btn-danger.disabled:focus,
.btn-danger[disabled]:focus,
fieldset[disabled] .btn-danger:focus,
.btn-danger.disabled.focus,
.btn-danger[disabled].focus,
fieldset[disabled] .btn-danger.focus,
.btn-danger.disabled:active,
.btn-danger[disabled]:active,
fieldset[disabled] .btn-danger:active,
.btn-danger.disabled.active,
.btn-danger[disabled].active,
fieldset[disabled] .btn-danger.active {
background-color: #c12e2a;
background-image: none;
}
.thumbnail,
.img-thumbnail {
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
}
.dropdown-menu > li > a:hover,
.dropdown-menu > li > a:focus {
background-color: #e8e8e8;
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
background-repeat: repeat-x;
}
.dropdown-menu > .active > a,
.dropdown-menu > .active > a:hover,
.dropdown-menu > .active > a:focus {
background-color: #2e6da4;
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
background-repeat: repeat-x;
}
.navbar-default {
background-image: -webkit-linear-gradient(top, #fff 0%, #f8f8f8 100%);
background-image: -o-linear-gradient(top, #fff 0%, #f8f8f8 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#f8f8f8));
background-image: linear-gradient(to bottom, #fff 0%, #f8f8f8 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-radius: 4px;
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075);
}
.navbar-default .navbar-nav > .open > a,
.navbar-default .navbar-nav > .active > a {
background-image: -webkit-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
background-image: -o-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#dbdbdb), to(#e2e2e2));
background-image: linear-gradient(to bottom, #dbdbdb 0%, #e2e2e2 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdbdbdb', endColorstr='#ffe2e2e2', GradientType=0);
background-repeat: repeat-x;
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075);
}
.navbar-brand,
.navbar-nav > li > a {
text-shadow: 0 1px 0 rgba(255, 255, 255, .25);
}
.navbar-inverse {
background-image: -webkit-linear-gradient(top, #3c3c3c 0%, #222 100%);
background-image: -o-linear-gradient(top, #3c3c3c 0%, #222 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#3c3c3c), to(#222));
background-image: linear-gradient(to bottom, #3c3c3c 0%, #222 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
background-repeat: repeat-x;
border-radius: 4px;
}
.navbar-inverse .navbar-nav > .open > a,
.navbar-inverse .navbar-nav > .active > a {
background-image: -webkit-linear-gradient(top, #080808 0%, #0f0f0f 100%);
background-image: -o-linear-gradient(top, #080808 0%, #0f0f0f 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#080808), to(#0f0f0f));
background-image: linear-gradient(to bottom, #080808 0%, #0f0f0f 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff080808', endColorstr='#ff0f0f0f', GradientType=0);
background-repeat: repeat-x;
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25);
}
.navbar-inverse .navbar-brand,
.navbar-inverse .navbar-nav > li > a {
text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
}
.navbar-static-top,
.navbar-fixed-top,
.navbar-fixed-bottom {
border-radius: 0;
}
@media (max-width: 767px) {
.navbar .navbar-nav .open .dropdown-menu > .active > a,
.navbar .navbar-nav .open .dropdown-menu > .active > a:hover,
.navbar .navbar-nav .open .dropdown-menu > .active > a:focus {
color: #fff;
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
background-repeat: repeat-x;
}
}
.alert {
text-shadow: 0 1px 0 rgba(255, 255, 255, .2);
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05);
}
.alert-success {
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
background-image: -o-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#c8e5bc));
background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);
background-repeat: repeat-x;
border-color: #b2dba1;
}
.alert-info {
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
background-image: -o-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#b9def0));
background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);
background-repeat: repeat-x;
border-color: #9acfea;
}
.alert-warning {
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
background-image: -o-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#f8efc0));
background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);
background-repeat: repeat-x;
border-color: #f5e79e;
}
.alert-danger {
background-image: -webkit-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
background-image: -o-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#e7c3c3));
background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);
background-repeat: repeat-x;
border-color: #dca7a7;
}
.progress {
background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
background-image: -o-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#f5f5f5));
background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar {
background-image: -webkit-linear-gradient(top, #337ab7 0%, #286090 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #286090 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#286090));
background-image: linear-gradient(to bottom, #337ab7 0%, #286090 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff286090', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-success {
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #449d44 100%);
background-image: -o-linear-gradient(top, #5cb85c 0%, #449d44 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#449d44));
background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-info {
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
background-image: -o-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#31b0d5));
background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-warning {
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
background-image: -o-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#ec971f));
background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-danger {
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c9302c 100%);
background-image: -o-linear-gradient(top, #d9534f 0%, #c9302c 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c9302c));
background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);
background-repeat: repeat-x;
}
.progress-bar-striped {
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
}
.list-group {
border-radius: 4px;
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
box-shadow: 0 1px 2px rgba(0, 0, 0, .075);
}
.list-group-item.active,
.list-group-item.active:hover,
.list-group-item.active:focus {
text-shadow: 0 -1px 0 #286090;
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2b669a 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2b669a 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2b669a));
background-image: linear-gradient(to bottom, #337ab7 0%, #2b669a 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2b669a', GradientType=0);
background-repeat: repeat-x;
border-color: #2b669a;
}
.list-group-item.active .badge,
.list-group-item.active:hover .badge,
.list-group-item.active:focus .badge {
text-shadow: none;
}
.panel {
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
box-shadow: 0 1px 2px rgba(0, 0, 0, .05);
}
.panel-default > .panel-heading {
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
background-repeat: repeat-x;
}
.panel-primary > .panel-heading {
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
background-repeat: repeat-x;
}
.panel-success > .panel-heading {
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
background-image: -o-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#d0e9c6));
background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);
background-repeat: repeat-x;
}
.panel-info > .panel-heading {
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
background-image: -o-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#c4e3f3));
background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);
background-repeat: repeat-x;
}
.panel-warning > .panel-heading {
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
background-image: -o-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#faf2cc));
background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);
background-repeat: repeat-x;
}
.panel-danger > .panel-heading {
background-image: -webkit-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
background-image: -o-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#ebcccc));
background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);
background-repeat: repeat-x;
}
.well {
background-image: -webkit-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
background-image: -o-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
background-image: -webkit-gradient(linear, left top, left bottom, from(#e8e8e8), to(#f5f5f5));
background-image: linear-gradient(to bottom, #e8e8e8 0%, #f5f5f5 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);
background-repeat: repeat-x;
border-color: #dcdcdc;
-webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1);
}
/*# sourceMappingURL=bootstrap-theme.css.map */

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,401 +0,0 @@
/*!
* bootstrap-fileinput v4.3.6
* http://plugins.krajee.com/file-input
*
* Author: Kartik Visweswaran
* Copyright: 2014 - 2016, Kartik Visweswaran, Krajee.com
*
* Licensed under the BSD 3-Clause
* https://github.com/kartik-v/bootstrap-fileinput/blob/master/LICENSE.md
*/
.file-loading {
top: 0;
right: 0;
width: 25px;
height: 25px;
font-size: 999px;
text-align: right;
color: #fff;
background: transparent url('images/loading.gif') top left no-repeat;
border: none;
}
.file-object {
margin: 0 0 -5px 0;
padding: 0;
}
.btn-file {
position: relative;
overflow: hidden;
}
.btn-file input[type=file] {
position: absolute;
top: 0;
right: 0;
min-width: 100%;
min-height: 100%;
text-align: right;
opacity: 0;
background: none repeat scroll 0 0 transparent;
cursor: inherit;
display: block;
}
.file-caption-name {
display: inline-block;
overflow: hidden;
height: 20px;
word-break: break-all;
}
.input-group-lg .file-caption-name {
height: 25px;
}
.file-zoom-dialog {
text-align: left;
}
.file-error-message {
color: #a94442;
background-color: #f2dede;
margin: 5px;
border: 1px solid #ebccd1;
border-radius: 4px;
padding: 15px;
}
.file-error-message pre, .file-error-message ul {
margin: 0;
text-align: left;
}
.file-error-message pre {
margin: 5px 0;
}
.file-caption-disabled {
background-color: #EEEEEE;
cursor: not-allowed;
opacity: 1;
}
.file-preview {
border-radius: 5px;
border: 1px solid #ddd;
padding: 5px;
width: 100%;
margin-bottom: 5px;
}
.file-preview-frame {
position: relative;
display: table;
margin: 8px;
height: 160px;
border: 1px solid #ddd;
box-shadow: 1px 1px 5px 0 #a2958a;
padding: 6px;
float: left;
text-align: center;
vertical-align: middle;
}
.file-preview-frame:not(.file-preview-error):hover {
box-shadow: 3px 3px 5px 0 #333;
}
.file-preview-image {
vertical-align: middle;
image-orientation: from-image;
}
.file-preview-text {
display: block;
color: #428bca;
border: 1px solid #ddd;
font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
outline: none;
padding: 8px;
resize: none;
}
.file-preview-html {
border: 1px solid #ddd;
padding: 8px;
overflow: auto;
}
.file-zoom-dialog .file-preview-text {
font-size: 1.2em;
}
.file-preview-other {
left: 0;
top: 0;
right: 0;
bottom: 0;
margin: auto;
text-align: center;
vertical-align: middle;
padding: 10px;
}
.file-preview-other:hover {
opacity: 0.8;
}
.file-actions, .file-other-error {
text-align: left;
}
.file-other-icon {
font-size: 4.8em;
}
/* noinspection CssOverwrittenProperties */
.file-zoom-dialog .file-other-icon {
font-size: 8em;
font-size: 55vmin;
}
.file-input-new .file-preview, .file-input-new .close, .file-input-new .glyphicon-file,
.file-input-new .fileinput-remove-button, .file-input-new .fileinput-upload-button,
.file-input-ajax-new .fileinput-remove-button, .file-input-ajax-new .fileinput-upload-button {
display: none;
}
.file-caption-main {
width: 100%;
}
.file-input-ajax-new .no-browse .input-group-btn,
.file-input-new .no-browse .input-group-btn {
display: none;
}
.file-input-ajax-new .no-browse .form-control,
.file-input-new .no-browse .form-control {
border-top-right-radius: 4px;
border-bottom-right-radius: 4px;
}
.file-thumb-loading {
background: transparent url('images/loading.gif') no-repeat scroll center center content-box !important;
}
.file-actions {
margin-top: 15px;
}
.file-footer-buttons {
float: right;
}
.file-upload-indicator {
display: inline;
cursor: default;
opacity: 0.8;
width: 60%;
}
.file-upload-indicator:hover {
font-weight: bold;
opacity: 1;
}
.file-footer-caption {
display: block;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
width: 160px;
text-align: center;
padding-top: 4px;
font-size: 11px;
color: #777;
margin: 5px auto;
}
.file-preview-error {
opacity: 0.65;
box-shadow: none;
}
.file-preview-frame:not(.file-preview-error) .file-footer-caption:hover {
color: #000;
}
.file-drop-zone {
border: 1px dashed #aaa;
border-radius: 4px;
height: 100%;
text-align: center;
vertical-align: middle;
margin: 12px 15px 12px 12px;
padding: 5px;
}
.file-drop-zone-title {
color: #aaa;
font-size: 1.6em;
padding: 85px 10px;
cursor: default;
}
.file-preview .clickable,
.clickable .file-drop-zone-title {
cursor: pointer;
}
.file-drop-zone.clickable:hover {
border: 2px dashed #999;
}
.file-drop-zone.clickable:focus {
border: 2px solid #5acde2;
}
.file-drop-zone .file-preview-thumbnails {
cursor: default;
}
.file-highlighted {
border: 2px dashed #999 !important;
background-color: #f0f0f0;
}
.file-uploading {
background: url('../images/loading-sm.gif') no-repeat center bottom 10px;
opacity: 0.65;
}
.file-thumb-progress {
height: 10px;
}
.file-thumb-progress .progress, .file-thumb-progress .progress-bar {
height: 10px;
font-size: 9px;
line-height: 10px;
}
.file-thumbnail-footer {
position: relative;
}
.file-thumb-progress {
position: absolute;
top: 35px;
left: 0;
right: 0;
}
.file-zoom-fullscreen.modal {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
}
.file-zoom-fullscreen .modal-dialog {
position: fixed;
margin: 0;
width: 100%;
height: 100%;
padding: 0;
}
.file-zoom-fullscreen .modal-content {
border-radius: 0;
box-shadow: none;
}
.file-zoom-fullscreen .modal-body {
overflow-y: auto;
}
.file-zoom-dialog .modal-body {
position: relative !important;
}
.file-zoom-dialog .btn-navigate {
position: absolute;
padding: 0;
margin: 0;
background: transparent;
text-decoration: none;
outline: none;
opacity: 0.7;
top: 45%;
font-size: 4em;
color: #1c94c4;
}
.file-zoom-dialog .floating-buttons {
position: absolute;
top: 5px;
right: 10px;
}
.floating-buttons, .floating-buttons .btn {
z-index: 3000;
}
.file-zoom-dialog .kv-zoom-actions .btn,
.floating-buttons .btn {
margin-left: 3px;
}
.file-zoom-dialog .btn-navigate:not([disabled]):hover,
.file-zoom-dialog .btn-navigate:not([disabled]):focus {
outline: none;
box-shadow: none;
opacity: 0.5;
}
.file-zoom-dialog .btn-navigate[disabled] {
opacity: 0.3;
}
.file-zoom-dialog .btn-prev {
left: 1px;
}
.file-zoom-dialog .btn-next {
right: 1px;
}
.file-drag-handle {
display: inline;
margin-right: 2px;
font-size: 16px;
cursor: move;
cursor: -webkit-grabbing;
}
.file-drag-handle:hover {
opacity: 0.7;
}
.file-zoom-content {
height: 480px;
text-align: center;
}
.file-preview-initial.sortable-chosen {
background-color: #d9edf7;
}
.file-preview-frame.sortable-ghost {
background-color: #eee;
}
/* IE 10 fix */
.btn-file ::-ms-browse {
width: 100%;
height: 100%;
}

File diff suppressed because one or more lines are too long

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.3 KiB

View File

@ -1 +0,0 @@
请不要删除此目录

View File

@ -1,104 +0,0 @@
.lock-screen {
background: #02bac6 url("images/lock-bg.jpg");
background-size: cover;
background-repeat: repeat;
}
.lock-wrapper {
margin: 6% auto;
max-width: 330px;
}
.lock-box {
background: rgba(255,255,255,.3);
padding: 20px;
border-radius: 10px;
-webkit-border-radius: 10px;
position: relative;
}
.lock-box .form-group {
float: inherit !important;
}
.lock-wrapper img {
border-radius: 50%;
-webkit-border-radius: 50%;
border: 5px solid #fff;
width: 250px;
height: 250px;
}
.lock-wrapper h1 {
text-align: center;
color: #fff;
font-size: 18px;
text-transform: uppercase;
padding: 20px 0 0 0;
}
.lock-wrapper .locked {
margin-bottom: 20px;
display: inline-block;
color: #026f7a;
}
.btn-lock, .btn-lock:hover {
background: #02b5c2;
color: #fff;
}
.lock-input {
width: 83%;
border: none;
float: left;
margin-right: 3px;
}
#time {
width: 100%;
color: #fff;
font-size: 60px;
display: inline-block;
text-align: center;
font-family: 'Open Sans', sans-serif;
font-weight: 300;
}
.btn-lock, .btn-lock:hover {
background: #02b5c2;
color: #fff;
outline: none !important;
border-color: #2e6da4;
border-left: none;
}
.has-error .btn-lock {
color: #a94442;
background-color: #f2dede;
border-color: #a94442;
}
.has-success .btn-lock {
color: #3c763d;
background-color: #dff0d8;
border-color: #3c763d;
}
div.input-group span {
top: 0;
background: #02b5c2;
border-color: #2e6da4;
color: #fff;
}
div.input-group input, div.input-group input:hover, div.input-group input:focus {
border-color: #2e6da4;
border-left: none;
border-right: none;
}
div.input-group input.error {
background-color: #dcc4c4;
border-color: #e21717;
}

View File

@ -1,91 +0,0 @@
body {
background: url('images/bg4.jpg') fixed repeat;
}
.form-signin {
margin: 0 auto;
border-radius: 5px;
border: solid 1px #1a88a9;
background: rgba(255, 255, 255, 0.23);
}
.form-signin .form-signin-heading {
margin: 0;
padding: 15px;
text-align: center;
background: rgba(0, 0, 0, 0.57);
border-radius: 5px 5px 0 0;
color: #fff;
font-size: 32px;
text-transform: uppercase;
font-weight: 300;
}
.form-signin .login-wrap {
padding: 20px;
}
.form-signin .login-wrap .login-footer {
padding-bottom: 15px;
}
.form-signin .login-wrap .login-footer .login-create {
float: left;
}
.form-signin .login-wrap .login-footer .login-reset {
float: right;
}
.form-signin .input-group {
margin-bottom: 15px;
border-radius: 5px;
border: 1px solid #089dc9;
box-shadow: none;
font-size: 12px;
}
.form-signin .input-group > span {
top: 0;
background-color: #5bc0de;
}
.form-signin .form-control, .form-signin .input-group span {
border: none;
}
.form-signin .has-success .input-group {
border: solid 1px #3c763d;
}
.form-signin .has-error .input-group {
border: solid 1px #a94442;
}
.form-signin .form-control, .form-signin .form-control:focus {
box-shadow: none;
}
.form-signin .btn-login {
background: #f67a6e;
color: #fff;
text-transform: uppercase;
font-weight: 300;
font-family: 'Open Sans', sans-serif;
box-shadow: 0 4px #e56b60;
margin-bottom: 20px;
outline: none !important;
}
.form-signin .checkbox {
padding-left: 24px;
}
.form-signin .checkbox > input {
top: -1px;
}
.form-signin .checkbox > label {
padding-left: 4px;
color: #333;
}

View File

@ -1,466 +0,0 @@
html {
font-size: 62.5%;
}
body {
color: #797979;
background: #f1f2f7;
font-family: 'Open Sans', sans-serif;
font-size: 1.4rem;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-webkit-overflow-scrolling: touch;
}
ul li {
list-style: none;
}
a, a:hover, a:focus {
text-decoration: none;
outline: none;
}
.dropdown-menu {
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.176);
padding: 0;
}
.dropdown-menu > li > a {
padding: 6px 20px;
}
.dropdown-menu .divider {
margin: 1px 0;
}
.card-view:not(:last-child) {
margin-bottom: 6px;
}
.header {
padding: 0 15px;
height: 98px;
background: #fff;
border-bottom: 1px solid #ddd;
top: 0;
left: 0;
right: 0;
}
.header .bg {
background-color: #337ab7;
height: 4px;
margin: 0 -15px;
}
.header a {
transition: all .25s linear;
}
.header > .dropdown {
margin-top: 7px;
float: right;
}
.header > .dropdown > a {
border: 1px solid #eee;
border-radius: 4px;
padding: 6px;
background: none;
margin-right: 0;
display: block;
white-space: nowrap;
color: #777;
}
.header > .dropdown > a:hover, .header > .dropdown.open > a, .notify-row > li > a:hover {
border: 1px solid #777;
color: #333
}
.header > .dropdown > a span {
display: inline-block;
min-width: 18px;
}
.header > .dropdown > a img {
height: 29px;
width: 29px;
}
.header > .dropdown .dropdown-menu {
width: 268px;
top: 50px;
left: auto;
right: 0;
}
.header > .dropdown .dropdown-menu li {
text-align: center;
width: 33.3%;
float: left;
}
.header > .dropdown .dropdown-menu li:first-child {
border-color: transparent transparent #e8e8e8;
border-bottom-color: #e8e8e8;
border-top-color: #e8e8e8;
border-style: solid;
border-width: 0 7px 7px;
position: absolute;
right: 20px;
top: -8px;
width: 0;
}
.header > .dropdown .dropdown-menu li:last-child {
width: 100%;
}
.header > .dropdown .dropdown-menu li:last-child a {
color: #ca3a39;
border-radius: 0 0 3px 3px;
background: #a9d96c;
background-image: linear-gradient(to bottom, #a9d96c 0%, #799e51 100%);
}
.header > .dropdown .dropdown-menu li:last-child a:hover {
color: #d20100;
background: #6d9046;
background-image: linear-gradient(to bottom, #a9d96c 0%, #6d9046 100%);
}
.header > .dropdown .dropdown-menu li a {
color: #777;
padding: 15px 10px;
}
.header > .dropdown .dropdown-menu li a:hover {
color: #333;
}
.header > .dropdown .dropdown-menu li a i {
font-size: 1.7rem;
display: block;
margin-bottom: 4px;
}
.header > .dropdown .dropdown-menu li a .badge {
position: absolute;
right: 20px;
top: 4px;
background: #5cb85c;
}
/*Title*/
.sidebar-toggle-box {
font-size: 2.1rem;
color: #333;
float: left;
margin-top: 15px;
}
.sidebar-toggle-box span, .notify-row {
display: none;
}
/*end title*/
.site-footer {
background: #5b6e84;
color: #fff;
padding: 10px 4px;
height: 40px;
left: 0;
bottom: 0;
right: 0;
white-space: nowrap;
}
.go-top {
background: rgba(255,255,255,.5);
width: 20px;
height: 20px;
border-radius: 50%;
-webkit-border-radius: 50%;
position: absolute;
right: 10px;
}
.go-top:hover {
background-color: white;
}
.go-top i {
color: #2A3542;
}
/*notify bar*/
.notify-row {
margin-top: 20px;
padding-left: 20px;
}
.notify-row .bg-success, .notify-row .dropdown-menu.tasks-bar li p {
background: #a9d86e;
}
.notify-row .bg-important, .notify-row .dropdown-menu.inbox li p {
background: #ff6c60;
}
.notify-row .bg-user, .notify-row .dropdown-menu.users li p {
background: #5cb85c;
}
.notify-row .bg-warning, .notify-row .dropdown-menu.notification li p {
background: #FCB322;
}
.notify-row .bg-db, .notify-row .dropdown-menu.dbs li p {
background: #d03633;
}
.notify-row > li {
float: left;
position: relative;
display: block;
}
.notify-row > li > a {
color: #666666;
border-radius: 4px;
-webkit-border-radius: 4px;
font-size: 1.6rem;
border: 1px solid #f0f0f8;
padding: 2px 6px;
margin-right: 15px;
}
.notify-row > li > a .badge {
position: absolute;
top: -10px;
z-index: 1;
}
.notify-row .dropdown-menu {
float: left;
max-width: 300px;
min-width: 160px;
top: 32px;
left: -74px;
width: 235px;
border: none;
}
.notify-row .dropdown-menu .notify-arrow {
border-style: solid;
border-width: 0 9px 9px;
height: 0;
margin-top: 0;
opacity: 0;
position: absolute;
left: 80px;
top: -18px;
transition: all 0.25s ease 0s;
width: 0;
z-index: 10;
margin-top: 10px;
opacity: 1;
}
.notify-row .dropdown-menu .notify-arrow.notify-arrow-green {
border-color: transparent transparent #a9d86e;
border-bottom-color: #a9d86e;
border-top-color: #a9d86e;
}
.notify-row .dropdown-menu .notify-arrow.notify-arrow-yellow {
border-color: transparent transparent #FCB322;
border-bottom-color: #FCB322;
border-top-color: #FCB322;
}
.notify-row .dropdown-menu .notify-arrow.notify-arrow-red {
border-color: transparent transparent #ff6c60;
border-bottom-color: #ff6c60;
border-top-color: #ff6c60;
}
.notify-row .dropdown-menu .notify-arrow.notify-arrow-db {
border-color: transparent transparent #d03633;
border-bottom-color: #d03633;
border-top-color: #d03633;
}
.notify-row .dropdown-menu .notify-arrow.notify-arrow-user {
border-color: transparent transparent #5cb85c;
border-bottom-color: #5cb85c;
border-top-color: #5cb85c;
}
.notify-row .dropdown-menu li:last-child a {
border-bottom: 0;
border-radius: 0 0 4px 4px;
}
.notify-row .dropdown-menu li a {
border-bottom: 1px solid #EBEBEB;
font-size: 1.2rem;
list-style: none;
padding: 15px 10px;
}
.notify-row .dropdown-menu li a:hover {
color: #222;
}
.notify-row .dropdown-menu p {
color: #fff;
margin: 0;
padding: 10px;
border-radius: 4px 4px 0px 0px;
-webkit-border-radius: 4px 4px 0px 0px;
}
.notify-row .dropdown-menu .content {
position: absolute;
left: 36px;
right: 44px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
display: inline-block;
}
.notify-row .dropdown-menu .label {
display: inline-block;
height: 18px;
width: 20px;
padding: 5px;
margin-right: 5px;
}
.notify-row .dropdown-menu .small {
font-style: italic;
font-weight: bold;
float: right;
padding-top: 2px;
font-size: 1rem;
}
.notify-row .dropdown-menu.tasks-bar .desc {
font-size: 1.3rem;
font-weight: normal;
display: block;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.notify-row .dropdown-menu.tasks-bar .percent {
display: inline-block;
float: right;
font-size: 1.3rem;
font-weight: 600;
}
.notify-row .dropdown-menu.tasks-bar .progress {
margin-top: 4px;
height: 10px;
margin-right: 34px;
margin-bottom: 0;
}
.notify-row .dropdown-menu.inbox .photo img {
border-radius: 2px 2px 2px 2px;
float: left;
height: 42px;
margin-right: 4px;
width: 42px;
border: solid 1px #EBEBEB;
border-radius: 3px;
}
.notify-row .dropdown-menu.inbox .subject {
display: block;
}
.notify-row .dropdown-menu.inbox .subject .from {
font-weight: 600;
}
.notify-row .dropdown-menu.inbox .subject .time {
font-size: 1.1rem;
font-style: italic;
font-weight: bold;
float: right;
}
.notify-row .dropdown-menu.inbox .message {
font-size: 1.1rem;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
position: absolute;
right: 6px;
left: 56px;
margin-top: 2px;
}
/*end*/
.breadcrumb {
position: absolute;
top: 60px;
left: 15px;
right: 15px;
border: solid 1px #ddd;
border-width: 1px 0 0 0;
background-color: transparent;
border-top-left-radius: 0;
border-top-right-radius: 0;
}
.breadcrumb > li.active {
display: inline-block;
}
.breadcrumb > li.load {
display: none;
}
.breadcrumb > li > a > i {
padding-right: 6px;
}
.content-body {
position: fixed;
left: 0;
bottom: 40px;
right: 0;
top: 98px;
overflow: hidden;
}
.content-body iframe {
width: 100%;
height: 100%;
border: none;
}
.welcome-bg {
background-image: url('images/bg.jpg');
background-size: 100% 100%;
}
.tooltip-inner {
max-width: 768px;
}
.tooltip.has-error .tooltip-inner {
background-color: #a94442;
}
.tooltip.has-error .tooltip-arrow {
border-top-color: #a94442;
}

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,76 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Web;
using Microsoft.AspNetCore.Authentication;
using Microsoft.AspNetCore.Authentication.Cookies;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using System.Security.Claims;
using System.Threading.Tasks;
namespace Bootstrap.Admin.Controllers
{
/// <summary>
/// Account controller.
/// </summary>
[AllowAnonymous]
public class AccountController : Controller
{
/// <summary>
/// Login the specified userName, password and remember.
/// </summary>
/// <returns>The login.</returns>
/// <param name="userName">User name.</param>
/// <param name="password">Password.</param>
/// <param name="remember">Remember.</param>
public async Task<IActionResult> Login(string userName, string password, string remember)
{
if (!string.IsNullOrEmpty(userName) && BootstrapUser.Authenticate(userName, password))
{
var identity = new ClaimsIdentity(CookieAuthenticationDefaults.AuthenticationScheme);
identity.AddClaim(new Claim(ClaimTypes.Name, userName));
await HttpContext.SignInAsync(CookieAuthenticationDefaults.AuthenticationScheme, new ClaimsPrincipal(identity), new AuthenticationProperties() { IsPersistent = remember == "true" });
return Redirect("~/");
}
var mobile = Request.IsMobileDevice();
var model = Request.IPad();
return mobile && !model ? View("Loginm", new ModelBase()) : View("Login", new ModelBase());
}
/// <summary>
/// Logout this instance.
/// </summary>
/// <returns>The logout.</returns>
public async Task<IActionResult> Logout()
{
await HttpContext.SignOutAsync(CookieAuthenticationDefaults.AuthenticationScheme);
return Redirect("~" + CookieAuthenticationDefaults.LoginPath);
}
/// <summary>
/// Accesses the denied.
/// </summary>
/// <returns>The denied.</returns>
public ActionResult AccessDenied()
{
return View();
}
/// <summary>
///
/// </summary>
/// <returns></returns>
public ActionResult Register(User p)
{
if (string.IsNullOrEmpty(p.UserName) || string.IsNullOrEmpty(p.Password) || string.IsNullOrEmpty(p.DisplayName) || string.IsNullOrEmpty(p.Description)) return View();
p.UserStatus = 1;
return UserHelper.SaveUser(p) ? (ActionResult)Redirect("~/html/RegResult.html") : View();
}
/// <summary>
///
/// </summary>
/// <returns></returns>
public ActionResult Mobile()
{
return View();
}
}
}

View File

@ -1,5 +1,6 @@
using Bootstrap.Admin.Models;
using System.Web.Mvc;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
namespace Bootstrap.Admin.Controllers
{
@ -14,7 +15,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Index()
{
return View(new NavigatorBarModel("~/Admin/Index"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -22,7 +23,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Users()
{
return View(new NavigatorBarModel("~/Admin/Users"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -30,7 +31,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Groups()
{
return View(new NavigatorBarModel("~/Admin/Groups"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -38,7 +39,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Dicts()
{
return View(new NavigatorBarModel("~/Admin/Dicts"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -46,7 +47,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Roles()
{
return View(new NavigatorBarModel("~/Admin/Roles"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -54,7 +55,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Menus()
{
return View(new NavigatorBarModel("~/Admin/Menus"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -62,7 +63,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Logs()
{
return View(new NavigatorBarModel("~/Admin/Logs"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -70,17 +71,16 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult FAIcon()
{
return View(new NavigatorBarModel("~/Admin/FAIcon"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[OutputCache(CacheProfile = "IconView")]
[AllowAnonymous]
[ResponseCache(Duration = 600)]
public PartialViewResult IconView()
{
Response.Cache.SetOmitVaryStar(true);
return PartialView("IconView");
}
/// <summary>
@ -89,7 +89,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Settings()
{
return View(new NavigatorBarModel("~/Admin/Settings"));
return View(new ThemeModel(this));
}
/// <summary>
@ -98,7 +98,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Notifications()
{
return View(new NavigatorBarModel("~/Admin/Notifications"));
return View(new NavigatorBarModel(this));
}
/// <summary>
@ -107,7 +107,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Profiles()
{
return View(new ProfilesModel("~/Admin/Profiles"));
return View(new ProfilesModel(this));
}
/// <summary>
///
@ -115,7 +115,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Exceptions()
{
return View(new NavigatorBarModel("~/Admin/Exceptions"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -123,7 +123,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Messages()
{
return View(new NavigatorBarModel("~/Admin/Messages"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -131,7 +131,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Tasks()
{
return View(new NavigatorBarModel("~/Admin/Tasks"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -139,7 +139,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Mobile()
{
return View(new NavigatorBarModel("~/Admin/Mobile"));
return View(new NavigatorBarModel(this));
}
/// <summary>
///
@ -147,7 +147,7 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Api()
{
return View(new NavigatorBarModel("~/Admin/Api"));
return View(new NavigatorBarModel(this));
}
}
}

View File

@ -0,0 +1,23 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using System.Collections.Generic;
namespace Bootstrap.Admin.Controllers.Api
{
[Route("api/[controller]")]
public class CategoryController : Controller
{
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpGet]
[AllowAnonymous]
public IEnumerable<BootstrapDict> Get()
{
return DictHelper.RetrieveCategories();
}
}
}

View File

@ -0,0 +1,48 @@
using Bootstrap.Admin.Query;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Web.Mvc;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using System.Collections.Generic;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class DictsController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<BootstrapDict> Get(QueryDictOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]BootstrapDict value)
{
return DictHelper.SaveDict(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
[Authorize(Roles = "Administrators")]
public object Delete([FromBody]IEnumerable<int> value)
{
var result = DictHelper.DeleteDict(value);
return new { result, msg = result ? "成功!" : "失败" };
}
}
}

View File

@ -1,65 +1,77 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class ExceptionsController : ApiController
{
/// <summary>
/// 显示所有异常
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Exceptions> Get([FromUri]QueryExceptionOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpPost]
public IEnumerable<string> Post()
{
var filePath = HttpContext.Current.Server.MapPath("~/App_Data/ErrorLog");
return Directory.GetFiles(filePath)
.Where(f => Path.GetExtension(f).Equals(".log", System.StringComparison.OrdinalIgnoreCase))
.Select(f => Path.GetFileNameWithoutExtension(f)).OrderByDescending(s => s);
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpPut]
public string Put([FromBody]string fileName)
{
var logName = HttpContext.Current.Server.MapPath(string.Format("~/App_Data/ErrorLog/{0}.log", fileName));
if (!File.Exists(logName)) return "无此日志文件";
StringBuilder sb = new StringBuilder();
using (StreamReader reader = new StreamReader(logName))
{
while (!reader.EndOfStream)
{
var line = reader.ReadLine().Replace("<", "&lt;").Replace(">", "&gt;");
if (line == "General Information ") sb.AppendFormat("<h4><b>{0}</b></h4>", line);
else if (line.StartsWith("TimeStamp:")) sb.AppendFormat("<div class='logTs'>{0}</div>", line);
else if (line.EndsWith("Exception Information")) sb.AppendFormat("<div class='logExcep'>{0}</div>", line);
else if (line.StartsWith("Message:")) sb.AppendFormat("<div class='logMsg'>{0}</div>", line);
else if (line.StartsWith("ErrorSql:")) sb.AppendFormat("<div class='logSql'>{0}</div>", line);
else if (line.StartsWith("Exception Type: Longbow.Data.DBAccessException")) sb.AppendFormat("<div class='logDbExcep'>{0}</div>", line);
else if (line.StartsWith("StackTrace Information")) sb.AppendFormat("<b>{0}</b><br>", line);
else sb.AppendFormat("{0}<br>", line);
};
}
return sb.ToString();
}
}
}
using Bootstrap.Admin.Query;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class ExceptionsController : Controller
{
/// <summary>
/// 显示所有异常
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Exceptions> Get(QueryExceptionOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpPost]
public IEnumerable<string> Post()
{
var filePath = Path.Combine(AppContext.BaseDirectory, "Error");
return Directory.GetFiles(filePath)
.Where(f => Path.GetExtension(f).Equals(".log", System.StringComparison.OrdinalIgnoreCase))
.Select(f => Path.GetFileNameWithoutExtension(f)).OrderByDescending(s => s);
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpPut]
public JsonResult Put([FromBody]ExceptionFileQuery exceptionFile)
{
var filePath = Path.Combine(AppContext.BaseDirectory, "Error");
var logName = $"{Path.Combine(filePath, exceptionFile.FileName)}.log";
if (!System.IO.File.Exists(logName)) return new JsonResult("无此日志文件");
StringBuilder sb = new StringBuilder();
using (StreamReader reader = new StreamReader(logName))
{
while (!reader.EndOfStream)
{
var line = reader.ReadLine().Replace("<", "&lt;").Replace(">", "&gt;");
if (line == "General Information ") sb.AppendFormat("<h4><b>{0}</b></h4>", line);
else if (line.StartsWith("TimeStamp:")) sb.AppendFormat("<div class='logTs'>{0}</div>", line);
else if (line.EndsWith("Exception Information")) sb.AppendFormat("<div class='logExcep'>{0}</div>", line);
else if (line.StartsWith("Message:")) sb.AppendFormat("<div class='logMsg'>{0}</div>", line);
else if (line.StartsWith("ErrorSql:")) sb.AppendFormat("<div class='logSql'>{0}</div>", line);
else if (line.StartsWith("Exception Type: Longbow.Data.DBAccessException")) sb.AppendFormat("<div class='logDbExcep'>{0}</div>", line);
else if (line.StartsWith("StackTrace Information")) sb.AppendFormat("<b>{0}</b><br>", line);
else sb.AppendFormat("{0}<br>", line);
};
}
return new JsonResult(sb.ToString());
}
public class ExceptionFileQuery
{
public string FileName { get; set; }
}
}
}

View File

@ -1,101 +1,105 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class GroupsController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Group> Get([FromUri]QueryGroupOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet]
public Group Get(int id)
{
return GroupHelper.RetrieveGroups().FirstOrDefault(t => t.Id == id);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]Group value)
{
return GroupHelper.SaveGroup(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]string value)
{
return GroupHelper.DeleteGroup(value);
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost]
public IEnumerable<Group> Post(int id, [FromBody]JObject value)
{
var ret = new List<Group>();
dynamic json = value;
switch ((string)json.type)
{
case "user":
ret = GroupHelper.RetrieveGroupsByUserId(id).ToList();
break;
case "role":
ret = GroupHelper.RetrieveGroupsByRoleId(id).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string groupIds = json.groupIds;
switch ((string)json.type)
{
case "user":
ret = GroupHelper.SaveGroupsByUserId(id, groupIds);
break;
case "role":
ret = GroupHelper.SaveGroupsByRoleId(id, groupIds);
break;
default:
break;
}
return ret;
}
}
}
using Bootstrap.Admin.Query;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class GroupsController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Group> Get(QueryGroupOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet("{id}")]
public Group Get(int id)
{
return GroupHelper.RetrieveGroups().FirstOrDefault(t => t.Id == id);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]Group value)
{
return GroupHelper.SaveGroup(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]IEnumerable<int> value)
{
return GroupHelper.DeleteGroup(value);
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost("{id}")]
public IEnumerable<Group> Post(int id, [FromBody]JObject value)
{
var ret = new List<Group>();
dynamic json = value;
switch ((string)json.type)
{
case "user":
ret = GroupHelper.RetrieveGroupsByUserId(id).ToList();
break;
case "role":
ret = GroupHelper.RetrieveGroupsByRoleId(id).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut("{id}")]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string groupIds = json.groupIds;
switch ((string)json.type)
{
case "user":
ret = GroupHelper.SaveGroupsByUserId(id, groupIds);
break;
case "role":
ret = GroupHelper.SaveGroupsByRoleId(id, groupIds);
break;
default:
break;
}
return ret;
}
}
}

View File

@ -1,56 +1,57 @@
using Bootstrap.Security;
using Bootstrap.Security.Mvc;
using Longbow.Caching;
using Longbow.Security.Principal;
using Newtonsoft.Json.Linq;
using System;
using System.Globalization;
using System.Linq;
using System.Web.Http;
using System.Web.Security;
namespace Bootstrap.Admin.Controllers
{
/// <summary>
///
/// </summary>
public class LoginController : ApiController
{
[HttpGet]
public LoginInfo Get()
{
var token = Request.Headers.GetValues("Token").First();
return new LoginInfo() { UserName = User.Identity.Name, Token = token };
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[AllowAnonymous]
[HttpPost]
public LoginInfo Post([FromBody]JObject value)
{
dynamic user = value;
string userName = user.userName;
string password = user.password;
if (LgbPrincipal.Authenticate(userName, password) || BootstrapUser.Authenticate(userName, password))
{
var token = CacheManager.AddOrUpdate(string.Format("WebApi-{0}", userName), k => new LoginInfo() { UserName = userName, Token = Guid.NewGuid().ToString() }, (k, info) => info, "WebApi");
CacheManager.AddOrUpdate(token.Token, k => token, (k, info) => info, "Token");
return token;
}
return new LoginInfo() { UserName = userName };
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[AllowAnonymous]
[HttpOptions]
public string Options()
{
return null;
}
}
}
using Bootstrap.Security;
using Longbow.Cache;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class LoginController : Controller
{
[HttpGet]
public object Get()
{
var token = Request.Headers["Token"];
return new { UserName = User.Identity.Name, Token = token };
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[AllowAnonymous]
[HttpPost]
public object Post([FromBody]JObject value)
{
dynamic user = value;
string userName = user.userName;
string password = user.password;
if (BootstrapUser.Authenticate(userName, password))
{
var token = CacheManager.AddOrUpdate(string.Format("WebApi-{0}", userName), k => new { UserName = userName, Token = Guid.NewGuid().ToString() }, (k, info) => info, "WebApi");
CacheManager.AddOrUpdate(token.Token, k => token, (k, info) => info, "Token");
return token;
}
return new { UserName = userName };
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[AllowAnonymous]
[HttpOptions]
public string Options()
{
return null;
}
}
}

View File

@ -1,43 +1,45 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Linq;
using System.Web;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class LogsController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Log> Get([FromUri]QueryLogOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet]
public Log Get(int id)
{
return LogHelper.RetrieveLogs().FirstOrDefault(t => t.Id == id);
}
[HttpPost]
public bool Post([FromBody]Log value)
{
var request = HttpContext.Current.Request;
value.ClientAgent = request.UserAgent;
value.ClientIp = request.UserHostAddress;
value.UserName = HttpContext.Current.User.Identity.Name;
return LogHelper.SaveLog(value);
}
}
using Bootstrap.Admin.Query;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using Microsoft.AspNetCore.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class LogsController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Log> Get(QueryLogOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet("{id}")]
public Log Get(int id)
{
return LogHelper.RetrieveLogs().FirstOrDefault(t => t.Id == id);
}
[HttpPost]
public bool Post([FromBody]Log value)
{
value.ClientAgent = Request.Headers["User-Agent"];
value.ClientIp = HttpContext.Connection.RemoteIpAddress.ToString();
value.UserName = User.Identity.Name;
return LogHelper.SaveLog(value);
}
}
}

View File

@ -1,89 +1,93 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Web.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class MenusController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<BootstrapMenu> Get([FromUri]QueryMenuOption value)
{
return value.RetrieveData(User.Identity.Name);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]BootstrapMenu value)
{
return MenuHelper.SaveMenu(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]string value)
{
return MenuHelper.DeleteMenu(value);
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost]
public IEnumerable<BootstrapMenu> Post(int id, [FromBody]JObject value)
{
var ret = new List<BootstrapMenu>();
dynamic json = value;
switch ((string)json.type)
{
case "role":
ret = MenuHelper.RetrieveMenusByRoleId(id).ToList();
break;
case "user":
ret = BootstrapMenu.RetrieveAllMenus(User.Identity.Name).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string menuIds = json.menuIds.ToString();
switch ((string)json.type)
{
case "role":
ret = MenuHelper.SaveMenusByRoleId(id, menuIds);
break;
default:
break;
}
return ret;
}
}
using Bootstrap.Admin.Query;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Web.Mvc;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class MenusController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<BootstrapMenu> Get(QueryMenuOption value)
{
return value.RetrieveData(User.Identity.Name);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]BootstrapMenu value)
{
return MenuHelper.SaveMenu(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]IEnumerable<int> value)
{
return MenuHelper.DeleteMenu(value);
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost("{id}")]
public IEnumerable<BootstrapMenu> Post(int id, [FromBody]JObject value)
{
var ret = new List<BootstrapMenu>();
dynamic json = value;
switch ((string)json.type)
{
case "role":
ret = MenuHelper.RetrieveMenusByRoleId(id).ToList();
break;
case "user":
ret = BootstrapMenu.RetrieveAllMenus(User.Identity.Name).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut("{id}")]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string menuIds = json.menuIds.ToString();
switch ((string)json.type)
{
case "role":
ret = MenuHelper.SaveMenusByRoleId(id, menuIds);
break;
default:
break;
}
return ret;
}
}
}

View File

@ -1,56 +1,60 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class MessagesController : ApiController
{
/// <summary>
/// 根据Id返回不同的消息列表
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet]
public IEnumerable<Message> Get(string id)
{
var ret = new List<Message>();
switch (id)
{
case "inbox":
ret = MessageHelper.Inbox(User.Identity.Name).ToList();
break;
case "sendmail":
ret = MessageHelper.SendMail(User.Identity.Name).ToList();
break;
case "mark":
ret = MessageHelper.Mark(User.Identity.Name).ToList();
break;
case "trash":
ret = MessageHelper.Trash(User.Identity.Name).ToList();
break;
}
return ret;
}
/// <summary>
/// 返回各个消息列表的文件个数
/// </summary>
/// <returns></returns>
[HttpGet]
public MessageCountModel Get()
{
var mcm = new MessageCountModel
{
InboxCount = MessageHelper.Inbox(User.Identity.Name).Count(),
SendmailCount = MessageHelper.SendMail(User.Identity.Name).Count(),
MarkCount = MessageHelper.Mark(User.Identity.Name).Count(),
TrashCount = MessageHelper.Trash(User.Identity.Name).Count()
};
return mcm;
}
}
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Microsoft.AspNetCore.Mvc;
using System.Collections.Generic;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class MessagesController : Controller
{
/// <summary>
/// 根据Id返回不同的消息列表
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet("{id}")]
public IEnumerable<Message> Get(string id)
{
var ret = new List<Message>();
switch (id)
{
case "inbox":
ret = MessageHelper.Inbox(User.Identity.Name).ToList();
break;
case "sendmail":
ret = MessageHelper.SendMail(User.Identity.Name).ToList();
break;
case "mark":
ret = MessageHelper.Mark(User.Identity.Name).ToList();
break;
case "trash":
ret = MessageHelper.Trash(User.Identity.Name).ToList();
break;
}
return ret;
}
/// <summary>
/// 返回各个消息列表的文件个数
/// </summary>
/// <returns></returns>
[HttpGet]
public MessageCountModel Get()
{
var mcm = new MessageCountModel
{
InboxCount = MessageHelper.Inbox(User.Identity.Name).Count(),
SendmailCount = MessageHelper.SendMail(User.Identity.Name).Count(),
MarkCount = MessageHelper.Mark(User.Identity.Name).Count(),
TrashCount = MessageHelper.Trash(User.Identity.Name).Count()
};
return mcm;
}
}
}

View File

@ -1,136 +1,140 @@
using Bootstrap.DataAccess;
using System.Collections.Generic;
using System.Web.Http;
using System.Linq;
using System;
namespace Bootstrap.Admin.Controllers
{
public class NotificationsController : ApiController
{
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpGet]
public Notifications Get()
{
var ret = new Notifications();
// New Users
var user = UserHelper.RetrieveNewUsers();
ret.Users = user.Take(6).ToList();
ret.Users.AsParallel().ForAll(n =>
{
var ts = DateTime.Now - n.RegisterTime;
if (ts.TotalMinutes < 5) n.Period = "刚刚";
else if (ts.Days > 0) n.Period = string.Format("{0}天", ts.Days);
else if (ts.Hours > 0) n.Period = string.Format("{0}小时", ts.Hours);
else if (ts.Minutes > 0) n.Period = string.Format("{0}分钟", ts.Minutes);
});
ret.NewUsersCount = user.Count();
// Tasks
var task = TaskHelper.RetrieveTasks();
ret.Tasks = task.Take(6).ToList();
ret.TasksCount = task.Count();
//Message
var message = MessageHelper.RetrieveMessagesHeader(User.Identity.Name);
ret.Messages = message.Take(6).ToList();
ret.Messages.AsParallel().ForAll(m => m.FromIcon = Url.Content(m.FromIcon));
ret.MessagesCount = message.Count();
//Apps
var apps = ExceptionHelper.RetrieveExceptions().Where(n => n.ExceptionType != "Longbow.Data.DBAccessException");
ret.Apps = apps.Take(6).ToList();
ret.Apps.AsParallel().ForAll(n =>
{
n.ExceptionType = n.ExceptionType.Split('.').Last();
var ts = DateTime.Now - n.LogTime;
if (ts.TotalMinutes < 5) n.Period = "刚刚";
else if (ts.Days > 0) n.Period = string.Format("{0}天", ts.Days);
else if (ts.Hours > 0) n.Period = string.Format("{0}小时", ts.Hours);
else if (ts.Minutes > 0) n.Period = string.Format("{0}分钟", ts.Minutes);
});
ret.AppExceptionsCount = apps.Count();
//Dbs
var dbs = ExceptionHelper.RetrieveExceptions().Where(n => n.ExceptionType == "Longbow.Data.DBAccessException");
ret.Dbs = dbs.Take(6).ToList();
ret.Dbs.AsParallel().ForAll(n =>
{
var ts = DateTime.Now - n.LogTime;
if (ts.TotalMinutes < 5) n.Period = "刚刚";
else if (ts.Days > 0) n.Period = string.Format("{0}天", ts.Days);
else if (ts.Hours > 0) n.Period = string.Format("{0}小时", ts.Hours);
else if (ts.Minutes > 0) n.Period = string.Format("{0}分钟", ts.Minutes);
});
ret.DbExceptionsCount = dbs.Count();
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public Notifications Get(string id)
{
var ret = new Notifications();
if (id == "newusers" || id == "all") ret.Users = UserHelper.RetrieveNewUsers().OrderByDescending(u => u.RegisterTime).ToList();
return ret;
}
public class Notifications
{
public Notifications()
{
Users = new List<User>();
Apps = new List<Exceptions>();
Dbs = new List<Exceptions>();
Tasks = new List<Task>();
Messages = new List<Message>();
}
/// <summary>
///
/// </summary>
public List<User> Users { get; set; }
/// <summary>
///
/// </summary>
public List<Exceptions> Apps { get; set; }
/// <summary>
///
/// </summary>
public List<Exceptions> Dbs { get; set; }
/// <summary>
///
/// </summary>
public List<Task> Tasks { get; set; }
/// <summary>
///
/// </summary>
public List<Message> Messages { get; set; }
/// <summary>
/// 获得/设置 消息数量
/// </summary>
public int MessagesCount { get; set; }
/// <summary>
/// 获得/设置 新用户数量
/// </summary>
public int NewUsersCount { get; set; }
/// <summary>
/// 获取/设置 任务数量
/// </summary>
public int TasksCount { get; set; }
/// <summary>
/// 获取/设置 应用程序错误数量
/// </summary>
public int AppExceptionsCount { get; set; }
/// <summary>
/// 获取/设置 数据库错误数量
/// </summary>
public int DbExceptionsCount { get; set; }
}
}
using Bootstrap.DataAccess;
using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class NotificationsController : Controller
{
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpGet]
public Notifications Get()
{
var ret = new Notifications();
// New Users
var user = UserHelper.RetrieveNewUsers();
ret.Users = user.Take(6).ToList();
ret.Users.AsParallel().ForAll(n =>
{
var ts = DateTime.Now - n.RegisterTime;
if (ts.TotalMinutes < 5) n.Period = "刚刚";
else if (ts.Days > 0) n.Period = string.Format("{0}天", ts.Days);
else if (ts.Hours > 0) n.Period = string.Format("{0}小时", ts.Hours);
else if (ts.Minutes > 0) n.Period = string.Format("{0}分钟", ts.Minutes);
});
ret.NewUsersCount = user.Count();
// Tasks
var task = TaskHelper.RetrieveTasks();
ret.Tasks = task.Take(6).ToList();
ret.TasksCount = task.Count();
//Message
var message = MessageHelper.RetrieveMessagesHeader(User.Identity.Name);
ret.Messages = message.Take(6).ToList();
ret.Messages.AsParallel().ForAll(m => m.FromIcon = Url.Content(m.FromIcon));
ret.MessagesCount = message.Count();
//Apps
var apps = ExceptionHelper.RetrieveExceptions().Where(n => n.ExceptionType != "Longbow.Data.DBAccessException");
ret.Apps = apps.Take(6).ToList();
ret.Apps.AsParallel().ForAll(n =>
{
n.ExceptionType = n.ExceptionType.Split('.').Last();
var ts = DateTime.Now - n.LogTime;
if (ts.TotalMinutes < 5) n.Period = "刚刚";
else if (ts.Days > 0) n.Period = string.Format("{0}天", ts.Days);
else if (ts.Hours > 0) n.Period = string.Format("{0}小时", ts.Hours);
else if (ts.Minutes > 0) n.Period = string.Format("{0}分钟", ts.Minutes);
});
ret.AppExceptionsCount = apps.Count();
//Dbs
var dbs = ExceptionHelper.RetrieveExceptions().Where(n => n.ExceptionType == "Longbow.Data.DBAccessException");
ret.Dbs = dbs.Take(6).ToList();
ret.Dbs.AsParallel().ForAll(n =>
{
var ts = DateTime.Now - n.LogTime;
if (ts.TotalMinutes < 5) n.Period = "刚刚";
else if (ts.Days > 0) n.Period = string.Format("{0}天", ts.Days);
else if (ts.Hours > 0) n.Period = string.Format("{0}小时", ts.Hours);
else if (ts.Minutes > 0) n.Period = string.Format("{0}分钟", ts.Minutes);
});
ret.DbExceptionsCount = dbs.Count();
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet("{id}")]
public Notifications Get(string id)
{
var ret = new Notifications();
if (id == "newusers" || id == "all") ret.Users = UserHelper.RetrieveNewUsers().OrderByDescending(u => u.RegisterTime).ToList();
return ret;
}
public class Notifications
{
public Notifications()
{
Users = new List<User>();
Apps = new List<Exceptions>();
Dbs = new List<Exceptions>();
Tasks = new List<Task>();
Messages = new List<Message>();
}
/// <summary>
///
/// </summary>
public List<User> Users { get; set; }
/// <summary>
///
/// </summary>
public List<Exceptions> Apps { get; set; }
/// <summary>
///
/// </summary>
public List<Exceptions> Dbs { get; set; }
/// <summary>
///
/// </summary>
public List<Task> Tasks { get; set; }
/// <summary>
///
/// </summary>
public List<Message> Messages { get; set; }
/// <summary>
/// 获得/设置 消息数量
/// </summary>
public int MessagesCount { get; set; }
/// <summary>
/// 获得/设置 新用户数量
/// </summary>
public int NewUsersCount { get; set; }
/// <summary>
/// 获取/设置 任务数量
/// </summary>
public int TasksCount { get; set; }
/// <summary>
/// 获取/设置 应用程序错误数量
/// </summary>
public int AppExceptionsCount { get; set; }
/// <summary>
/// 获取/设置 数据库错误数量
/// </summary>
public int DbExceptionsCount { get; set; }
}
}
}

View File

@ -0,0 +1,67 @@
using Bootstrap.DataAccess;
using Longbow.Logging;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Specialized;
using System.IO;
using System.Threading.Tasks;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class ProfilesController : Controller
{
[HttpPost]
public async Task<JsonResult> Post([FromServices]IHostingEnvironment env, IFormCollection files)
{
var previewUrl = string.Empty;
long fileSize = 0;
var userName = User.Identity.Name;
var error = string.Empty;
if (User.IsInRole("Administrators")) userName = "default";
if (files.Count > 0)
{
var uploadFile = files.Files[0];
var webSiteUrl = DictHelper.RetrieveIconFolderPath().Code;
var fileName = string.Format("{0}{1}", userName, Path.GetExtension(uploadFile.FileName));
var fileUrl = string.Format("{0}{1}", webSiteUrl, fileName);
var filePath = Path.Combine(env.WebRootPath, webSiteUrl.Replace("~", string.Empty).Replace("/", "\\").TrimStart('\\') + fileName);
var fileFolder = Path.GetDirectoryName(filePath);
fileSize = uploadFile.Length;
try
{
if (!Directory.Exists(fileFolder)) Directory.CreateDirectory(fileFolder);
using (var fs = new FileStream(filePath, FileMode.Create))
{
await uploadFile.CopyToAsync(fs);
}
previewUrl = string.Format("{0}?q={1}", Url.Content(fileUrl), DateTime.Now.Ticks);
UserHelper.SaveUserIconByName(userName, fileName);
}
catch (Exception ex)
{
var nv = new NameValueCollection
{
{ "UpLoadFileName", filePath }
};
error = ex.Message;
ExceptionManager.Publish(ex, nv);
}
}
return new JsonResult(new
{
error = string.IsNullOrEmpty(error) ? error : $"服务器端错误-{error}",
initialPreview = new string[] { previewUrl },
initialPreviewConfig = new object[] {
new { caption= "新头像", size= fileSize, showZoom= true }
},
append = false
});
}
}
}

View File

@ -1,98 +1,102 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class RolesController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Role> Get([FromUri]QueryRoleOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost]
public IEnumerable<Role> Post(int id, [FromBody]JObject value)
{
var ret = new List<Role>();
dynamic json = value;
switch ((string)json.type)
{
case "user":
ret = RoleHelper.RetrieveRolesByUserId(id).ToList();
break;
case "group":
ret = RoleHelper.RetrieveRolesByGroupId(id).ToList();
break;
case "menu":
ret = RoleHelper.RetrieveRolesByMenuId(id).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>根据GroupID获取
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string roleIds = json.roleIds;
switch ((string)json.type)
{
case "user":
ret = RoleHelper.SaveRolesByUserId(id, roleIds);
break;
case "group":
ret = RoleHelper.SaveRolesByGroupId(id, roleIds);
break;
case "menu":
ret = RoleHelper.SavaRolesByMenuId(id, roleIds);
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]Role value)
{
return RoleHelper.SaveRole(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]string value)
{
return RoleHelper.DeleteRole(value);
}
}
}
using Bootstrap.Admin.Query;
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class RolesController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<Role> Get(QueryRoleOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost("{id}")]
public IEnumerable<Role> Post(int id, [FromBody]JObject value)
{
var ret = new List<Role>();
dynamic json = value;
switch ((string)json.type)
{
case "user":
ret = RoleHelper.RetrieveRolesByUserId(id).ToList();
break;
case "group":
ret = RoleHelper.RetrieveRolesByGroupId(id).ToList();
break;
case "menu":
ret = RoleHelper.RetrieveRolesByMenuId(id).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>根据GroupID获取
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut("{id}")]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string roleIds = json.roleIds;
switch ((string)json.type)
{
case "user":
ret = RoleHelper.SaveRolesByUserId(id, roleIds);
break;
case "group":
ret = RoleHelper.SaveRolesByGroupId(id, roleIds);
break;
case "menu":
ret = RoleHelper.SavaRolesByMenuId(id, roleIds);
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]Role value)
{
return RoleHelper.SaveRole(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]IEnumerable<int> value)
{
return RoleHelper.DeleteRole(value);
}
}
}

View File

@ -0,0 +1,36 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Cache;
using Microsoft.AspNetCore.Mvc;
using System.Collections.Generic;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class SettingsController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost]
public bool Post([FromBody]BootstrapDict value)
{
//保存个性化设置
return DictHelper.SaveSettings(value);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpGet]
public IEnumerable<ICacheCorsItem> Get()
{
return CacheManager.CorsSites;
}
}
}

View File

@ -1,17 +1,18 @@
using Bootstrap.DataAccess;
using Microsoft.AspNetCore.Mvc;
using System.Collections.Generic;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// <summary>
///
/// </summary>
public class TasksController : ApiController
[Route("api/[controller]")]
public class TasksController : Controller
{
/// <summary>
///
/// </summary>
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpGet]
public IEnumerable<Task> Get()

View File

@ -1,158 +1,146 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Security.Principal;
using Longbow.Web.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
/// <summary>
///
/// </summary>
public class UsersController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<User> Get([FromUri]QueryUserOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpPut]
public bool Put([FromBody]User value)
{
if(value.UserStatus == 3)
{
return UserHelper.SaveUserCssByName(value.UserName, value.Css);
}
if (value.UserStatus == 9)
{
// vlaidate userName
return BootstrapUser.RetrieveUserByUserName(value.UserName) == null && !UserHelper.RetrieveNewUsers().Any(u => u.UserName == value.UserName);
}
var ret = false;
if (value.UserName.Equals(User.Identity.Name, System.StringComparison.OrdinalIgnoreCase) || LgbPrincipal.IsAdmin(User))
{
if (value.UserStatus == 1)
ret = BootstrapUser.SaveUserInfoByName(value.UserName, value.DisplayName);
else if (value.UserStatus == 2)
ret = BootstrapUser.ChangePassword(value.UserName, value.Password, value.NewPassword);
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost]
public IEnumerable<User> Post(int id, [FromBody]JObject value)
{
var ret = new List<User>();
dynamic json = value;
switch ((string)json.type)
{
case "role":
ret = UserHelper.RetrieveUsersByRoleId(id).ToList();
break;
case "group":
ret = UserHelper.RetrieveUsersByGroupId(id).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="userName"></param>
/// <returns></returns>
[HttpGet]
public BootstrapUser Get(string userName)
{
return BootstrapUser.RetrieveUserByUserName(userName);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]User value)
{
value.Description = string.Format("管理员{0}创建用户", User.Identity.Name);
value.ApprovedBy = User.Identity.Name;
return UserHelper.SaveUser(value);
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string userIds = json.userIds;
switch ((string)json.type)
{
case "role":
ret = UserHelper.SaveUsersByRoleId(id, userIds);
break;
case "group":
ret = UserHelper.SaveUsersByGroupId(id, userIds);
break;
case "user":
// 此时 userIds 存储的信息是操作结果 1 标示同意 0 标示拒绝
var user = new User() { Id = id, UserStatus = 2 };
if (userIds == "1")
{
user.ApprovedBy = User.Identity.Name;
}
else
{
user.RejectedReason = "无原因";
user.RejectedBy = User.Identity.Name;
}
ret = UserHelper.SaveUser(user);
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]string value)
{
return UserHelper.DeleteUser(value);
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[AllowAnonymous]
[HttpOptions]
public string Options()
{
return null;
}
}
using Bootstrap.Admin.Query;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Web.Mvc;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
namespace Bootstrap.Admin.Controllers.Api
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class UsersController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<User> Get(QueryUserOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpPut]
public bool Put([FromBody]User value)
{
if (User.IsInRole("Administrators")) return false;
var ret = false;
if (value.UserStatus == 3)
{
return UserHelper.SaveUserCssByName(value.UserName, value.Css);
}
if (value.UserName.Equals(User.Identity.Name, System.StringComparison.OrdinalIgnoreCase))
{
if (value.UserStatus == 1)
ret = BootstrapUser.SaveUserInfoByName(value.UserName, value.DisplayName);
else if (value.UserStatus == 2)
ret = BootstrapUser.ChangePassword(value.UserName, value.Password, value.NewPassword);
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost("{id}")]
public IEnumerable<User> Post(int id, [FromBody]JObject value)
{
var ret = new List<User>();
dynamic json = value;
switch ((string)json.type)
{
case "role":
ret = UserHelper.RetrieveUsersByRoleId(id).ToList();
break;
case "group":
ret = UserHelper.RetrieveUsersByGroupId(id).ToList();
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]User value)
{
value.Description = string.Format("管理员{0}创建用户", User.Identity.Name);
value.ApprovedBy = User.Identity.Name;
return UserHelper.SaveUser(value);
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <param name="value"></param>
/// <returns></returns>
[HttpPut("{id}")]
public bool Put(int id, [FromBody]JObject value)
{
var ret = false;
dynamic json = value;
string userIds = json.userIds;
switch ((string)json.type)
{
case "role":
ret = UserHelper.SaveUsersByRoleId(id, userIds);
break;
case "group":
ret = UserHelper.SaveUsersByGroupId(id, userIds);
break;
case "user":
// 此时 userIds 存储的信息是操作结果 1 标示同意 0 标示拒绝
var user = new User() { Id = id, UserStatus = 2 };
if (userIds == "1")
{
user.ApprovedBy = User.Identity.Name;
}
else
{
user.RejectedReason = "无原因";
user.RejectedBy = User.Identity.Name;
}
ret = UserHelper.SaveUser(user);
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public bool Delete([FromBody]IEnumerable<int> value)
{
return UserHelper.DeleteUser(value);
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[AllowAnonymous]
[HttpOptions]
public string Options()
{
return null;
}
}
}

View File

@ -1,82 +0,0 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Security.Principal;
using Longbow.Web.Mvc;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class DictsController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public QueryData<BootstrapDict> Get([FromUri]QueryDictOption value)
{
return value.RetrieveData();
}
/// <summary>
///
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet]
public BootstrapDict Get(int id)
{
return DictHelper.RetrieveDicts().FirstOrDefault(t => t.Id == id);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpPost]
public bool Post([FromBody]BootstrapDict value)
{
return DictHelper.SaveDict(value);
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[HttpPost]
[AllowAnonymous]
public IEnumerable<BootstrapDict> Post(int id, [FromBody]JObject value)
{
IEnumerable<BootstrapDict> ret = new List<BootstrapDict>();
dynamic json = value;
switch ((string)json.type)
{
case "category":
ret = DictHelper.RetrieveCategories();
break;
case "css":
ret = DictHelper.RetrieveWebCss();
break;
case "activeCss":
ret = DictHelper.RetrieveActiveCss();
break;
default:
break;
}
return ret;
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpDelete]
public object Delete([FromBody]string value)
{
if (!LgbPrincipal.IsAdmin(User)) return new { result = false, msg = "当前用户权限不够" };
var result = DictHelper.DeleteDict(value);
return new { result = result, msg = result ? "成功!" : "失败" };
}
}
}

View File

@ -1,9 +1,7 @@
using Bootstrap.Admin.Models;
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Security.Principal;
using System.Web.Mvc;
using System.Web.Security;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
namespace Bootstrap.Admin.Controllers
{
@ -18,59 +16,18 @@ namespace Bootstrap.Admin.Controllers
/// <returns></returns>
public ActionResult Index()
{
var v = new HeaderBarModel { HomeUrl = DictHelper.RetrieveHomeUrl() };
var v = new HeaderBarModel(User.Identity) { HomeUrl = DictHelper.RetrieveHomeUrl() };
return v.HomeUrl.StartsWith("~/") ? (ActionResult)View(v) : Redirect(v.HomeUrl);
}
/// <summary>
///
/// </summary>
/// <returns></returns>
public ActionResult Lock()
{
FormsAuthentication.SignOut();
var user = BootstrapUser.RetrieveUserByUserName(User.Identity.Name);
return View(new LockModel
{
UserName = user.UserName,
DisplayName = user.DisplayName,
ReturnUrl = Url.Encode(Request.UrlReferrer == null ? FormsAuthentication.DefaultUrl : Request.UrlReferrer.AbsoluteUri)
});
}
/// <summary>
///
/// </summary>
/// <param name="login"></param>
/// <param name="id"></param>
/// <returns></returns>
[AllowAnonymous]
public ActionResult Login(LoginModel login)
public IActionResult Error(int id)
{
FormsAuthentication.SignOut();
if (!string.IsNullOrEmpty(login.UserName) && (LgbPrincipal.Authenticate(login.UserName, login.Password) || BootstrapUser.Authenticate(login.UserName, login.Password)))
{
FormsAuthentication.RedirectFromLoginPage(login.UserName, login.Remember == "true");
return new EmptyResult();
}
return View(login);
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[AllowAnonymous]
public ActionResult Register(User p)
{
if (string.IsNullOrEmpty(p.UserName) || string.IsNullOrEmpty(p.Password) || string.IsNullOrEmpty(p.DisplayName) || string.IsNullOrEmpty(p.Description)) return View();
p.UserStatus = 1;
return UserHelper.SaveUser(p) ? (ActionResult)Redirect("~/Content/html/RegResult.html") : View();
}
/// <summary>
///
/// </summary>
/// <returns></returns>
[AllowAnonymous]
public ActionResult Mobile()
{
return View();
return id == 404 ? View("NotFound") : View();
}
}
}

View File

@ -0,0 +1,25 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Microsoft.AspNetCore.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Controllers
{
/// <summary>
///
/// </summary>
[Route("api/[controller]")]
public class NewController : Controller
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public bool Get(string userName)
{
return BootstrapUser.RetrieveUserByUserName(userName) == null && !UserHelper.RetrieveNewUsers().Any(u => u.UserName == userName);
}
}
}

View File

@ -1,45 +0,0 @@
using Bootstrap.DataAccess;
using Longbow.ExceptionManagement;
using Longbow.Security.Principal;
using System;
using System.Collections.Specialized;
using System.IO;
using System.Web;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class ProfilesController : ApiController
{
[HttpPost]
public string Post()
{
var ret = string.Empty;
var userName = User.Identity.Name;
if (LgbPrincipal.IsWebAdmin(userName)) userName = "default";
var files = HttpContext.Current.Request.Files;
if (files.Count > 0)
{
var webSiteUrl = DictHelper.RetrieveIconFolderPath().Code;
var fileName = string.Format("{0}{1}", userName, Path.GetExtension(files[0].FileName));
var fileUrl = string.Format("{0}{1}", webSiteUrl, fileName);
var filePath = HttpContext.Current.Server.MapPath(fileUrl);
var fileFolder = Path.GetDirectoryName(filePath);
try
{
if (!Directory.Exists(fileFolder)) Directory.CreateDirectory(fileFolder);
files[0].SaveAs(filePath);
ret = string.Format("{0}?q={1}", Url.Content(fileUrl), DateTime.Now.Ticks);
UserHelper.SaveUserIconByName(userName, fileName);
}
catch (Exception ex)
{
var nv = new NameValueCollection();
nv.Add("UpLoadFileName", filePath);
ExceptionManager.Publish(ex, nv);
}
}
return ret;
}
}
}

View File

@ -1,38 +0,0 @@
using Bootstrap.DataAccess;
using Longbow.Caching.Configuration;
using Newtonsoft.Json.Linq;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
/// <summary>
///
/// </summary>
public class SettingsController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpPost]
public bool Post([FromBody]JObject value)
{
//保存个性化设置
dynamic json = value;
return DictHelper.SaveSettings((string)json.name, (string)json.code, (string)json.category);
}
/// <summary>
///
/// </summary>
/// <param name="value"></param>
[HttpGet]
public IEnumerable<CacheListElement> Get([FromUri]JObject value)
{
var section = CacheListSection.GetSection();
return section.Items.Where(item => item.Enabled);
}
}
}

View File

@ -1,21 +0,0 @@
using Bootstrap.DataAccess;
using System.Collections.Generic;
using System.Linq;
using System.Web.Http;
namespace Bootstrap.Admin.Controllers
{
public class WSController : ApiController
{
/// <summary>
///
/// </summary>
/// <param name="value"></param>
/// <returns></returns>
[HttpGet]
public List<MessageBody> Get()
{
return NotificationHelper.MessagePool.ToList();
}
}
}

View File

@ -1 +0,0 @@
<%@ Application Codebehind="Global.asax.cs" Inherits="Bootstrap.Admin.Global" Language="C#" %>

View File

@ -1,20 +0,0 @@
using System;
using System.Web;
using System.Web.Http;
using System.Web.Mvc;
using System.Web.Routing;
namespace Bootstrap.Admin
{
public class Global : HttpApplication
{
void Application_Start(object sender, EventArgs e)
{
// Code that runs on application startup
AreaRegistration.RegisterAllAreas();
GlobalConfiguration.Configure(WebApiConfig.Register);
RouteConfig.RegisterRoutes(RouteTable.Routes);
FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
}
}
}

View File

@ -1,5 +1,6 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using System.Security.Principal;
using System.Web;
namespace Bootstrap.Admin.Models
@ -9,9 +10,9 @@ namespace Bootstrap.Admin.Models
/// </summary>
public class HeaderBarModel : ModelBase
{
public HeaderBarModel()
public HeaderBarModel(IIdentity identity)
{
var user = BootstrapUser.RetrieveUserByUserName(HttpContext.Current.User.Identity.Name);
var user = BootstrapUser.RetrieveUserByUserName(identity.Name);
Icon = user.Icon;
DisplayName = user.DisplayName;
UserName = user.UserName;

View File

@ -1,17 +0,0 @@
namespace Bootstrap.Admin.Models
{
/// <summary>
///
/// </summary>
public class LockModel : LoginModel
{
/// <summary>
///
/// </summary>
public string DisplayName { get; set; }
/// <summary>
///
/// </summary>
public string ReturnUrl { get; set; }
}
}

View File

@ -14,6 +14,7 @@ namespace Bootstrap.Admin.Models
{
Title = DictHelper.RetrieveWebTitle();
Footer = DictHelper.RetrieveWebFooter();
Theme = DictHelper.RetrieveActiveTheme();
}
/// <summary>
///
@ -23,5 +24,9 @@ namespace Bootstrap.Admin.Models
///
/// </summary>
public string Footer { get; private set; }
/// <summary>
///
/// </summary>
public string Theme { get; private set; }
}
}

View File

@ -1,14 +1,15 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Microsoft.AspNetCore.Mvc;
using System.Collections.Generic;
namespace Bootstrap.Admin.Models
{
public class NavigatorBarModel : HeaderBarModel
{
public NavigatorBarModel(string url)
public NavigatorBarModel(ControllerBase controller) : base(controller.User.Identity)
{
Navigations = BootstrapMenu.RetrieveSystemMenus(UserName, url);
Navigations = BootstrapMenu.RetrieveSystemMenus(UserName, $"~{controller.HttpContext.Request.Path}");
Applications = DictHelper.RetrieveApps();
HomeUrl = "~/Admin/Index";
}

View File

@ -1,37 +1,33 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.IO;
using System.Web;
namespace Bootstrap.Admin.Models
{
/// <summary>
///
/// </summary>
public class ProfilesModel : NavigatorBarModel
public class ProfilesModel : ThemeModel
{
/// <summary>
/// 获得/设置 头像文件大小
/// </summary>
public long Size { get; }
/// <summary>
/// 获得 系统配置的所有样式表
/// </summary>
public IEnumerable<BootstrapDict> Csss { get; }
/// <summary>
///
/// </summary>
/// <param name="url"></param>
public ProfilesModel(string url) : base(url)
/// <param name="controller"></param>
public ProfilesModel(ControllerBase controller) : base(controller)
{
var fileName = HttpContext.Current.Server.MapPath(Icon);
// TODO: 找到MapPath方法
var fileName = AppContext.BaseDirectory + Icon;
if (File.Exists(fileName))
{
Size = new FileInfo(fileName).Length;
}
Csss = DictHelper.RetrieveWebCss();
}
}
}

View File

@ -0,0 +1,26 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Microsoft.AspNetCore.Mvc;
using System.Collections.Generic;
namespace Bootstrap.Admin.Models
{
/// <summary>
///
/// </summary>
public class ThemeModel : NavigatorBarModel
{
/// <summary>
///
/// </summary>
/// <param name="controller"></param>
public ThemeModel(ControllerBase controller) : base(controller)
{
Themes = DictHelper.RetrieveThemes();
}
/// <summary>
/// 获得 系统配置的所有样式表
/// </summary>
public IEnumerable<BootstrapDict> Themes { get; }
}
}

View File

@ -0,0 +1,16 @@
using Microsoft.AspNetCore;
using Microsoft.AspNetCore.Hosting;
namespace Bootstrap.Admin
{
public class Program
{
public static void Main(string[] args)
{
CreateWebHostBuilder(args).Build().Run();
}
public static IWebHostBuilder CreateWebHostBuilder(string[] args) =>
WebHost.CreateDefaultBuilder(args).UseStartup<Startup>();
}
}

View File

@ -1,40 +0,0 @@
using System;
using System.Reflection;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
#if DEBUG
[assembly: AssemblyTitle("Bootstrap.Admin Debug Version")]
#else
[assembly: AssemblyTitle("Bootstrap.Admin Release Version")]
#endif
[assembly: AssemblyDescription("Bootstrap.Admin Web Component")]
//[assembly: AssemblyConfiguration("")]
//[assembly: AssemblyCompany("")]
//[assembly: AssemblyProduct("Bootstrap.DataAccess")]
//[assembly: AssemblyCopyright("Copyright © 2016")]
//[assembly: AssemblyTrademark("")]
//[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
[assembly: CLSCompliant(true)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("7b2b7043-3cb2-4c5a-bdf2-8c47f1a5471a")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
//[assembly: AssemblyVersion("1.0.0.0")]
//[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@ -0,0 +1,28 @@
{
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "http://localhost:50852/",
"sslPort": 0
}
},
"profiles": {
"IIS Express": {
"commandName": "IISExpress",
"launchBrowser": true,
"environmentVariables": {
"DOTNET_USE_POLLING_FILE_WATCHER": "true",
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"Bootstrap.Admin": {
"commandName": "Project",
"launchBrowser": true,
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
},
"applicationUrl": "http://localhost:50853/"
}
}
}

View File

@ -1,65 +1,65 @@
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Models
{
public class QueryDictOption : PaginationOption
{
/// <summary>
/// 字典分项
/// </summary>
public string Category { get; set; }
/// <summary>
/// 字典名称
/// </summary>
public string Name { get; set; }
/// <summary>
/// 字典种类
/// </summary>
public string Define { get; set; }
/// <summary>
/// 字典表查询
/// </summary>
/// <returns></returns>
public QueryData<BootstrapDict> RetrieveData()
{
var data = DictHelper.RetrieveDicts();
if (!string.IsNullOrEmpty(Category))
{
data = data.Where(t => t.Category.Contains(Category));
}
if (!string.IsNullOrEmpty(Name))
{
data = data.Where(t => t.Name.Contains(Name));
}
if (!string.IsNullOrEmpty(Define))
{
data = data.Where(t => t.Define.ToString() == Define);
}
var ret = new QueryData<BootstrapDict>();
ret.total = data.Count();
// 通过option.Sort属性判断对那列进行排序
switch (Sort)
{
case "Category":
data = Order == "asc" ? data.OrderBy(t => t.Category) : data.OrderByDescending(t => t.Category);
break;
case "Name":
data = Order == "asc" ? data.OrderBy(t => t.Name) : data.OrderByDescending(t => t.Name);
break;
case "Code":
data = Order == "asc" ? data.OrderBy(t => t.Code) : data.OrderByDescending(t => t.Code);
break;
case "Define":
data = Order == "asc" ? data.OrderBy(t => t.Define) : data.OrderByDescending(t => t.Define);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
using Bootstrap.DataAccess;
using Bootstrap.Security;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Query
{
public class QueryDictOption : PaginationOption
{
/// <summary>
/// 字典分项
/// </summary>
public string Category { get; set; }
/// <summary>
/// 字典名称
/// </summary>
public string Name { get; set; }
/// <summary>
/// 字典种类
/// </summary>
public string Define { get; set; }
/// <summary>
/// 字典表查询
/// </summary>
/// <returns></returns>
public QueryData<BootstrapDict> RetrieveData()
{
var data = DictHelper.RetrieveDicts();
if (!string.IsNullOrEmpty(Category))
{
data = data.Where(t => t.Category.Contains(Category));
}
if (!string.IsNullOrEmpty(Name))
{
data = data.Where(t => t.Name.Contains(Name));
}
if (!string.IsNullOrEmpty(Define))
{
data = data.Where(t => t.Define.ToString() == Define);
}
var ret = new QueryData<BootstrapDict>();
ret.total = data.Count();
// 通过option.Sort属性判断对那列进行排序
switch (Sort)
{
case "Category":
data = Order == "asc" ? data.OrderBy(t => t.Category) : data.OrderByDescending(t => t.Category);
break;
case "Name":
data = Order == "asc" ? data.OrderBy(t => t.Name) : data.OrderByDescending(t => t.Name);
break;
case "Code":
data = Order == "asc" ? data.OrderBy(t => t.Code) : data.OrderByDescending(t => t.Code);
break;
case "Define":
data = Order == "asc" ? data.OrderBy(t => t.Define) : data.OrderByDescending(t => t.Define);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}

View File

@ -1,57 +1,57 @@
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System;
using System.Globalization;
using System.Linq;
namespace Bootstrap.Admin.Models
{
public class QueryExceptionOption : PaginationOption
{
/// <summary>
///
/// </summary>
public DateTime StartTime { get; set; }
/// <summary>
///
/// </summary>
public DateTime EndTime { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Exceptions> RetrieveData()
{
var data = ExceptionHelper.RetrieveExceptions();
if (StartTime > DateTime.MinValue)
{
data = data.Where(t => t.LogTime > StartTime);
}
if (EndTime > DateTime.MinValue)
{
data = data.Where(t => t.LogTime < EndTime.AddDays(1));
}
var ret = new QueryData<Exceptions>();
ret.total = data.Count();
switch (Sort)
{
case "ErrorPage":
data = Order == "asc" ? data.OrderBy(t => t.ErrorPage) : data.OrderByDescending(t => t.ErrorPage);
break;
case "UserID":
data = Order == "asc" ? data.OrderBy(t => t.UserId) : data.OrderByDescending(t => t.UserId);
break;
case "UserIp":
data = Order == "asc" ? data.OrderBy(t => t.UserIp) : data.OrderByDescending(t => t.UserIp);
break;
case "LogTime":
data = Order == "asc" ? data.OrderBy(t => t.LogTime) : data.OrderByDescending(t => t.LogTime);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System;
using System.Globalization;
using System.Linq;
namespace Bootstrap.Admin.Query
{
public class QueryExceptionOption : PaginationOption
{
/// <summary>
///
/// </summary>
public DateTime StartTime { get; set; }
/// <summary>
///
/// </summary>
public DateTime EndTime { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Exceptions> RetrieveData()
{
var data = ExceptionHelper.RetrieveExceptions();
if (StartTime > DateTime.MinValue)
{
data = data.Where(t => t.LogTime > StartTime);
}
if (EndTime > DateTime.MinValue)
{
data = data.Where(t => t.LogTime < EndTime.AddDays(1));
}
var ret = new QueryData<Exceptions>();
ret.total = data.Count();
switch (Sort)
{
case "ErrorPage":
data = Order == "asc" ? data.OrderBy(t => t.ErrorPage) : data.OrderByDescending(t => t.ErrorPage);
break;
case "UserID":
data = Order == "asc" ? data.OrderBy(t => t.UserId) : data.OrderByDescending(t => t.UserId);
break;
case "UserIp":
data = Order == "asc" ? data.OrderBy(t => t.UserIp) : data.OrderByDescending(t => t.UserIp);
break;
case "LogTime":
data = Order == "asc" ? data.OrderBy(t => t.LogTime) : data.OrderByDescending(t => t.LogTime);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}

View File

@ -1,40 +1,40 @@
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Models
{
public class QueryGroupOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string GroupName { get; set; }
/// <summary>
///
/// </summary>
public string Description { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Group> RetrieveData()
{
// int limit, int offset, string name, string price, string sort, string order
var data = GroupHelper.RetrieveGroups();
if (!string.IsNullOrEmpty(GroupName))
{
data = data.Where(t => t.GroupName.Contains(GroupName));
}
if (!string.IsNullOrEmpty(Description))
{
data = data.Where(t => t.Description.Contains(Description));
}
var ret = new QueryData<Group>();
ret.total = data.Count();
data = Order == "asc" ? data.OrderBy(t => t.GroupName) : data.OrderByDescending(t => t.GroupName);
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Query
{
public class QueryGroupOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string GroupName { get; set; }
/// <summary>
///
/// </summary>
public string Description { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Group> RetrieveData()
{
// int limit, int offset, string name, string price, string sort, string order
var data = GroupHelper.RetrieveGroups();
if (!string.IsNullOrEmpty(GroupName))
{
data = data.Where(t => t.GroupName.Contains(GroupName));
}
if (!string.IsNullOrEmpty(Description))
{
data = data.Where(t => t.Description.Contains(Description));
}
var ret = new QueryData<Group>();
ret.total = data.Count();
data = Order == "asc" ? data.OrderBy(t => t.GroupName) : data.OrderByDescending(t => t.GroupName);
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}

View File

@ -1,70 +1,70 @@
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System;
using System.Globalization;
using System.Linq;
namespace Bootstrap.Admin.Models
{
public class QueryLogOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string OperateType { get; set; }
/// <summary>
///
/// </summary>
public DateTime OperateTimeStart { get; set; }
/// <summary>
///
/// </summary>
public DateTime OperateTimeEnd { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Log> RetrieveData()
{
var data = LogHelper.RetrieveLogs();
if (!string.IsNullOrEmpty(OperateType))
{
data = data.Where(t => t.CRUD.ToString().Contains(OperateType));
}
if (OperateTimeStart > DateTime.MinValue)
{
data = data.Where(t => t.LogTime > OperateTimeStart);
}
if (OperateTimeEnd > DateTime.MinValue)
{
data = data.Where(t => t.LogTime < OperateTimeEnd.AddDays(1));
}
var ret = new QueryData<Log>();
ret.total = data.Count();
switch (Sort)
{
case "CRUD":
data = Order == "asc" ? data.OrderBy(t => t.CRUD) : data.OrderByDescending(t => t.CRUD);
break;
case "UserName":
data = Order == "asc" ? data.OrderBy(t => t.UserName) : data.OrderByDescending(t => t.UserName);
break;
case "LogTime":
data = Order == "asc" ? data.OrderBy(t => t.LogTime) : data.OrderByDescending(t => t.LogTime);
break;
case "ClientIp":
data = Order == "asc" ? data.OrderBy(t => t.ClientIp) : data.OrderByDescending(t => t.ClientIp);
break;
case "RequestUrl":
data = Order == "asc" ? data.OrderBy(t => t.RequestUrl) : data.OrderByDescending(t => t.RequestUrl);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System;
using System.Globalization;
using System.Linq;
namespace Bootstrap.Admin.Query
{
public class QueryLogOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string OperateType { get; set; }
/// <summary>
///
/// </summary>
public DateTime OperateTimeStart { get; set; }
/// <summary>
///
/// </summary>
public DateTime OperateTimeEnd { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Log> RetrieveData()
{
var data = LogHelper.RetrieveLogs();
if (!string.IsNullOrEmpty(OperateType))
{
data = data.Where(t => t.CRUD.ToString().Contains(OperateType));
}
if (OperateTimeStart > DateTime.MinValue)
{
data = data.Where(t => t.LogTime > OperateTimeStart);
}
if (OperateTimeEnd > DateTime.MinValue)
{
data = data.Where(t => t.LogTime < OperateTimeEnd.AddDays(1));
}
var ret = new QueryData<Log>();
ret.total = data.Count();
switch (Sort)
{
case "CRUD":
data = Order == "asc" ? data.OrderBy(t => t.CRUD) : data.OrderByDescending(t => t.CRUD);
break;
case "UserName":
data = Order == "asc" ? data.OrderBy(t => t.UserName) : data.OrderByDescending(t => t.UserName);
break;
case "LogTime":
data = Order == "asc" ? data.OrderBy(t => t.LogTime) : data.OrderByDescending(t => t.LogTime);
break;
case "ClientIp":
data = Order == "asc" ? data.OrderBy(t => t.ClientIp) : data.OrderByDescending(t => t.ClientIp);
break;
case "RequestUrl":
data = Order == "asc" ? data.OrderBy(t => t.RequestUrl) : data.OrderByDescending(t => t.RequestUrl);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}

View File

@ -1,77 +1,77 @@
using Bootstrap.Security;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Models
{
public class QueryMenuOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string Name { get; set; }
/// <summary>
///
/// </summary>
public string ParentName { get; set; }
/// <summary>
///
/// </summary>
public string Category { get; set; }
/// <summary>
///
/// </summary>
public string IsResource { get; set; }
public QueryData<BootstrapMenu> RetrieveData(string userName)
{
var data = BootstrapMenu.RetrieveMenusByUserName(userName);
if (!string.IsNullOrEmpty(ParentName))
{
data = data.Where(t => t.ParentName.Contains(ParentName));
}
if (!string.IsNullOrEmpty(Name))
{
data = data.Where(t => t.Name.Contains(Name));
}
if (!string.IsNullOrEmpty(Category))
{
data = data.Where(t => t.Category.Contains(Category));
}
if (!string.IsNullOrEmpty(IsResource))
{
data = data.Where(t => t.IsResource.ToString() == IsResource);
}
var ret = new QueryData<BootstrapMenu>();
ret.total = data.Count();
switch (Sort)
{
case "Name":
data = Order == "asc" ? data.OrderBy(t => t.Name) : data.OrderByDescending(t => t.Name);
break;
case "ParentName":
data = Order == "asc" ? data.OrderBy(t => t.ParentName) : data.OrderByDescending(t => t.ParentName);
break;
case "Order":
data = Order == "asc" ? data.OrderBy(t => t.Order) : data.OrderByDescending(t => t.Order);
break;
case "CategoryName":
data = Order == "asc" ? data.OrderBy(t => t.CategoryName) : data.OrderByDescending(t => t.CategoryName);
break;
case "Target":
data = Order == "asc" ? data.OrderBy(t => t.Target) : data.OrderByDescending(t => t.Target);
break;
case "IsResource":
data = Order == "asc" ? data.OrderBy(t => t.IsResource) : data.OrderByDescending(t => t.IsResource);
break;
case "ApplicationCode":
data = Order == "asc" ? data.OrderBy(t => t.ApplicationCode) : data.OrderByDescending(t => t.ApplicationCode);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
using Bootstrap.Security;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Query
{
public class QueryMenuOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string Name { get; set; }
/// <summary>
///
/// </summary>
public string ParentName { get; set; }
/// <summary>
///
/// </summary>
public string Category { get; set; }
/// <summary>
///
/// </summary>
public string IsResource { get; set; }
public QueryData<BootstrapMenu> RetrieveData(string userName)
{
var data = BootstrapMenu.RetrieveMenusByUserName(userName);
if (!string.IsNullOrEmpty(ParentName))
{
data = data.Where(t => t.ParentName.Contains(ParentName));
}
if (!string.IsNullOrEmpty(Name))
{
data = data.Where(t => t.Name.Contains(Name));
}
if (!string.IsNullOrEmpty(Category))
{
data = data.Where(t => t.Category.Contains(Category));
}
if (!string.IsNullOrEmpty(IsResource))
{
data = data.Where(t => t.IsResource.ToString() == IsResource);
}
var ret = new QueryData<BootstrapMenu>();
ret.total = data.Count();
switch (Sort)
{
case "Name":
data = Order == "asc" ? data.OrderBy(t => t.Name) : data.OrderByDescending(t => t.Name);
break;
case "ParentName":
data = Order == "asc" ? data.OrderBy(t => t.ParentName) : data.OrderByDescending(t => t.ParentName);
break;
case "Order":
data = Order == "asc" ? data.OrderBy(t => t.Order) : data.OrderByDescending(t => t.Order);
break;
case "CategoryName":
data = Order == "asc" ? data.OrderBy(t => t.CategoryName) : data.OrderByDescending(t => t.CategoryName);
break;
case "Target":
data = Order == "asc" ? data.OrderBy(t => t.Target) : data.OrderByDescending(t => t.Target);
break;
case "IsResource":
data = Order == "asc" ? data.OrderBy(t => t.IsResource) : data.OrderByDescending(t => t.IsResource);
break;
case "ApplicationCode":
data = Order == "asc" ? data.OrderBy(t => t.ApplicationCode) : data.OrderByDescending(t => t.ApplicationCode);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}

View File

@ -1,40 +1,40 @@
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Models
{
public class QueryRoleOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string RoleName { get; set; }
/// <summary>
///
/// </summary>
public string Description { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Role> RetrieveData()
{
// int limit, int offset, string name, string price, string sort, string order
var data = RoleHelper.RetrieveRoles();
if (!string.IsNullOrEmpty(RoleName))
{
data = data.Where(t => t.RoleName.Contains(RoleName));
}
if (!string.IsNullOrEmpty(Description))
{
data = data.Where(t => t.Description.Contains(Description));
}
var ret = new QueryData<Role>();
ret.total = data.Count();
data = Order == "asc" ? data.OrderBy(t => t.RoleName) : data.OrderByDescending(t => t.RoleName);
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Query
{
public class QueryRoleOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string RoleName { get; set; }
/// <summary>
///
/// </summary>
public string Description { get; set; }
/// <summary>
///
/// </summary>
/// <returns></returns>
public QueryData<Role> RetrieveData()
{
// int limit, int offset, string name, string price, string sort, string order
var data = RoleHelper.RetrieveRoles();
if (!string.IsNullOrEmpty(RoleName))
{
data = data.Where(t => t.RoleName.Contains(RoleName));
}
if (!string.IsNullOrEmpty(Description))
{
data = data.Where(t => t.Description.Contains(Description));
}
var ret = new QueryData<Role>();
ret.total = data.Count();
data = Order == "asc" ? data.OrderBy(t => t.RoleName) : data.OrderByDescending(t => t.RoleName);
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}

View File

@ -1,59 +1,59 @@
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Models
{
/// <summary>
///
/// </summary>
public class QueryUserOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string Name { get; set; }
/// <summary>
///
/// </summary>
public string DisplayName { get; set; }
public QueryData<User> RetrieveData()
{
// int limit, int offset, string name, string price, string sort, string order
var data = UserHelper.RetrieveUsers();
if (!string.IsNullOrEmpty(Name))
{
data = data.Where(t => t.UserName.Contains(Name));
}
if (!string.IsNullOrEmpty(DisplayName))
{
data = data.Where(t => t.DisplayName.Contains(DisplayName));
}
var ret = new QueryData<User>();
ret.total = data.Count();
switch (Sort)
{
case "UserName":
data = Order == "asc" ? data.OrderBy(t => t.UserName) : data.OrderByDescending(t => t.UserName);
break;
case "DisplayName":
data = Order == "asc" ? data.OrderBy(t => t.DisplayName) : data.OrderByDescending(t => t.DisplayName);
break;
case "RegisterTime":
data = Order == "asc" ? data.OrderBy(t => t.RegisterTime) : data.OrderByDescending(t => t.RegisterTime);
break;
case "ApprovedTime":
data = Order == "asc" ? data.OrderBy(t => t.ApprovedTime) : data.OrderByDescending(t => t.ApprovedTime);
break;
case "ApprovedBy":
data = Order == "asc" ? data.OrderBy(t => t.ApprovedBy) : data.OrderByDescending(t => t.ApprovedBy);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
using Bootstrap.DataAccess;
using Longbow.Web.Mvc;
using System.Linq;
namespace Bootstrap.Admin.Query
{
/// <summary>
///
/// </summary>
public class QueryUserOption : PaginationOption
{
/// <summary>
///
/// </summary>
public string Name { get; set; }
/// <summary>
///
/// </summary>
public string DisplayName { get; set; }
public QueryData<User> RetrieveData()
{
// int limit, int offset, string name, string price, string sort, string order
var data = UserHelper.RetrieveUsers();
if (!string.IsNullOrEmpty(Name))
{
data = data.Where(t => t.UserName.Contains(Name));
}
if (!string.IsNullOrEmpty(DisplayName))
{
data = data.Where(t => t.DisplayName.Contains(DisplayName));
}
var ret = new QueryData<User>();
ret.total = data.Count();
switch (Sort)
{
case "UserName":
data = Order == "asc" ? data.OrderBy(t => t.UserName) : data.OrderByDescending(t => t.UserName);
break;
case "DisplayName":
data = Order == "asc" ? data.OrderBy(t => t.DisplayName) : data.OrderByDescending(t => t.DisplayName);
break;
case "RegisterTime":
data = Order == "asc" ? data.OrderBy(t => t.RegisterTime) : data.OrderByDescending(t => t.RegisterTime);
break;
case "ApprovedTime":
data = Order == "asc" ? data.OrderBy(t => t.ApprovedTime) : data.OrderByDescending(t => t.ApprovedTime);
break;
case "ApprovedBy":
data = Order == "asc" ? data.OrderBy(t => t.ApprovedBy) : data.OrderByDescending(t => t.ApprovedBy);
break;
default:
break;
}
ret.rows = data.Skip(Offset).Take(Limit);
return ret;
}
}
}

View File

@ -1,4 +0,0 @@
$(function () {
$('#navbar').attr('data-toggle', "dropdown").addClass('dropdown-toggle');
$('#breadNav').hide();
});

View File

@ -1,15 +0,0 @@
$(function () {
$(".container").autoCenter();
// validate
$('#login').autoValidate({
userName: {
required: true,
maxlength: 50
},
password: {
required: true,
maxlength: 50
}
});
})

View File

@ -1,97 +0,0 @@
$(function () {
var $headerIcon = $('#headerIcon');
var preIcon = $headerIcon.attr('src');
$('#fileIcon').fileinput({
uploadUrl: Profiles.url,
language: 'zh',
maxFileSize: 5000,
allowedFileExtensions: ['jpg', 'png', 'bmp', 'gif', 'jpeg'],
initialPreview: [
preIcon
],
initialPreviewConfig: [
{ caption: "现在头像", size: $('#fileIcon').attr('data-init'), showZoom: false },
],
initialPreviewAsData: true,
overwriteInitial: true,
dropZoneTitle: "请选择头像"
}).on('fileuploaded', function (event, data, previewId, index) {
var url = data.response;
if (!!url) $headerIcon.attr('src', url);
});
$('#infoDataForm').autoValidate({
displayName: {
required: true,
maxlength: 50
}
}, {
button: ['btnSaveDisplayName']
});
$('#passwordDataForm').autoValidate({
currentPassword: {
required: true,
maxlength: 50
},
newPassword: {
required: true,
maxlength: 50
},
confirmPassword: {
required: true,
equalTo: "#newPassword",
maxlength: 50
}
}, {
button: ['btnSavePassword']
});
var bsa = new BootstrapAdmin({
url: Profiles.url,
bootstrapTable: null,
dataEntity: new DataEntity({
map: {
Password: "currentPassword",
NewPassword: "newPassword",
DisplayName: "displayName",
UserName: "userName",
Css: "css"
}
}),
click: {
assign: [{
id: 'btnSavePassword',
click: function (row, data) {
if ($(this).attr('data-valid') == "true") {
data.UserStatus = 2;
$.bc({ url: User.url, method: "PUT", data: data, title: "更改密码" });
}
}
}, {
id: 'btnSaveDisplayName',
click: function (row, data) {
if ($(this).attr('data-valid') == "true") {
data.UserStatus = 1;
$.bc({
url: User.url, method: "PUT", data: data, title: "修改用户显示名称",
callback: function (result) {
if (result) {
$('#userDisplayName').text(data.DisplayName);
}
}
});
}
}
}, {
id: 'btnSaveCss',
click: function (row, data) {
data.UserStatus = 3;
$.bc({ url: User.url, method: "PUT", data: data, title: "保存样式" });
}
}]
}
});
$('button[data-admin="False"]').removeAttr('disabled');
$('#kvFileinputModal').appendTo('body');
});

View File

@ -1,178 +0,0 @@
$(function () {
$('a[data-admin="False"]').hide();
$('#headerDataForm').autoValidate({
sysName: {
required: true,
maxlength: 50
}
}, {
button: ['sysSave']
});
$('#footerDataForm').autoValidate({
sysFoot: {
required: true,
maxlength: 50
}
}, {
button: ['footSave']
});
var bsa = new BootstrapAdmin({
url: Settings.url,
bootstrapTable: null,
validateForm: null,
modal: null,
dataEntity: new DataEntity({
map: {
Title: "sysName",
Footer: "sysFoot"
}
}),
click: {
assign: [{
id: 'sysSave',
click: function (row, data) {
if ($(this).attr('data-valid') == "true") {
$.bc({
url: Settings.url, data: { name: '网站标题', code: data.Title, category: Settings.title }, title: Settings.title,
callback: function (result) {
if (result) $('#websiteTitle').text(data.Title);
}
});
}
}
}, {
id: 'footSave',
click: function (row, data) {
if ($(this).attr('data-valid') == "true") {
$.bc({
url: Settings.url, data: { name: '网站页脚', code: data.Footer, category: Settings.title }, title: Settings.title,
callback: function (result) {
if (result) $('#websiteFooter').text(data.Footer);
}
});
}
}
}, {
id: 'cssSave',
click: function (row, data) {
var cssDefine = $('#dictCssDefine').val();
$.bc({
url: Settings.url, data: { name: '使用样式', code: cssDefine, category: '当前样式' }, title: '网站样式',
callback: function (result) {
if (result) {
window.setTimeout(function () { window.location.reload(true); }, 1000);
}
}
});
}
}]
}
});
var $sortable = $('#sortable');
var listCacheUrl = function (options) {
options = $.extend({ clear: false }, options);
$sortable.html('');
$.bc({
url: Settings.url,
method: 'GET',
swal: false,
callback: function (result) {
if (result && $.isArray(result)) {
$.each(result, function (index, item) {
listCache($.extend({ item: item, url: item.Url }, options));
});
}
}
});
}
var listCache = function (options) {
options = $.extend({ clear: false, key: '' }, options);
if (options.key != '') {
options.url = $.format(options.url, options.key);
}
if (options.clear) {
options.url += '&clear=clear';
}
$.bc({
url: options.url,
swal: false,
callback: function (result) {
if (result && options.key == '') {
result = $.parseJSON(result);
if ($.isArray(result)) {
var html = '<li class="{4}"><i class="fa fa-ellipsis-v"></i><div class="task-title"><span class="task-title-sp" role="tooltip" title="{1}">{2}</span><span class="badge badge-sm label-success">{0}</span><span class="task-value" title="{3}">{3}</span><div class="pull-right hidden-phone"><span>{6}</span><button class="btn btn-danger btn-xs fa fa-trash-o" title="{1}" data-key="{1}" data-url="{5}" role="tooltip" data-placement="left"></button></div></div></li>';
var content = result.sort(function (x, y) {
return x.Key > y.Key ? 1 : -1;
}).map(function (ele) {
var key = ele.Key.split('-')[0];
var css = 'list-default';
switch (key) {
case "MenuHelper":
css = 'list-primary';
break;
case "UserHelper":
css = 'list-success';
break;
case "RoleHelper":
css = 'list-danger';
break;
case "GroupHelper":
css = 'list-warning';
break;
case "LogHelper":
css = 'list-info';
break;
case "DictHelper":
css = 'list-inverse';
break;
case "ExceptionHelper":
css = 'list-Exception';
break;
case "MessageHelper":
css = 'list-Message';
break;
case "TaskHelper":
css = 'list-Task';
break;
case "NotificationHelper":
css = 'list-Notification';
break;
default:
break;
}
return $.format(html, ele.Interval, ele.Key, ele.Desc, ele.Value, css, options.url, Math.max(0, ele.Interval - Math.round((new Date() - new Date(ele.CreateTime.replace(/-/g, '/'))) / 1000)));
}).join('');
$sortable.append($.format('<li class="title">{0}-{1}</li>', options.item.Desc, options.item.Key));
$sortable.append(content);
$sortable.find('[role="tooltip"]').lgbTooltip();
}
}
}
});
}
$('#refreshCache').click(function () { listCacheUrl(); }).trigger('click');
$('#clearCache').click(function () { listCacheUrl({ clear: true }); });
$sortable.on('click', '.btn', function () {
$(this).lgbTooltip('destroy');
listCache({ key: $(this).attr('data-key'), url: $(this).attr('data-url') });
listCacheUrl();
});
$.bc({
Id: 1, url: Dicts.url, data: { type: 'css' }, swal: false,
callback: function (result) {
var html = result.map(function (ele, index) { return $.format('<li><a href="#" data-val="{1}">{0}</a></li>', ele.Name, ele.Code); }).join('');
$('#cssContainer').append(html);
$.bc({
Id: 1, url: Dicts.url, data: { type: 'activeCss' }, swal: false,
callback: function (result) {
if (result.length > 0)
$('.lgbDropdown').lgbDropdown('val', result[0].Code);
}
});
}
});
})

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@ -1,17 +0,0 @@
$(function () {
$('body').addClass('lock-screen');
$('#time').text((new Date()).format('HH:mm:ss'));
setInterval(function () {
$('#time').text((new Date()).format('HH:mm:ss'));
}, 500);
$.extend($.validator.messages, { required: "请输入密码" });
// validate
$('form').autoValidate({
password: {
required: true,
maxlength: 50
}
});
});

View File

@ -1,33 +0,0 @@
(function (factory) {
if (typeof define === "function" && define.amd) {
define(["jquery", "../jquery.validate"], factory);
} else if (typeof module === "object" && module.exports) {
module.exports = factory(require("jquery"));
} else {
factory(jQuery);
}
}(function ($) {
/*
* Translated default messages for the jQuery validation plugin.
* Locale: ZH (Chinese, 中文 (Zhōngwén), 汉语, 漢語)
*/
$.extend($.validator.messages, {
required: "这是必填字段",
remote: "请修正此字段",
email: "请输入有效的电子邮件地址",
url: "请输入有效的网址",
date: "请输入有效的日期",
dateISO: "请输入有效的日期 (YYYY-MM-DD)",
number: "请输入有效的数字",
digits: "只能输入数字",
creditcard: "请输入有效的信用卡号码",
equalTo: "你的输入不相同",
extension: "请输入有效的后缀",
maxlength: $.validator.format("最多可以输入 {0} 个字符"),
minlength: $.validator.format("最少要输入 {0} 个字符"),
rangelength: $.validator.format("请输入长度在 {0} 到 {1} 之间的字符串"),
range: $.validator.format("请输入范围在 {0} 到 {1} 之间的数值"),
max: $.validator.format("请输入不大于 {0} 的数值"),
min: $.validator.format("请输入不小于 {0} 的数值")
});
}));

View File

@ -1,4 +0,0 @@
/*! jQuery Validation Plugin - v1.15.0 - 2/24/2016
* http://jqueryvalidation.org/
* Copyright (c) 2016 Jörn Zaefferer; Licensed MIT */
!function(a){"function"==typeof define&&define.amd?define(["jquery","../jquery.validate.min"],a):"object"==typeof module&&module.exports?module.exports=a(require("jquery")):a(jQuery)}(function(a){a.extend(a.validator.messages,{required:"这是必填字段",remote:"请修正此字段",email:"请输入有效的电子邮件地址",url:"请输入有效的网址",date:"请输入有效的日期",dateISO:"请输入有效的日期 (YYYY-MM-DD)",number:"请输入有效的数字",digits:"只能输入数字",creditcard:"请输入有效的信用卡号码",equalTo:"你的输入不相同",extension:"请输入有效的后缀",maxlength:a.validator.format("最多可以输入 {0} 个字符"),minlength:a.validator.format("最少要输入 {0} 个字符"),rangelength:a.validator.format("请输入长度在 {0} 到 {1} 之间的字符串"),range:a.validator.format("请输入范围在 {0} 到 {1} 之间的数值"),max:a.validator.format("请输入不大于 {0} 的数值"),min:a.validator.format("请输入不小于 {0} 的数值")})});

View File

@ -0,0 +1,95 @@
using Bootstrap.DataAccess;
using Bootstrap.Security.Filter;
using Bootstrap.Security.Middleware;
using Longbow.Cache;
using Longbow.Cache.Middleware;
using Longbow.Configuration;
using Longbow.Data;
using Longbow.Logging;
using Longbow.Web;
using Longbow.Web.WebSockets;
using Microsoft.AspNetCore.Authentication.Cookies;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.DataProtection;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Newtonsoft.Json;
using Newtonsoft.Json.Serialization;
using System;
using System.IO;
namespace Bootstrap.Admin
{
public class Startup
{
public Startup(IConfiguration configuration)
{
Configuration = configuration;
}
public IConfiguration Configuration { get; }
// This method gets called by the runtime. Use this method to add services to the container.
public void ConfigureServices(IServiceCollection services)
{
services.Configure<CookiePolicyOptions>(options =>
{
// This lambda determines whether user consent for non-essential cookies is needed for a given request.
options.CheckConsentNeeded = context => true;
options.MinimumSameSitePolicy = SameSiteMode.None;
});
services.AddCors();
services.AddLogging(builder => builder.AddFileLogger().AddDBLogger(ExceptionHelper.Log));
services.AddConfigurationManager();
services.AddCacheManager();
services.AddDBAccessFactory();
services.AddDataProtection(op => op.ApplicationDiscriminator = "BootstrapAdmin")
.SetApplicationName("__bd__")
.DisableAutomaticKeyGeneration()
.PersistKeysToFileSystem(new DirectoryInfo(ConfigurationManager.AppSettings["KeyPath"]));
services.AddMvc(options =>
{
options.Filters.Add<BootstrapAdminAuthorizeFilter>();
options.Filters.Add<ExceptionFilter>();
}).AddJsonOptions(options =>
{
options.SerializerSettings.ContractResolver = new DefaultContractResolver();
options.SerializerSettings.DateFormatString = "yyyy-MM-dd HH:mm:ss";
JsonConvert.DefaultSettings = () => options.SerializerSettings;
}).SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
services.AddAuthentication(CookieAuthenticationDefaults.AuthenticationScheme).AddCookie();
}
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
if (env.IsDevelopment())
{
app.UseDeveloperExceptionPage();
}
else
{
app.UseExceptionHandler("/Home/Error");
app.UseHsts();
}
app.UseStatusCodePagesWithReExecute("/Home/Error/{0}");
app.UseCors(builder => builder.WithOrigins(Configuration["AllowOrigins"].Split(',', StringSplitOptions.RemoveEmptyEntries)).AllowAnyHeader().AllowAnyMethod().AllowCredentials());
app.UseHttpsRedirection();
app.UseStaticFiles();
app.UseCookiePolicy();
app.UseAuthentication();
app.UseBootstrapRoleAuthorization();
app.UseWebSocketHandler(options => options.UseAuthentication = true);
app.UseCacheManagerCorsHandler();
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller=Home}/{action=Index}/{id?}");
});
}
}
}

View File

@ -0,0 +1,17 @@
@{
ViewBag.Title = "未授权请求";
Layout = "~/Views/Shared/_Root.cshtml";
}
@section css {
<link href="~/css/error.css" rel="stylesheet" />
}
@section Javascript {
<script src="~/js/error.js"></script>
}
<section class="error-wrapper">
<img src="~/images/error_icon.png" />
<h1>网页拒绝访问</h1>
<h3>您无权访问本页面请联系网站管理员授权后再查看</h3>
<br />
<a href="~/Home/Index" target="_top">返回首页</a>
</section>

View File

@ -0,0 +1,8 @@
@model Bootstrap.Admin.Models.ModelBase
@{
ViewBag.Title = Model.Title;
Layout = "~/Views/Shared/_Login.cshtml";
}
@section css {
<link href="~/css/login.css" rel="stylesheet" />
}

View File

@ -0,0 +1,8 @@
@model Bootstrap.Admin.Models.ModelBase
@{
ViewBag.Title = Model.Title;
Layout = "~/Views/Shared/_Login.cshtml";
}
@section css {
<link href="~/css/loginm.css" rel="stylesheet" />
}

View File

@ -1,18 +1,18 @@
@{
ViewBag.Title = "客户端测试";
Layout = "~/Views/Shared/_Layout.cshtml";
}
@section css {
<style type="text/css">
label {
word-break: break-all;
}
section {
padding-top: 15px;
}
</style>
}
<section class="container-fluid">
@Html.Partial("_Mobile")
@{
ViewBag.Title = "客户端测试";
Layout = "~/Views/Shared/_Layout.cshtml";
}
@section css {
<style type="text/css">
label {
word-break: break-all;
}
section {
padding-top: 15px;
}
</style>
}
<section class="container-fluid">
@await Html.PartialAsync("_Mobile")
</section>

View File

@ -1,107 +1,112 @@
@{
ViewBag.Title = "注册新用户";
Layout = "~/Views/Shared/_Layout.cshtml";
}
@section css {
<link href="~/Content/register.css" rel="stylesheet" />
}
@section javascript {
<script src="~/Scripts/jquery.validate.js"></script>
<script src="~/Scripts/messages_zh.js"></script>
<script src="~/Scripts/sweetalert.js"></script>
<script src="~/Scripts/register.js"></script>
}
<div class="container">
<div class="setup-wrapper">
<header><h2>新用户注册</h2></header>
<div class="setup-header">
<ol class="steps">
<li class="current">
<strong class="step">步骤 1:</strong><span>创建一个账号</span>
</li>
<li>
<strong class="step">步骤 2:</strong><span>确认信息</span>
</li>
</ol>
</div>
<form autocomplete="off" id="signup-form" method="post">
<div class="setup-main">
<div class="setup-form-container">
<h3 class="setup-form-title mb-3">
创建您的账号
</h3>
<div class="form-group">
<label for="userName">登陆账号:</label>
<div class="input-group">
<span class="input-group-addon">@@</span>
<input type="text" id="userName" name="userName" class="form-control" placeholder="登陆账号" value="" autofocus maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="displayName">显示名称:</label>
<div class="input-group">
<span class="glyphicon glyphicon-user input-group-addon"></span>
<input type="text" id="displayName" name="displayName" class="form-control" value="" placeholder="显示名称" maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="password">密码:</label>
<div class="input-group">
<span class="glyphicon glyphicon-lock input-group-addon"></span>
<input type="password" id="password" name="password" class="form-control" value="" placeholder="密码" maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="assurePassword">确认密码:</label>
<div class="input-group">
<span class="glyphicon glyphicon-lock input-group-addon"></span>
<input type="password" id="assurePassword" name="assurePassword" class="form-control" value="" placeholder="确认密码" maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="description">申请理由:</label>
<div class="input-group">
<span class="glyphicon glyphicon-certificate input-group-addon"></span>
<textarea id="description" name="description" class="form-control" placeholder="申请理由500字以内" rows="6" maxlength="500"></textarea>
</div>
</div>
<div class="form-group">
<button id="btnAccount" class="btn btn-primary pull-right" type="button">继续</button>
</div> <!-- /.setup-form-container -->
</div>
</div>
<div class="setup-confirm">
<h3>您注册的信息如下:</h3>
<div class="form-group">
<label>登陆账号:</label><span id="loginID" class="form-control-static"></span>
</div>
<div class="form-group">
<label>显示名称:</label><span id="loginName" class="form-control-static"></span>
</div>
<div class="form-group">
<label>申请理由:</label><span id="loginDesc" class="form-control-static"></span>
</div>
<div class="form-group">
<button id="btnPrev" class="btn btn-default" type="button">上一步</button>
<button id="btnSubmit" class="btn btn-primary pull-right" type="submit">确认并提交</button>
</div>
</div>
</form>
<div class="setup-secondary">
<div class="setup-info-module">
<h4>欢迎加入本系统</h4>
<ul class="features-list">
<li><strong>Unlimited</strong> 特性一</li>
<li><strong>Unlimited</strong> 特性二</li>
<li><strong>Unlimited</strong> 特性三</li>
<li><strong>Unlimited</strong> 特性四</li>
<li class="list-divider"></li>
<li><i class="glyphicon glyphicon-ok"></i> 优点一</li>
<li><i class="glyphicon glyphicon-ok"></i> 优点二</li>
<li><i class="glyphicon glyphicon-ok"></i> 优点三</li>
<li><i class="glyphicon glyphicon-ok"></i> 优点四</li>
</ul>
</div>
</div>
</div>
@{
ViewBag.Title = "注册新用户";
Layout = "~/Views/Shared/_Root.cshtml";
}
@section css {
<link href="~/css/bootstrap.css" rel="stylesheet">
<link href="~/css/bootstrap-theme.css" rel="stylesheet">
<link href="~/css/font-awesome.css" rel="stylesheet" />
<link href="~/css/register.css" rel="stylesheet" />
}
@section javascript {
<script src="~/js/bootstrap.js"></script>
<script src="~/js/Longbow.Common.js"></script>
<script src="~/js/jquery.validate.js"></script>
<script src="~/js/messages_zh.js"></script>
<script src="~/js/sweetalert.js"></script>
<script src="~/js/register.js"></script>
}
<div class="container">
<div class="setup-wrapper">
<header><h2>新用户注册</h2></header>
<div class="setup-header">
<ol class="steps">
<li class="current">
<strong class="step">步骤 1:</strong><span>创建一个账号</span>
</li>
<li>
<strong class="step">步骤 2:</strong><span>确认信息</span>
</li>
</ol>
</div>
<form autocomplete="off" id="signup-form" method="post">
<div class="setup-main">
<div class="setup-form-container">
<h3 class="setup-form-title mb-3">
创建您的账号
</h3>
<div class="form-group">
<label for="userName">登陆账号:</label>
<div class="input-group">
<span class="input-group-addon">@@</span>
<input type="text" id="userName" name="userName" class="form-control" placeholder="登陆账号" value="" autofocus maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="displayName">显示名称:</label>
<div class="input-group">
<span class="glyphicon glyphicon-user input-group-addon"></span>
<input type="text" id="displayName" name="displayName" class="form-control" value="" placeholder="显示名称" maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="password">密码:</label>
<div class="input-group">
<span class="glyphicon glyphicon-lock input-group-addon"></span>
<input type="password" id="password" name="password" class="form-control" value="" placeholder="密码" maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="assurePassword">确认密码:</label>
<div class="input-group">
<span class="glyphicon glyphicon-lock input-group-addon"></span>
<input type="password" id="assurePassword" name="assurePassword" class="form-control" value="" placeholder="确认密码" maxlength="50" />
</div>
</div>
<div class="form-group">
<label for="description">申请理由:</label>
<div class="input-group">
<span class="glyphicon glyphicon-certificate input-group-addon"></span>
<textarea id="description" name="description" class="form-control" placeholder="申请理由500字以内" rows="6" maxlength="500"></textarea>
</div>
</div>
<div class="form-group">
<button id="btnAccount" class="btn btn-primary pull-right" type="button">继续</button>
</div> <!-- /.setup-form-container -->
</div>
</div>
<div class="setup-confirm">
<h3>您注册的信息如下:</h3>
<div class="form-group">
<label>登陆账号:</label><span id="loginID" class="form-control-static"></span>
</div>
<div class="form-group">
<label>显示名称:</label><span id="loginName" class="form-control-static"></span>
</div>
<div class="form-group">
<label>申请理由:</label><span id="loginDesc" class="form-control-static"></span>
</div>
<div class="form-group">
<button id="btnPrev" class="btn btn-secondary" type="button">上一步</button>
<button id="btnSubmit" class="btn btn-primary pull-right" type="submit">确认并提交</button>
</div>
</div>
</form>
<div class="setup-secondary">
<div class="setup-info-module">
<h4>欢迎加入本系统</h4>
<ul class="features-list">
<li><strong>Unlimited</strong> 特性一</li>
<li><strong>Unlimited</strong> 特性二</li>
<li><strong>Unlimited</strong> 特性三</li>
<li><strong>Unlimited</strong> 特性四</li>
<li class="list-divider"></li>
<li><i class="glyphicon glyphicon-ok"></i> 优点一</li>
<li><i class="glyphicon glyphicon-ok"></i> 优点二</li>
<li><i class="glyphicon glyphicon-ok"></i> 优点三</li>
<li><i class="glyphicon glyphicon-ok"></i> 优点四</li>
</ul>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,30 @@
@model Bootstrap.Admin.Models.ModelBase
<h2 class="form-signin-heading">@Model.Title</h2>
<div class="login-wrap" data-toggle="LgbValidate" data-valid-button="#btnSubmit">
<div class="form-group">
<div class="input-group">
<div class="input-group-prepend">
<span class="fa fa-user input-group-text"></span>
</div>
<input type="text" name="userName" class="form-control" placeholder="用户名" data-required-msg="请输入用户名" value="" autofocus data-valid="true" />
</div>
</div>
<div class="form-group">
<div class="input-group">
<div class="input-group-prepend">
<span class="fa fa-lock input-group-text"></span>
</div>
<input type="password" name="password" class="form-control" value="" placeholder="密码" data-required-msg="请输入密码" data-valid="true" />
</div>
</div>
<div class="form-group">
<div class="form-check">
<input id="remember" name="remember" type="checkbox" class="form-check-input" value="true" /><label for="remember" class="form-check-label">记住我</label>
</div>
</div>
<button class="btn btn-lg btn-login btn-block" type="submit" id="btnSubmit">登 陆</button>
<div class="login-footer">
<div class="login-create"><a href="Register">申请账号</a></div>
<div class="login-reset"><a href="#">忘记密码</a></div>
</div>
</div>

View File

@ -1,13 +1,13 @@
@model NavigatorBarModel
@model Bootstrap.Admin.Models.NavigatorBarModel
@{
ViewBag.Title = "Api 文档";
Layout = "~/Views/Shared/_Admin.cshtml";
}
@section javascript {
<script src="~/Scripts/apidoc.js"></script>
<script src="~/js/apidoc.js"></script>
}
@section css {
<link href="~/Content/api.css" rel="stylesheet" />
<link href="~/css/api.css" rel="stylesheet" />
}
<section>
<div><h3>接口返回值定义</h3></div>

View File

@ -1,88 +1,77 @@
@model NavigatorBarModel
@model Bootstrap.Admin.Models.NavigatorBarModel
@{
ViewBag.Title = "字典表维护";
Layout = "~/Views/Shared/_Default.cshtml";
}
@section Javascript {
<script src="~/Scripts/bootstrap3-typeahead.js"></script>
<script src="~/scripts/Dicts.js"></script>
<script src="~/js/bootstrap3-typeahead.js"></script>
<script src="~/js/Dicts.js"></script>
}
@section query {
<form class="form-inline" role="form">
<div class="row">
<div class="form-group col-sm-6 col-lg-3">
<form class="form-inline">
<div class="form-row">
<div class="form-group col-sm-6 col-md-5">
<label class="control-label" for="txt_dict_cate">字典标签</label>
<input type="text" class="form-control" id="txt_dict_cate" data-provide="typeahead" />
</div>
<div class="form-group col-sm-6 col-lg-3">
<div class="form-group col-sm-6 col-md-5">
<label class="control-label" for="txt_dict_name">字典名称</label>
<input type="text" class="form-control" id="txt_dict_name" />
</div>
<div class="form-group col-sm-6 col-lg-3">
<div class="form-group col-sm-6 col-md-5">
<label class="control-label" for="txt_dict_define">字典类别</label>
<div class="dropdown lgbDropdown">
<a id="txt_dict_define" class="btn btn-success" data-toggle="dropdown">
<span>全部</span>
<span class="caret"></span>
</a>
<ul class="dropdown-menu" role="menu">
<li><a href="#" data-val="">全部</a></li>
<li class="divider"></li>
<li><a href="#" data-val="0">系统使用</a></li>
<li><a href="#" data-val="1">自定义</a></li>
</ul>
<div class="dropdown">
<button id="txt_dict_define" class="btn btn-success dropdown-select dropdown-toggle" data-toggle="dropdown">全部</button>
<div class="dropdown-menu">
<a href="#" data-val="">全部</a>
<div class="dropdown-divider"></div>
<a href="#" data-val="0">系统使用</a>
<a href="#" data-val="1">自定义</a>
</div>
</div>
</div>
<div class="form-group col-sm-6 col-lg-3">
<button type="button" id="btn_query" class="btn btn-primary form-control"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
<div class="form-group col-sm-6 col-md-5">
<button type="button" id="btn_query" class="btn btn-primary btn-fill"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
</div>
</div>
</form>
}
@section toolbar {
<div class="toolbar btn-group dropdown">
<button class="btn btn-default dropdown-toggle" data-toggle="dropdown" type="button"><i class="fa fa-gear"></i></button>
<button class="btn dropdown-toggle" data-toggle="dropdown" type="button"><i class="fa fa-gear"></i></button>
<div class="dropdown-menu">
@Html.Partial("_ButtonBarGroup")
@await Html.PartialAsync("_ButtonBarGroup")
</div>
</div>
}
@section modal {
<div class="modal-header">
<h5 class="modal-title" id="myModalLabel">字典编辑窗口</h5>
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
<h4 class="modal-title" id="myModalLabel">字典编辑窗口</h4>
</div>
<div class="modal-body">
<form class="form-horizontal" id="dataForm" name="dataForm" role="form">
<input type="text" class="form-control hidden" id="dictID" name="dictID" />
<div class="form-group">
<label class="control-label col-sm-2" for="dictCate">字典标签</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="dictCate" name="dictCate" placeholder="不可为空50字以内" maxlength="50" />
</div>
<form class="form-inline">
<input type="text" class="form-control d-none" id="dictID" data-default-val="0" />
<div class="form-group col-12">
<label class="control-label" for="dictCate">字典标签</label>
<input type="text" class="form-control form-control-url" id="dictCate" placeholder="不可为空50字以内" maxlength="50" data-valid="true" />
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="dictName">字典名称</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="dictName" name="dictName" placeholder="不可为空50字以内" maxlength="50" />
</div>
<div class="form-group col-12">
<label class="control-label" for="dictName">字典名称</label>
<input type="text" class="form-control form-control-url" id="dictName" placeholder="不可为空50字以内" maxlength="50" data-valid="true" />
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="dictCode">字典代码</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="dictCode" name="dictCode" placeholder="不可为空50字以内" maxlength="50" />
</div>
<div class="form-group col-12">
<label class="control-label" for="dictCode">字典代码</label>
<input type="text" class="form-control form-control-url" id="dictCode" placeholder="不可为空50字以内" maxlength="50" data-valid="true" />
</div>
<div class="form-group">
<label class="control-label col-sm-2" for="dictDefine">字典类型</label>
<div class="dropdown lgbDropdown dropup col-sm-10">
<a id="dictDefine" class="btn btn-success" data-toggle="dropdown" data-default-val="1">
<span>全部</span><span class="caret"></span>
</a>
<ul class="dropdown-menu" role="menu">
<li><a href="#" data-val="0">系统使用</a></li>
<li><a href="#" data-val="1">自定义</a></li>
</ul>
<div class="form-group col-12">
<label class="control-label" for="dictDefine">字典类型</label>
<div class="dropdown">
<button id="dictDefine" class="btn btn-success dropdown-select dropdown-toggle" data-toggle="dropdown" data-default-val="1">全部</button>
<div class="dropdown-menu">
<a href="#" data-val="0">系统使用</a>
<a href="#" data-val="1">自定义</a>
</div>
</div>
</div>
</form>

View File

@ -1,82 +1,90 @@
@model NavigatorBarModel
@model Bootstrap.Admin.Models.NavigatorBarModel
@{
ViewBag.Title = "程序异常";
Layout = "~/Views/Shared/_Admin.cshtml";
}
@section css {
<link href="~/Content/bootstrap-table.css" rel="stylesheet" />
<link href="~/Content/bootstrap-datetimepicker.css" rel="stylesheet" />
<link href="~/Content/fa.css" rel="stylesheet" />
<link href="~/css/bootstrap-table.css" rel="stylesheet" />
<link href="~/css/bootstrap-datetimepicker.css" rel="stylesheet" />
<link href="~/css/fa.css" rel="stylesheet" />
}
@section Javascript {
<script src="~/Scripts/bootstrap-table.js"></script>
<script src="~/Scripts/bootstrap-table-zh-CN.js"></script>
<script src="~/Scripts/longbow.dataentity.js"></script>
<script src="~/Scripts/bootstrap-datetimepicker.js"></script>
<script src="~/Scripts/bootstrap-datetimepicker.zh-CN.js"></script>
<script src="~/scripts/Exceptions.js"></script>
<script src="~/js/bootstrap-table.js"></script>
<script src="~/js/bootstrap-table-zh-CN.js"></script>
<script src="~/js/longbow.dataentity.js"></script>
<script src="~/js/bootstrap-datetimepicker.js"></script>
<script src="~/js/bootstrap-datetimepicker.zh-CN.js"></script>
<script src="~/js/Exceptions.js"></script>
}
<div class="panel panel-default">
<div class="panel-heading">查询条件</div>
<div class="panel-body">
<form class="form-inline" role="form">
<div class="row">
<div class="form-group col-lg-5">
<div class="card">
<div class="card-header">查询条件</div>
<div class="card-body">
<form class="form-inline">
<div class="form-row">
<div class="form-group col-sm-6 col-lg-5">
<label class="control-label" for="txt_operate_start">起始时间</label>
<div class="input-group date form_date">
<input id="txt_operate_start" class="form-control" size="16" type="text" value="" readonly>
<span class="input-group-addon"><span class="glyphicon glyphicon-remove"></span></span>
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-times"></span></div>
</div>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-calendar"></span></div>
</div>
</div>
</div>
<div class="form-group col-lg-5">
<div class="form-group col-sm-6 col-lg-5">
<label class="control-label" for="txt_operate_end">终止时间</label>
<div class="input-group date form_date">
<input id="txt_operate_end" class="form-control" size="16" type="text" value="" readonly>
<span class="input-group-addon"><span class="glyphicon glyphicon-remove"></span></span>
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-times"></span></div>
</div>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-calendar"></span></div>
</div>
</div>
</div>
<div class="form-group col-lg-2">
<label class="sr-only"></label>
<button type="button" id="btn_query" class="btn btn-primary form-control"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
<button type="button" id="btn_query" class="btn btn-primary btn-fill"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
</div>
</div>
</form>
</div>
</div>
<div id="toolbar" class="btn-group hidden">
<div id="toolbar" class="btn-group d-none">
<button id="btn_view" type="button" class="btn btn-danger">
<i class="fa fa-file-text-o" aria-hidden="true"></i><span class="hidden-tb">服务器日志</span>
<i class="fa fa-file-text-o" aria-hidden="true"></i><span>服务器日志</span>
</button>
<div class="toolbar btn-group dropdown">
<button class="btn btn-default dropdown-toggle" data-toggle="dropdown" type="button"><i class="fa fa-gear"></i></button>
<button class="btn dropdown-toggle" data-toggle="dropdown" type="button"><i class="fa fa-gear"></i></button>
<div class="dropdown-menu">
<a id="tb_view" href="#" title="查看明细"><i class="fa fa-file-text-o"></i></a>
</div>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<div class="card">
<div class="card-header">
查询结果
</div>
<div class="panel-body barTable">
<div class="card-body">
<table></table>
</div>
</div>
@section modal {
<div class="modal fade" id="dialogNew" tabindex="-1" role="dialog" data-backdrop="static" aria-labelledby="myModalLabel" aria-hidden="true">
<div id="errorList" class="modal-dialog">
<div id="errorList" class="modal-dialog modal-dialog-centered modal-lg" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="myModalLabel">程序异常日志窗口</h5>
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
<h4 class="modal-title" id="myModalLabel">程序异常日志窗口</h4>
</div>
<div class="modal-body">
<form class="form-inline" id="dataForm" name="dataForm" role="form"><div class="row"></div></form>
<form class="form-inline" id="dataForm" name="dataForm"><div class="form-row"></div></form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">
<button type="button" class="btn btn-secondary" data-dismiss="modal">
关闭
</button>
</div>
@ -85,20 +93,22 @@
</div>
<div id="errorDetail" class="modal-content icon-content">
<div class="modal-header">
<h5 class="modal-title" id="myDetailModalLabel">程序异常日志窗口</h5>
<button type="button" class="close" aria-hidden="true">&times;</button>
<h4 class="modal-title" id="myDetailModalLabel">程序异常日志窗口</h4>
</div>
<div class="modal-body">
<i id="fa-top" class="fa-target"></i>
<div class="affix" id="myScrollspy">
<div><a href="#fa-top" class="fa fa-arrow-circle-up"></a></div>
<div><a href="#fa-bottom" class="fa fa-arrow-circle-down"></a></div>
<div class="iconview">
<i id="fa-top" class="fa-target"></i>
<div class="affix">
<div><a href="#fa-top" class="fa fa-arrow-circle-up"></a></div>
<div><a href="#fa-bottom" class="fa fa-arrow-circle-down"></a></div>
</div>
<div id="dataFormDetail" class="ex-content"><div class="text-center"><i class="fa fa-spinner fa-pulse fa-3x fa-fw"></i></div></div>
<i id="fa-bottom" class="fa-target"></i>
</div>
<div id="dataFormDetail" class="ex-content"><div class="text-center"><i class="fa fa-spinner fa-pulse fa-3x fa-fw"></i></div></div>
<i id="fa-bottom" class="fa-target"></i>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default">
<button type="button" class="btn btn-secondary">
关闭
</button>
</div>

View File

@ -1,12 +1,12 @@
@model NavigatorBarModel
@model Bootstrap.Admin.Models.NavigatorBarModel
@{
ViewBag.Title = "图标集";
Layout = "~/Views/Shared/_Admin.cshtml";
}
@section css {
<link href="~/Content/fa.css" rel="stylesheet" />
<link href="~/css/fa.css" rel="stylesheet" />
}
@section javascript {
<script src="~/Scripts/icon.js"></script>
<script src="~/js/icon.js"></script>
}
@Html.Partial("IconView")
@await Html.PartialAsync("IconView")

View File

@ -1,66 +1,66 @@
@model NavigatorBarModel
@model Bootstrap.Admin.Models.NavigatorBarModel
@{
ViewBag.Title = "部门管理";
Layout = "~/Views/Shared/_Default.cshtml";
}
@section Javascript {
<script src="~/scripts/Groups.js"></script>
<script src="~/js/Groups.js"></script>
}
@section query {
<form class="form-inline" role="form">
<div class="row">
<div class="form-group col-md-5">
<form class="form-inline">
<div class="form-row">
<div class="form-group col-sm-6 col-md-5">
<label class="control-label" for="txt_search_name">部门名称</label>
<input type="text" class="form-control" id="txt_search_name" />
</div>
<div class="form-group col-md-5">
<div class="form-group col-sm-6 col-md-5">
<label class="control-label" for="txt_group_desc">部门描述</label>
<input type="text" class="form-control" id="txt_group_desc" />
</div>
<div class="form-group col-md-2">
<button type="button" id="btn_query" class="btn btn-primary form-control"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
<div class="form-group col-sm-12 col-md-2">
<button type="button" id="btn_query" class="btn btn-primary btn-fill"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
</div>
</div>
</form>
}
@section toolbar {
<button id="btn_assignRole" type="button" class="btn btn-info">
<span class="fa fa-sitemap" aria-hidden="true"></span><span class="hidden-tb">指派角色</span>
</button>
<button id="btn_assignUser" type="button" class="btn btn-info">
<span class="fa fa-user" aria-hidden="true"></span><span class="hidden-tb">指派用户</span>
<span class="fa fa-user" aria-hidden="true"></span><span>分配用户</span>
</button>
<div class="toolbar btn-group dropdown">
<button class="btn btn-default dropdown-toggle" data-toggle="dropdown" type="button"><i class="fa fa-gear"></i></button>
<button id="btn_assignRole" type="button" class="btn btn-warning">
<span class="fa fa-sitemap" aria-hidden="true"></span><span>分配角色</span>
</button>
<div class="toolbar btn-group">
<button class="btn dropdown-toggle" data-toggle="dropdown" type="button"><i class="fa fa-gear"></i></button>
<div class="dropdown-menu">
@Html.Partial("_ButtonBarGroup")
<a id="tb_assignRole" href="#" title="指派角色"><i class="fa fa-sitemap"></i></a>
<a id="tb_assignUser" href="#" title="指派用户"><i class="fa fa-user"></i></a>
@await Html.PartialAsync("_ButtonBarGroup")
<a id="tb_assignRole" href="#" title="分配角色"><i class="fa fa-sitemap"></i></a>
<a id="tb_assignUser" href="#" title="分配用户"><i class="fa fa-user"></i></a>
</div>
</div>
}
@section modal {
<div class="modal-header">
<h5 class="modal-title" id="myModalLabel">部门编辑窗口</h5>
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
<h4 class="modal-title" id="myModalLabel">部门编辑窗口</h4>
</div>
<div class="modal-body">
<form class="form-inline" id="dataForm" name="dataForm" role="form">
<div class="row">
<form class="form-inline">
<div class="form-row">
<div class="form-group col-sm-6">
<label class="control-label" for="groupName">部门名称</label>
<input type="text" class="form-control" id="groupName" name="groupName" placeholder="不可为空50字以内" maxlength="50" />
<input type="text" class="form-control" id="groupName" placeholder="不可为空50字以内" maxlength="50" data-valid="true" />
</div>
<div class="form-group col-sm-6">
<input type="text" class="form-control hidden" id="groupID" name="groupID" />
<input type="text" class="form-control d-none" id="groupID" data-default-val="0" />
<label class="control-label" for="groupDesc">部门描述</label>
<input type="text" class="form-control" id="groupDesc" name="groupDesc" placeholder="描述信息(可为空)50字以内" maxlength="50" />
<input type="text" class="form-control" id="groupDesc" placeholder="描述信息(可为空)50字以内" maxlength="50" />
</div>
</div>
</form>
</div>
}
@section customModal {
@Html.Partial("RoleConfig")
@Html.Partial("UserConfig")
@await Html.PartialAsync("RoleConfig")
@await Html.PartialAsync("UserConfig")
}

View File

@ -1,60 +1,78 @@
@model NavigatorBarModel
@model Bootstrap.Admin.Models.NavigatorBarModel
@{
ViewBag.Title = "系统日志";
Layout = "~/Views/Shared/_Admin.cshtml";
}
@section css {
<link href="~/Content/bootstrap-table.css" rel="stylesheet" />
<link href="~/Content/bootstrap-datetimepicker.css" rel="stylesheet" />
<environment include="Development">
<link href="~/css/bootstrap-table.css" rel="stylesheet" />
<link href="~/css/bootstrap-datetimepicker.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap-table.min.css" rel="stylesheet" />
<link href="~/css/bootstrap-datetimepicker.min.css" rel="stylesheet" />
</environment>
}
@section Javascript {
<script src="~/Scripts/bootstrap-table.js"></script>
<script src="~/Scripts/bootstrap-table-zh-CN.js"></script>
<script src="~/Scripts/longbow.dataentity.js"></script>
<script src="~/Scripts/bootstrap-datetimepicker.js"></script>
<script src="~/Scripts/bootstrap-datetimepicker.zh-CN.js"></script>
<script src="~/scripts/Logs.js"></script>
<environment include="Development">
<script src="~/js/bootstrap-table.js"></script>
<script src="~/js/bootstrap-table-zh-CN.js"></script>
<script src="~/js/bootstrap-datetimepicker.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap-table.min.js"></script>
<script src="~/js/bootstrap-table-zh-CN.min.js"></script>
<script src="~/js/bootstrap-datetimepicker.min.js"></script>
</environment>
<script src="~/js/bootstrap-datetimepicker.zh-CN.js"></script>
<script src="~/js/longbow.dataentity.js"></script>
<script src="~/js/Logs.js"></script>
}
<div class="panel panel-default">
<div class="panel-heading">查询条件</div>
<div class="panel-body">
<form class="form-inline" role="form">
<div class="row">
<div class="form-group col-xs-12">
<div class="card">
<div class="card-header">查询条件</div>
<div class="card-body">
<form class="form-inline">
<div class="form-row">
<div class="form-group col-12">
<label class="control-label" for="txt_operate_type">操作类型</label>
<input type="text" class="form-control" id="txt_operate_type" />
</div>
</div>
<div class="row">
<div class="form-group col-sm-6 col-lg-5">
<label class="control-label" for="txt_operate_start">起始时间</label>
<div class="input-group date form_date">
<input id="txt_operate_start" class="form-control" size="16" type="text" value="" readonly>
<span class="input-group-addon"><span class="glyphicon glyphicon-remove"></span></span>
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-times"></span></div>
</div>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-calendar"></span></div>
</div>
</div>
</div>
<div class="form-group col-sm-6 col-lg-5">
<label class="control-label" for="txt_operate_end">终止时间</label>
<div class="input-group date form_date">
<input id="txt_operate_end" class="form-control" size="16" type="text" value="" readonly>
<span class="input-group-addon"><span class="glyphicon glyphicon-remove"></span></span>
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-times"></span></div>
</div>
<div class="input-group-append input-group-addon">
<div class="input-group-text"><span class="fa fa-calendar"></span></div>
</div>
</div>
</div>
<div class="form-group col-lg-2">
<label class="sr-only"></label>
<button type="button" id="btn_query" class="btn btn-primary form-control"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
<button type="button" id="btn_query" class="btn btn-primary btn-fill"><i class="fa fa-search" aria-hidden="true"></i><span>查询</span></button>
</div>
</div>
</form>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<div class="card">
<div class="card-header">
查询结果
</div>
<div class="panel-body barTable">
<div class="card-body">
<table></table>
</div>
</div>

Some files were not shown because too many files have changed in this diff Show More