Publish:针对云心理发布版本,使用Longbow.Utility 2015组件库,针对Reference
This commit is contained in:
parent
35190af759
commit
2a151d6183
|
@ -1,4 +1,5 @@
|
|||
using Bootstrap.DataAccess;
|
||||
using Longbow.Caching;
|
||||
using Longbow.ExceptionManagement;
|
||||
using Longbow.ExceptionManagement.Configuration;
|
||||
using System;
|
||||
|
@ -21,6 +22,8 @@ namespace Bootstrap.Admin
|
|||
{
|
||||
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 });
|
||||
}
|
||||
}
|
||||
}
|
|
@ -123,6 +123,8 @@
|
|||
<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" />
|
||||
|
@ -196,6 +198,9 @@
|
|||
<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" />
|
||||
|
@ -228,6 +233,7 @@
|
|||
<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" />
|
||||
|
@ -262,6 +268,7 @@
|
|||
<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>
|
||||
|
@ -286,7 +293,6 @@
|
|||
<Content Include="Views\Shared\_Normal.cshtml" />
|
||||
<Content Include="Views\Shared\_Admin.cshtml" />
|
||||
<Content Include="Views\Admin\Index.cshtml" />
|
||||
<Content Include="Longbow.Utility.snk" />
|
||||
<Content Include="Views\Shared\_Default.cshtml" />
|
||||
<Content Include="Views\Admin\Users.cshtml" />
|
||||
<Content Include="Views\_ViewStart.cshtml" />
|
||||
|
@ -307,7 +313,6 @@
|
|||
<Content Include="Views\Admin\Logs.cshtml" />
|
||||
<Content Include="Views\Admin\Settings.cshtml" />
|
||||
<Content Include="Views\Shared\Footer.cshtml" />
|
||||
<Content Include="Views\Shared\MenuTree.cshtml" />
|
||||
<Content Include="Views\Shared\NavigatorConfig.cshtml" />
|
||||
<Content Include="Views\Shared\SubNavigation.cshtml" />
|
||||
<Content Include="Views\Home\Lock.cshtml" />
|
||||
|
@ -323,6 +328,7 @@
|
|||
<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>
|
||||
|
@ -345,7 +351,7 @@
|
|||
<SignAssembly>true</SignAssembly>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<AssemblyOriginatorKeyFile>Longbow.Utility.snk</AssemblyOriginatorKeyFile>
|
||||
<AssemblyOriginatorKeyFile>..\..\Keys\Longbow.Utility.snk</AssemblyOriginatorKeyFile>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<DelaySign>true</DelaySign>
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
@media (min-width: 768px) {
|
||||
.sidebar {
|
||||
top: 94px;
|
||||
top: 98px;
|
||||
bottom: 40px;
|
||||
position: absolute;
|
||||
overflow: auto;
|
||||
|
@ -73,9 +73,39 @@
|
|||
}
|
||||
}
|
||||
|
||||
@media (min-height: 414px) {
|
||||
.modal .modal-body {
|
||||
max-height: 200px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 568px) {
|
||||
.modal .modal-body {
|
||||
max-height: 350px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 667px) {
|
||||
.modal .modal-body {
|
||||
max-height: 450px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 736px) {
|
||||
.modal .modal-body {
|
||||
max-height: 510px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 768px) {
|
||||
.modal .modal-body {
|
||||
max-height: 540px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 672px) {
|
||||
.sidebar {
|
||||
top: 94px;
|
||||
top: 98px;
|
||||
bottom: 40px;
|
||||
position: absolute;
|
||||
overflow: auto;
|
||||
|
|
|
@ -2,17 +2,9 @@
|
|||
display: inline-block;
|
||||
}
|
||||
|
||||
.logfile {
|
||||
color: #d41404;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.logfile:focus, .logfile:active, .logfile:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
.logfile span {
|
||||
margin-left: 4px;
|
||||
.lgbDropdown .dropdown-menu > li > a:hover {
|
||||
background: #007AC0;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.logTs, .logSql, .logDbExcep {
|
||||
|
@ -51,7 +43,6 @@
|
|||
color: #ac2925;
|
||||
}
|
||||
|
||||
|
||||
.form-inline .form-group {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
@ -65,6 +56,7 @@
|
|||
vertical-align: middle;
|
||||
}
|
||||
|
||||
|
||||
.modal-dialog .modal-body, .panel-body {
|
||||
padding-bottom: 0;
|
||||
}
|
||||
|
@ -85,6 +77,12 @@
|
|||
padding: 0 15px;
|
||||
}
|
||||
|
||||
.modal .modal-body {
|
||||
max-height: 164px;
|
||||
overflow: auto;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
|
||||
.modal.file-zoom-dialog .modal-dialog {
|
||||
max-width: none;
|
||||
}
|
||||
|
@ -100,7 +98,7 @@
|
|||
margin-top: 1px;
|
||||
}
|
||||
|
||||
.modal-body .checkbox {
|
||||
.modal-body .checkbox, .modal-body .radio {
|
||||
min-width: 190px;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
|
@ -144,7 +142,7 @@
|
|||
left: 0;
|
||||
bottom: 40px;
|
||||
right: 0;
|
||||
top: 94px;
|
||||
top: 98px;
|
||||
}
|
||||
|
||||
.main-content.open {
|
||||
|
@ -168,7 +166,7 @@ aside {
|
|||
transform: translate(-100%);
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
top: 94px;
|
||||
top: 98px;
|
||||
bottom: 40px;
|
||||
left: 0;
|
||||
right: 0;
|
||||
|
@ -257,16 +255,16 @@ aside {
|
|||
}
|
||||
|
||||
/*Modal Dialog Checkbox*/
|
||||
.modal-body .checkbox {
|
||||
.modal-body .checkbox, .modal-dialog .radio {
|
||||
padding: 0;
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
.modal-body .checkbox label {
|
||||
.modal-body .checkbox label, .modal-body .radio label {
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
.modal-body .checkbox label input[type='checkbox'] {
|
||||
.modal-body .checkbox label input[type='checkbox'], .modal-body .radio label input[type='radio'] {
|
||||
margin: 0 4px 0 0;
|
||||
vertical-align: middle;
|
||||
position: relative;
|
||||
|
@ -302,7 +300,7 @@ aside {
|
|||
|
||||
.toolbar .dropdown-menu a {
|
||||
border-left: none;
|
||||
padding: 0 8px;
|
||||
padding: 0 14px;
|
||||
display: table-cell;
|
||||
color: #504d4d;
|
||||
}
|
||||
|
@ -488,3 +486,7 @@ input[type="datetime"] {
|
|||
.input-group.form_date span {
|
||||
border-left: none;
|
||||
}
|
||||
|
||||
.barTable {
|
||||
padding: 5px 15px 15px 15px;
|
||||
}
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
}
|
||||
|
||||
.fa-target {
|
||||
height: 16px;
|
||||
display: block;
|
||||
}
|
||||
|
||||
|
@ -85,14 +84,12 @@
|
|||
}
|
||||
|
||||
.icon-content .modal-body {
|
||||
position: fixed;
|
||||
left: 18px;
|
||||
right: 16px;
|
||||
top: 62px;
|
||||
bottom: 80px;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
top: 46px;
|
||||
bottom: 65px;
|
||||
overflow: auto;
|
||||
max-height: inherit;
|
||||
height: inherit;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
|
||||
|
@ -106,10 +103,10 @@
|
|||
}
|
||||
|
||||
.icon-content .modal-footer {
|
||||
position: fixed;
|
||||
left: 16px;
|
||||
right: 16px;
|
||||
bottom: 15px;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
|
@ -131,6 +128,27 @@
|
|||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.icon-content .modal-footer span {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.icon-content .dd {
|
||||
max-width: 100%;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.modal .modal-dialog .icon-content {
|
||||
position: static;
|
||||
}
|
||||
|
||||
.modal .modal-dialog .icon-content .modal-body {
|
||||
position: static;
|
||||
}
|
||||
|
||||
.modal .modal-dialog .icon-content .modal-footer {
|
||||
position: static;
|
||||
}
|
||||
|
||||
.fontawesome-icon-list .fa-hover a {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
|
@ -200,23 +218,33 @@
|
|||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.menu-content {
|
||||
display: none;
|
||||
z-index: 1051;
|
||||
.logitem {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.menu-content .modal-body {
|
||||
overflow-y: auto;
|
||||
max-height: 180px;
|
||||
padding-bottom: 15px;
|
||||
.logfile {
|
||||
color: #d41404;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.logfile:focus, .logfile:active, .logfile:hover {
|
||||
color: red;
|
||||
}
|
||||
|
||||
.menu-content .dd {
|
||||
max-width: inherit;
|
||||
.logfile span {
|
||||
margin-left: 4px;
|
||||
}
|
||||
|
||||
.icon-content .modal-footer span {
|
||||
display: none;
|
||||
.modal-header > h4 {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
margin-right: 20px;
|
||||
}
|
||||
|
||||
.ex-content {
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
@media (min-width: 375px) {
|
||||
|
@ -239,39 +267,3 @@
|
|||
margin-right: 160px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 375px) {
|
||||
.menu-content .modal-body {
|
||||
max-height: 240px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 414px) {
|
||||
.menu-content .modal-body {
|
||||
max-height: 280px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 568px) {
|
||||
.menu-content .modal-body {
|
||||
max-height: 430px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 667px) {
|
||||
.menu-content .modal-body {
|
||||
max-height: 530px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 736px) {
|
||||
.menu-content .modal-body {
|
||||
max-height: 600px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-height: 768px) {
|
||||
.menu-content .modal-body {
|
||||
max-height: 630px;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -7,11 +7,11 @@
|
|||
<title>注册成功</title>
|
||||
<link rel="shortcut icon" href="../../favicon.ico" />
|
||||
<!-- 新 Bootstrap 核心 CSS 文件 -->
|
||||
<link href="../css/bootstrap.css" rel="stylesheet">
|
||||
<link href="../css/bootstrap-theme.css" rel="stylesheet">
|
||||
<link href="../bootstrap.css" rel="stylesheet">
|
||||
<link href="../bootstrap-theme.css" rel="stylesheet">
|
||||
<style type="text/css">
|
||||
body {
|
||||
background: #02bac6 url("images/lock-bg.jpg");
|
||||
background: #02bac6 url("../images/lock-bg.jpg");
|
||||
background-size: cover;
|
||||
background-repeat: repeat;
|
||||
}
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 45 KiB After Width: | Height: | Size: 38 KiB |
|
@ -7,7 +7,6 @@
|
|||
display: block;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
max-width: 600px;
|
||||
list-style: none;
|
||||
font-size: 13px;
|
||||
line-height: 20px;
|
||||
|
@ -176,6 +175,8 @@
|
|||
.dd3-content label span i {
|
||||
width: 22px;
|
||||
display: inline-block;
|
||||
text-align: center;
|
||||
margin-right: 4px;
|
||||
}
|
||||
|
||||
.dd3-content label input {
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
background: rgba(0, 0, 0, 0.57);
|
||||
border-radius: 5px 5px 0 0;
|
||||
color: #fff;
|
||||
font-size: 34px;
|
||||
font-size: 32px;
|
||||
text-transform: uppercase;
|
||||
font-weight: 300;
|
||||
}
|
||||
|
|
|
@ -4,13 +4,13 @@
|
|||
}
|
||||
|
||||
#nprogress .bar {
|
||||
background: #29d;
|
||||
background: #673AB7;
|
||||
position: fixed;
|
||||
z-index: 1031;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 2px;
|
||||
height: 4px;
|
||||
}
|
||||
|
||||
/* Fancy blur effect */
|
||||
|
@ -32,7 +32,7 @@
|
|||
display: block;
|
||||
position: fixed;
|
||||
z-index: 1031;
|
||||
top: 19px;
|
||||
top: 22px;
|
||||
right: 17px;
|
||||
}
|
||||
|
||||
|
|
|
@ -16,8 +16,13 @@
|
|||
overflow: hidden;
|
||||
}
|
||||
|
||||
.header {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.header, .site-footer {
|
||||
position: fixed;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.main-content {
|
||||
|
@ -38,5 +43,6 @@
|
|||
|
||||
.header, .site-footer {
|
||||
position: fixed;
|
||||
z-index: 10;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,23 +23,37 @@ a, a:hover, a:focus {
|
|||
|
||||
.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: 94px;
|
||||
height: 98px;
|
||||
background: #fff;
|
||||
border-bottom: 1px solid #f1f2f7;
|
||||
border-bottom: 1px solid #ddd;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
z-index: 50;
|
||||
}
|
||||
|
||||
.header .bg {
|
||||
background-color: #337ab7;
|
||||
height: 4px;
|
||||
margin: 0 -15px;
|
||||
}
|
||||
|
||||
.header a {
|
||||
transition: all .25s linear;
|
||||
}
|
||||
|
@ -49,7 +63,6 @@ a, a:hover, a:focus {
|
|||
float: right;
|
||||
}
|
||||
|
||||
|
||||
.header > .dropdown > a {
|
||||
border: 1px solid #eee;
|
||||
border-radius: 4px;
|
||||
|
@ -81,7 +94,6 @@ a, a:hover, a:focus {
|
|||
top: 50px;
|
||||
left: auto;
|
||||
right: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.header > .dropdown .dropdown-menu li {
|
||||
|
@ -163,7 +175,6 @@ a, a:hover, a:focus {
|
|||
bottom: 0;
|
||||
right: 0;
|
||||
white-space: nowrap;
|
||||
z-index: 5;
|
||||
}
|
||||
|
||||
.go-top {
|
||||
|
@ -239,7 +250,6 @@ a, a:hover, a:focus {
|
|||
top: 32px;
|
||||
left: -74px;
|
||||
width: 235px;
|
||||
padding: 0;
|
||||
border: none;
|
||||
}
|
||||
|
||||
|
@ -401,12 +411,11 @@ a, a:hover, a:focus {
|
|||
|
||||
.breadcrumb {
|
||||
position: absolute;
|
||||
top: 56px;
|
||||
top: 60px;
|
||||
left: 15px;
|
||||
right: 15px;
|
||||
border-color: #ddd;
|
||||
border: solid 1px #ddd;
|
||||
border-width: 1px 0 0 0;
|
||||
border-style: solid;
|
||||
background-color: transparent;
|
||||
border-top-left-radius: 0;
|
||||
border-top-right-radius: 0;
|
||||
|
@ -429,7 +438,7 @@ a, a:hover, a:focus {
|
|||
left: 0;
|
||||
bottom: 40px;
|
||||
right: 0;
|
||||
top: 94px;
|
||||
top: 98px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
|
|
|
@ -53,9 +53,9 @@
|
|||
.tasks-widget .task-list li > .task-title .task-value {
|
||||
position: absolute;
|
||||
left: 190px;
|
||||
right: 62px;
|
||||
right: 84px;
|
||||
top: 15px;
|
||||
display: inline-block;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.tasks-widget .task-list li > .task-title span {
|
||||
|
@ -121,7 +121,7 @@
|
|||
|
||||
.tasks-widget .task-list li .task-title .task-title-sp {
|
||||
margin-right: 5px;
|
||||
max-width: 150px;
|
||||
max-width: 120px;
|
||||
padding-top: 15px;
|
||||
}
|
||||
|
||||
|
@ -255,14 +255,8 @@
|
|||
}
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 320px) {
|
||||
|
||||
.tasks-widget .task-config-btn {
|
||||
float: inherit;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.tasks-widget .task-list-projects li > .label {
|
||||
margin-bottom: 5px;
|
||||
@media (min-width: 375px) {
|
||||
.tasks-widget .task-list li > .task-title .task-value {
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,228 @@
|
|||
.toast-title {
|
||||
font-weight: bold;
|
||||
}
|
||||
.toast-message {
|
||||
-ms-word-wrap: break-word;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
.toast-message a,
|
||||
.toast-message label {
|
||||
color: #FFFFFF;
|
||||
}
|
||||
.toast-message a:hover {
|
||||
color: #CCCCCC;
|
||||
text-decoration: none;
|
||||
}
|
||||
.toast-close-button {
|
||||
position: relative;
|
||||
right: -0.3em;
|
||||
top: -0.3em;
|
||||
float: right;
|
||||
font-size: 20px;
|
||||
font-weight: bold;
|
||||
color: #FFFFFF;
|
||||
-webkit-text-shadow: 0 1px 0 #ffffff;
|
||||
text-shadow: 0 1px 0 #ffffff;
|
||||
opacity: 0.8;
|
||||
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=80);
|
||||
filter: alpha(opacity=80);
|
||||
line-height: 1;
|
||||
}
|
||||
.toast-close-button:hover,
|
||||
.toast-close-button:focus {
|
||||
color: #000000;
|
||||
text-decoration: none;
|
||||
cursor: pointer;
|
||||
opacity: 0.4;
|
||||
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=40);
|
||||
filter: alpha(opacity=40);
|
||||
}
|
||||
.rtl .toast-close-button {
|
||||
left: -0.3em;
|
||||
float: left;
|
||||
right: 0.3em;
|
||||
}
|
||||
/*Additional properties for button version
|
||||
iOS requires the button element instead of an anchor tag.
|
||||
If you want the anchor version, it requires `href="#"`.*/
|
||||
button.toast-close-button {
|
||||
padding: 0;
|
||||
cursor: pointer;
|
||||
background: transparent;
|
||||
border: 0;
|
||||
-webkit-appearance: none;
|
||||
}
|
||||
.toast-top-center {
|
||||
top: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
}
|
||||
.toast-bottom-center {
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
}
|
||||
.toast-top-full-width {
|
||||
top: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
}
|
||||
.toast-bottom-full-width {
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
}
|
||||
.toast-top-left {
|
||||
top: 12px;
|
||||
left: 12px;
|
||||
}
|
||||
.toast-top-right {
|
||||
top: 12px;
|
||||
right: 12px;
|
||||
}
|
||||
.toast-bottom-right {
|
||||
right: 12px;
|
||||
bottom: 12px;
|
||||
}
|
||||
.toast-bottom-left {
|
||||
bottom: 12px;
|
||||
left: 12px;
|
||||
}
|
||||
#toast-container {
|
||||
position: fixed;
|
||||
z-index: 999999;
|
||||
pointer-events: none;
|
||||
/*overrides*/
|
||||
}
|
||||
#toast-container * {
|
||||
-moz-box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
#toast-container > div {
|
||||
position: relative;
|
||||
pointer-events: auto;
|
||||
overflow: hidden;
|
||||
margin: 0 0 6px;
|
||||
padding: 15px 15px 15px 50px;
|
||||
width: 300px;
|
||||
-moz-border-radius: 3px 3px 3px 3px;
|
||||
-webkit-border-radius: 3px 3px 3px 3px;
|
||||
border-radius: 3px 3px 3px 3px;
|
||||
background-position: 15px center;
|
||||
background-repeat: no-repeat;
|
||||
-moz-box-shadow: 0 0 12px #999999;
|
||||
-webkit-box-shadow: 0 0 12px #999999;
|
||||
box-shadow: 0 0 12px #999999;
|
||||
color: #FFFFFF;
|
||||
opacity: 0.8;
|
||||
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=80);
|
||||
filter: alpha(opacity=80);
|
||||
}
|
||||
#toast-container > div.rtl {
|
||||
direction: rtl;
|
||||
padding: 15px 50px 15px 15px;
|
||||
background-position: right 15px center;
|
||||
}
|
||||
#toast-container > div:hover {
|
||||
-moz-box-shadow: 0 0 12px #000000;
|
||||
-webkit-box-shadow: 0 0 12px #000000;
|
||||
box-shadow: 0 0 12px #000000;
|
||||
opacity: 1;
|
||||
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=100);
|
||||
filter: alpha(opacity=100);
|
||||
cursor: pointer;
|
||||
}
|
||||
#toast-container > .toast-info {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=") !important;
|
||||
}
|
||||
#toast-container > .toast-error {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHOSURBVEhLrZa/SgNBEMZzh0WKCClSCKaIYOED+AAKeQQLG8HWztLCImBrYadgIdY+gIKNYkBFSwu7CAoqCgkkoGBI/E28PdbLZmeDLgzZzcx83/zZ2SSXC1j9fr+I1Hq93g2yxH4iwM1vkoBWAdxCmpzTxfkN2RcyZNaHFIkSo10+8kgxkXIURV5HGxTmFuc75B2RfQkpxHG8aAgaAFa0tAHqYFfQ7Iwe2yhODk8+J4C7yAoRTWI3w/4klGRgR4lO7Rpn9+gvMyWp+uxFh8+H+ARlgN1nJuJuQAYvNkEnwGFck18Er4q3egEc/oO+mhLdKgRyhdNFiacC0rlOCbhNVz4H9FnAYgDBvU3QIioZlJFLJtsoHYRDfiZoUyIxqCtRpVlANq0EU4dApjrtgezPFad5S19Wgjkc0hNVnuF4HjVA6C7QrSIbylB+oZe3aHgBsqlNqKYH48jXyJKMuAbiyVJ8KzaB3eRc0pg9VwQ4niFryI68qiOi3AbjwdsfnAtk0bCjTLJKr6mrD9g8iq/S/B81hguOMlQTnVyG40wAcjnmgsCNESDrjme7wfftP4P7SP4N3CJZdvzoNyGq2c/HWOXJGsvVg+RA/k2MC/wN6I2YA2Pt8GkAAAAASUVORK5CYII=") !important;
|
||||
}
|
||||
#toast-container > .toast-success {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAADsSURBVEhLY2AYBfQMgf///3P8+/evAIgvA/FsIF+BavYDDWMBGroaSMMBiE8VC7AZDrIFaMFnii3AZTjUgsUUWUDA8OdAH6iQbQEhw4HyGsPEcKBXBIC4ARhex4G4BsjmweU1soIFaGg/WtoFZRIZdEvIMhxkCCjXIVsATV6gFGACs4Rsw0EGgIIH3QJYJgHSARQZDrWAB+jawzgs+Q2UO49D7jnRSRGoEFRILcdmEMWGI0cm0JJ2QpYA1RDvcmzJEWhABhD/pqrL0S0CWuABKgnRki9lLseS7g2AlqwHWQSKH4oKLrILpRGhEQCw2LiRUIa4lwAAAABJRU5ErkJggg==") !important;
|
||||
}
|
||||
#toast-container > .toast-warning {
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGYSURBVEhL5ZSvTsNQFMbXZGICMYGYmJhAQIJAICYQPAACiSDB8AiICQQJT4CqQEwgJvYASAQCiZiYmJhAIBATCARJy+9rTsldd8sKu1M0+dLb057v6/lbq/2rK0mS/TRNj9cWNAKPYIJII7gIxCcQ51cvqID+GIEX8ASG4B1bK5gIZFeQfoJdEXOfgX4QAQg7kH2A65yQ87lyxb27sggkAzAuFhbbg1K2kgCkB1bVwyIR9m2L7PRPIhDUIXgGtyKw575yz3lTNs6X4JXnjV+LKM/m3MydnTbtOKIjtz6VhCBq4vSm3ncdrD2lk0VgUXSVKjVDJXJzijW1RQdsU7F77He8u68koNZTz8Oz5yGa6J3H3lZ0xYgXBK2QymlWWA+RWnYhskLBv2vmE+hBMCtbA7KX5drWyRT/2JsqZ2IvfB9Y4bWDNMFbJRFmC9E74SoS0CqulwjkC0+5bpcV1CZ8NMej4pjy0U+doDQsGyo1hzVJttIjhQ7GnBtRFN1UarUlH8F3xict+HY07rEzoUGPlWcjRFRr4/gChZgc3ZL2d8oAAAAASUVORK5CYII=") !important;
|
||||
}
|
||||
#toast-container.toast-top-center > div,
|
||||
#toast-container.toast-bottom-center > div {
|
||||
width: 300px;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
#toast-container.toast-top-full-width > div,
|
||||
#toast-container.toast-bottom-full-width > div {
|
||||
width: 96%;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
.toast {
|
||||
background-color: #030303;
|
||||
}
|
||||
.toast-success {
|
||||
background-color: #51A351;
|
||||
}
|
||||
.toast-error {
|
||||
background-color: #BD362F;
|
||||
}
|
||||
.toast-info {
|
||||
background-color: #2F96B4;
|
||||
}
|
||||
.toast-warning {
|
||||
background-color: #F89406;
|
||||
}
|
||||
.toast-progress {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
height: 4px;
|
||||
background-color: #000000;
|
||||
opacity: 0.4;
|
||||
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=40);
|
||||
filter: alpha(opacity=40);
|
||||
}
|
||||
/*Responsive Design*/
|
||||
@media all and (max-width: 240px) {
|
||||
#toast-container > div {
|
||||
padding: 8px 8px 8px 50px;
|
||||
width: 11em;
|
||||
}
|
||||
#toast-container > div.rtl {
|
||||
padding: 8px 50px 8px 8px;
|
||||
}
|
||||
#toast-container .toast-close-button {
|
||||
right: -0.2em;
|
||||
top: -0.2em;
|
||||
}
|
||||
#toast-container .rtl .toast-close-button {
|
||||
left: -0.2em;
|
||||
right: 0.2em;
|
||||
}
|
||||
}
|
||||
@media all and (min-width: 241px) and (max-width: 480px) {
|
||||
#toast-container > div {
|
||||
padding: 8px 8px 8px 50px;
|
||||
width: 18em;
|
||||
}
|
||||
#toast-container > div.rtl {
|
||||
padding: 8px 50px 8px 8px;
|
||||
}
|
||||
#toast-container .toast-close-button {
|
||||
right: -0.2em;
|
||||
top: -0.2em;
|
||||
}
|
||||
#toast-container .rtl .toast-close-button {
|
||||
left: -0.2em;
|
||||
right: 0.2em;
|
||||
}
|
||||
}
|
||||
@media all and (min-width: 481px) and (max-width: 768px) {
|
||||
#toast-container > div {
|
||||
padding: 15px 15px 15px 50px;
|
||||
width: 25em;
|
||||
}
|
||||
#toast-container > div.rtl {
|
||||
padding: 15px 50px 15px 15px;
|
||||
}
|
||||
}
|
File diff suppressed because one or more lines are too long
|
@ -77,6 +77,7 @@ namespace Bootstrap.Admin.Controllers
|
|||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[OutputCache(CacheProfile = "IconView")]
|
||||
[AllowAnonymous]
|
||||
public PartialViewResult IconView()
|
||||
{
|
||||
Response.Cache.SetOmitVaryStar(true);
|
||||
|
|
|
@ -32,10 +32,14 @@ namespace Bootstrap.Admin.Controllers
|
|||
[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;
|
||||
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))
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
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();
|
||||
}
|
||||
}
|
||||
}
|
Binary file not shown.
|
@ -15,6 +15,7 @@ namespace Bootstrap.Admin.Models
|
|||
Icon = user.Icon;
|
||||
DisplayName = user.DisplayName;
|
||||
UserName = user.UserName;
|
||||
Css = user.Css;
|
||||
}
|
||||
public string UserName { get; private set; }
|
||||
/// <summary>
|
||||
|
@ -29,5 +30,9 @@ namespace Bootstrap.Admin.Models
|
|||
/// 获得/设置 用户头像地址
|
||||
/// </summary>
|
||||
public string Icon { get; private set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Css { get; private set; }
|
||||
}
|
||||
}
|
|
@ -1,8 +1,6 @@
|
|||
using Bootstrap.DataAccess;
|
||||
using Bootstrap.Security;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace Bootstrap.Admin.Models
|
||||
{
|
||||
|
@ -10,21 +8,10 @@ namespace Bootstrap.Admin.Models
|
|||
{
|
||||
public NavigatorBarModel(string url)
|
||||
{
|
||||
Navigations = BootstrapMenu.RetrieveSystemMenus(UserName);
|
||||
Navigations = BootstrapMenu.RetrieveSystemMenus(UserName, url);
|
||||
Applications = DictHelper.RetrieveApps();
|
||||
ActiveMenu(null, Navigations.ToList(), url);
|
||||
HomeUrl = "~/Admin/Index";
|
||||
}
|
||||
|
||||
private void ActiveMenu(BootstrapMenu parent, List<BootstrapMenu> menus, string url)
|
||||
{
|
||||
menus.ForEach(m =>
|
||||
{
|
||||
m.Active = m.Url.Equals(url, StringComparison.OrdinalIgnoreCase) ? "active" : "";
|
||||
ActiveMenu(m, m.Menus.ToList(), url);
|
||||
if (parent != null && m.Active != "") parent.Active = m.Active;
|
||||
});
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
using System.IO;
|
||||
using Bootstrap.DataAccess;
|
||||
using Bootstrap.Security;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Web;
|
||||
|
||||
namespace Bootstrap.Admin.Models
|
||||
|
@ -13,16 +16,23 @@ namespace Bootstrap.Admin.Models
|
|||
/// </summary>
|
||||
public long Size { get; private set; }
|
||||
/// <summary>
|
||||
/// 获得 系统配置的所有样式表
|
||||
/// </summary>
|
||||
public IEnumerable<BootstrapDict> Csss { get; private set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="url"></param>
|
||||
public ProfilesModel(string url) : base(url)
|
||||
public ProfilesModel(string url)
|
||||
: base(url)
|
||||
{
|
||||
var fileName = HttpContext.Current.Server.MapPath(Icon);
|
||||
if (File.Exists(fileName))
|
||||
{
|
||||
Size = new FileInfo(fileName).Length;
|
||||
}
|
||||
|
||||
Csss = DictHelper.RetrieveWebCss();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -19,7 +19,7 @@
|
|||
queryParams: function (params) { return $.extend(params, { category: $('#txt_dict_cate').val(), name: $("#txt_dict_name").val(), define: $("#txt_dict_define").val() }); },
|
||||
columns: [
|
||||
{ checkbox: true },
|
||||
{ title: "Id", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "编辑", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "字典标签", field: "Category", sortable: true },
|
||||
{ title: "字典名称", field: "Name", sortable: true },
|
||||
{ title: "字典代码", field: "Code", sortable: true },
|
||||
|
|
|
@ -42,12 +42,12 @@
|
|||
Id: "", url: Exceptions.url, swal: false,
|
||||
callback: function (result) {
|
||||
var html = result.map(function (ele) {
|
||||
return $.format('<div class="form-group col-lg-3 col-md-3 col-sm-4 col-xs-6"><a class="logfile" href="#"><i class="fa fa-file-text-o"></i><span>{0}</span></a></div>', ele);
|
||||
return $.format('<div class="form-group col-lg-3 col-md-3 col-sm-4 col-xs-6 logitem"><a class="logfile" title="{0}" href="#"><i class="fa fa-file-text-o"></i><span>{0}</span></a></div>', ele);
|
||||
}).join('');
|
||||
$dataForm.children('div').html(html);
|
||||
$dialog.modal('show');
|
||||
}
|
||||
});
|
||||
$dialog.modal('show');
|
||||
});
|
||||
|
||||
$dialog.on('click', 'a', function () {
|
||||
|
|
|
@ -79,7 +79,7 @@
|
|||
sortName: 'GroupName',
|
||||
queryParams: function (params) { return $.extend(params, { groupName: $("#txt_search_name").val(), description: $("#txt_group_desc").val() }); }, //传递参数(*)
|
||||
columns: [{ checkbox: true },
|
||||
{ title: "Id", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "编辑", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "部门名称", field: "GroupName", sortable: true },
|
||||
{ title: "部门描述", field: "Description", sortable: false }
|
||||
]
|
||||
|
|
|
@ -140,7 +140,7 @@
|
|||
success(result);
|
||||
},
|
||||
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
||||
if ($.isFunction(data.callback)) data.callback(false);
|
||||
if (XMLHttpRequest.responseJSON) lgbSwal({ title: errorThrown, text: XMLHttpRequest.responseJSON.Message, type: 'error' });
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -159,7 +159,7 @@
|
|||
},
|
||||
lgbSwal: function (options) {
|
||||
if ($.isFunction(swal)) {
|
||||
swal($.extend({ showConfirmButton: false, showCancelButton: false, timer: 800, title: '未设置', type: "success" }, options));
|
||||
swal($.extend({ showConfirmButton: false, showCancelButton: false, timer: 1000, title: '未设置', type: "success" }, options));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
$(function () {
|
||||
var $dialog = $('#dialogNew');
|
||||
var $pickIcon = $('#pickIcon');
|
||||
var $dialogNew = $dialog.find('div.modal-dialog');
|
||||
var $dialogNew = $dialog;
|
||||
var $dialogIcon = $('#dialogIcon');
|
||||
var $dialogMenu = $('#dialogSubMenu').find('.modal-content');
|
||||
var $dialogMenu = $('#dialogMenu');
|
||||
var $dialogRole = $('#dialogRole');
|
||||
var $dialogRoleHeader = $('#myRoleModalLabel');
|
||||
var $dialogRoleForm = $('#roleForm');
|
||||
|
@ -18,7 +18,7 @@
|
|||
|
||||
var initNestMenu = function () {
|
||||
$nestMenuInput = $nestMenu.find('div.dd3-content');
|
||||
$nestMenuInput.find('label:first').hide();
|
||||
$nestMenuInput.children('.checkbox').hide();
|
||||
}
|
||||
|
||||
var bsa = new BootstrapAdmin({
|
||||
|
@ -82,7 +82,7 @@
|
|||
queryParams: function (params) { return $.extend(params, { parentName: $('#txt_parent_menus_name').val(), name: $("#txt_menus_name").val(), category: $('#sel_menus_category').val(), isresource: $('#sel_menus_res').val() }); }, //传递参数(*)
|
||||
columns: [
|
||||
{ checkbox: true },
|
||||
{ title: "Id", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "编辑", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "父级菜单", field: "ParentName", sortable: true },
|
||||
{ title: "菜单名称", field: "Name", sortable: true },
|
||||
{ title: "菜单序号", field: "Order", sortable: true },
|
||||
|
@ -178,7 +178,6 @@
|
|||
|
||||
// 排序按钮
|
||||
$('#btnMenuOrder').on('click', function () {
|
||||
$dialogNew.hide();
|
||||
$btnSubmitMenu.data('type', 'order');
|
||||
$nestMenuInput.find('label:last').find('input').hide();
|
||||
$nestMenu.find('li.dd-item').hide().remove('[data-id="0"]');
|
||||
|
@ -193,27 +192,24 @@
|
|||
$nestMenu.find('ol.dd-list:first').append($.format('<li class="dd-item dd3-item" data-id="0" data-order="10" data-category="{1}"><div class="dd-handle dd3-handle"></div><div class="dd3-content"><label><span>{0}</span></label></div></li>', menuName, menuCate));
|
||||
}
|
||||
$nestMenu.find('li[data-id="' + did + '"] > div.dd3-content span').addClass('active');
|
||||
$dialogMenu.show().adjustDialog();
|
||||
$dialogNew.hide();
|
||||
$dialogMenu.modal('show');
|
||||
});
|
||||
|
||||
// 选择父节点按钮
|
||||
$('#btnMenuParent').on('click', function () {
|
||||
$dialogNew.hide();
|
||||
$btnSubmitMenu.data('type', 'parent');
|
||||
$nestMenuInput.find('label:last').find('input').show();
|
||||
$nestMenu.find('li.dd-item').hide().remove('[data-id="0"]');
|
||||
$nestMenu.find('li[data-category="' + $category.val() + '"]').show();
|
||||
$dialogMenu.show().adjustDialog();
|
||||
$dialogNew.hide();
|
||||
$dialogMenu.modal('show');
|
||||
});
|
||||
|
||||
$dialogMenu.find('div.modal-header, div.modal-footer').on('click', 'button', function () {
|
||||
// remove active css
|
||||
$nestMenu.find('li span').removeClass('active');
|
||||
$dialogMenu.hide();
|
||||
$dialogNew.show();
|
||||
});
|
||||
$dialogMenu.on('hidden.bs.modal', function () { $dialogNew.show().find('.modal-dialog').adjustDialog(); });
|
||||
|
||||
$btnSubmitMenu.on('click', function () {
|
||||
$nestMenu.find('li span').removeClass('active');
|
||||
var type = $(this).data('type');
|
||||
switch (type) {
|
||||
case "parent":
|
||||
|
@ -264,8 +260,11 @@
|
|||
});
|
||||
|
||||
$(window).on('resize.bs.modal', function () {
|
||||
if ($dialogMenu.is(':visible')) {
|
||||
if ($dialogMenu.is(':visible') && ($(window).width() >= 768 || $(window).height() >= 672)) {
|
||||
$dialogMenu.adjustDialog();
|
||||
}
|
||||
else {
|
||||
$dialogMenu.css({ margin: "0" });
|
||||
}
|
||||
});
|
||||
});
|
|
@ -26,8 +26,8 @@
|
|||
maxlength: 50
|
||||
}
|
||||
}, {
|
||||
button: ['btnSaveDisplayName']
|
||||
});
|
||||
button: ['btnSaveDisplayName']
|
||||
});
|
||||
$('#passwordDataForm').autoValidate({
|
||||
currentPassword: {
|
||||
required: true,
|
||||
|
@ -43,8 +43,8 @@
|
|||
maxlength: 50
|
||||
}
|
||||
}, {
|
||||
button: ['btnSavePassword']
|
||||
});
|
||||
button: ['btnSavePassword']
|
||||
});
|
||||
|
||||
var bsa = new BootstrapAdmin({
|
||||
url: Profiles.url,
|
||||
|
@ -54,7 +54,8 @@
|
|||
Password: "currentPassword",
|
||||
NewPassword: "newPassword",
|
||||
DisplayName: "displayName",
|
||||
UserName: "userName"
|
||||
UserName: "userName",
|
||||
Css: "css"
|
||||
}
|
||||
}),
|
||||
click: {
|
||||
|
@ -81,6 +82,12 @@
|
|||
});
|
||||
}
|
||||
}
|
||||
}, {
|
||||
id: 'btnSaveCss',
|
||||
click: function (row, data) {
|
||||
data.UserStatus = 3;
|
||||
$.bc({ url: User.url, method: "PUT", data: data, title: "保存样式" });
|
||||
}
|
||||
}]
|
||||
}
|
||||
});
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
url: Role.url,
|
||||
dataEntity: new DataEntity({
|
||||
map: {
|
||||
ID: "roleID",
|
||||
Id: "roleID",
|
||||
RoleName: "roleName",
|
||||
Description: "roleDesc"
|
||||
}
|
||||
|
@ -120,10 +120,11 @@
|
|||
url: Role.url, //请求后台的URL(*)
|
||||
sortName: 'RoleName',
|
||||
queryParams: function (params) { return $.extend(params, { roleName: $("#txt_search_name").val(), description: $("#txt_role_desc").val() }); }, //传递参数(*)
|
||||
columns: [{ checkbox: true },
|
||||
{ title: "Id", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "角色名称", field: "RoleName", sortable: true },
|
||||
{ title: "角色描述", field: "Description", sortable: false }
|
||||
columns: [
|
||||
{ checkbox: true },
|
||||
{ title: "编辑", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "角色名称", field: "RoleName", sortable: true },
|
||||
{ title: "角色描述", field: "Description", sortable: false }
|
||||
]
|
||||
});
|
||||
|
||||
|
@ -143,6 +144,6 @@
|
|||
if (child.hasClass('dd-list')) {
|
||||
child.find(':checkbox').prop('checked', val);
|
||||
}
|
||||
}).find('label:last').hide();
|
||||
}).children('.radio').hide();
|
||||
});
|
||||
});
|
|
@ -57,16 +57,14 @@
|
|||
id: 'cssSave',
|
||||
click: function (row, data) {
|
||||
var cssDefine = $('#dictCssDefine').val();
|
||||
if (cssDefine) {
|
||||
$.bc({
|
||||
url: Settings.url, data: { name: '使用样式', code: cssDefine, category: '当前样式' }, title: '网站样式',
|
||||
callback: function (result) {
|
||||
if (result) {
|
||||
window.setTimeout(function () { window.location.reload(true); }, 1000);
|
||||
}
|
||||
$.bc({
|
||||
url: Settings.url, data: { name: '使用样式', code: cssDefine, category: '当前样式' }, title: '网站样式',
|
||||
callback: function (result) {
|
||||
if (result) {
|
||||
window.setTimeout(function () { window.location.reload(true); }, 1000);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}]
|
||||
}
|
||||
|
@ -145,7 +143,7 @@
|
|||
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)) / 1000)));
|
||||
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);
|
||||
|
@ -167,7 +165,7 @@
|
|||
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').html(html);
|
||||
$('#cssContainer').append(html);
|
||||
$.bc({
|
||||
Id: 1, url: Dicts.url, data: { type: 'activeCss' }, swal: false,
|
||||
callback: function (result) {
|
||||
|
|
|
@ -94,7 +94,7 @@
|
|||
queryParams: function (params) { return $.extend(params, { name: $("#txt_search_name").val(), displayName: $('#txt_display_name').val() }); }, //传递参数(*)
|
||||
columns: [
|
||||
{ checkbox: true },
|
||||
{ title: "Id", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "编辑", field: "Id", events: bsa.idEvents(), formatter: BootstrapAdmin.idFormatter },
|
||||
{ title: "登陆名称", field: "UserName", sortable: true },
|
||||
{ title: "显示名称", field: "DisplayName", sortable: true },
|
||||
{ title: "注册时间", field: "RegisterTime", sortable: true },
|
||||
|
|
|
@ -3,10 +3,10 @@
|
|||
var html = "";
|
||||
$.each(menus, function (index, menu) {
|
||||
if (menu.Menus.length == 0) {
|
||||
html += $.format('<li class="dd-item dd3-item" data-id="{0}" data-order="{4}" data-category="{3}"><div class="dd-handle dd3-handle"></div><div class="dd3-content"><label><input type="checkbox" value="{0}"><span><i class="{1}"></i>{2}</span></label><label><input type="radio" name="menu" value="{0}"><span><i class="{1}"></i>{2}</span></label><span class="menuType">{5}</span><span class="menuOrder">{4}</span></div></li>', menu.Id, menu.Icon, menu.Name, menu.Category, menu.Order, menu.CategoryName);
|
||||
html += $.format('<li class="dd-item dd3-item" data-id="{0}" data-order="{4}" data-category="{3}"><div class="dd-handle dd3-handle"></div><div class="dd3-content"><div class="checkbox"><label><input type="checkbox" value="{0}"><span><i class="{1}"></i>{2}</span></label></div><div class="radio"><label><input type="radio" name="menu" value="{0}"><span><i class="{1}"></i>{2}</span></label></div><span class="menuType">{5}</span><span class="menuOrder">{4}</span></div></li>', menu.Id, menu.Icon, menu.Name, menu.Category, menu.Order, menu.CategoryName);
|
||||
}
|
||||
else {
|
||||
html += $.format('<li class="dd-item dd3-item" data-id="{0}" data-order="{5}" data-category="{3}"><div class="dd-handle dd3-handle"></div><div class="dd3-content"><label><input type="checkbox" value="{0}"><span><i class="{1}"></i>{2}</span></label><label><input type="radio" name="menu" value="{0}"><span><i class="{1}"></i>{2}</span></label><span class="menuType">{6}</span><span class="menuOrder">{5}</span></div><ol class="dd-list">{4}</ol></li>', menu.Id, menu.Icon, menu.Name, menu.Category, cascadeSubMenu(menu.Menus), menu.Order, menu.CategoryName);
|
||||
html += $.format('<li class="dd-item dd3-item" data-id="{0}" data-order="{5}" data-category="{3}"><div class="dd-handle dd3-handle"></div><div class="dd3-content"><div class="checkbox"><label><input type="checkbox" value="{0}"><span><i class="{1}"></i>{2}</span></label></div><div class="radio"><label><input type="radio" name="menu" value="{0}"><span><i class="{1}"></i>{2}</span></label></div><span class="menuType">{6}</span><span class="menuOrder">{5}</span></div><ol class="dd-list">{4}</ol></li>', menu.Id, menu.Icon, menu.Name, menu.Category, cascadeSubMenu(menu.Menus), menu.Order, menu.CategoryName);
|
||||
}
|
||||
});
|
||||
return html;
|
||||
|
@ -15,7 +15,7 @@
|
|||
var cascadeSubMenu = function (menus) {
|
||||
var html = ""
|
||||
$.each(menus, function (index, menu) {
|
||||
html += $.format('<li class="dd-item dd3-item" data-id="{0}" data-order="{4}" data-category="{3}"><div class="dd-handle dd3-handle"></div><div class="dd3-content"><label><input type="checkbox" value="{0}"><span><i class="{1}"></i>{2}</span></label><label><input type="radio" name="menu" value="{0}"><span><i class="{1}"></i>{2}</span></label><span class="menuType">{5}</span><span class="menuOrder">{4}</span></div></li>', menu.Id, menu.Icon, menu.Name, menu.Category, menu.Order, menu.CategoryName);
|
||||
html += $.format('<li class="dd-item dd3-item" data-id="{0}" data-order="{4}" data-category="{3}"><div class="dd-handle dd3-handle"></div><div class="dd3-content"><div class="checkbox"><label><input type="checkbox" value="{0}"><span><i class="{1}"></i>{2}</span></label></div><div class="radio"><label><input type="radio" name="menu" value="{0}"><span><i class="{1}"></i>{2}</span></label></div><span class="menuType">{5}</span><span class="menuOrder">{4}</span></div></li>', menu.Id, menu.Icon, menu.Name, menu.Category, menu.Order, menu.CategoryName);
|
||||
});
|
||||
return html;
|
||||
};
|
||||
|
@ -33,11 +33,128 @@
|
|||
callback();
|
||||
}
|
||||
});
|
||||
},
|
||||
resetWidget: function () {
|
||||
var widgets = $(this).children('li');
|
||||
widgets.each(function () {
|
||||
var widget = $(this).children('ul');
|
||||
if (widget.children().length === 3) return;
|
||||
var last = widget.children(':last');
|
||||
while (widget.children().length > 3) {
|
||||
widget.children(':eq(2)').remove();
|
||||
}
|
||||
});
|
||||
return $(this);
|
||||
}
|
||||
});
|
||||
|
||||
$.extend({
|
||||
pullNotification: function () {
|
||||
if ($('.notify-row').length == 0) return;
|
||||
setTimeout(function () {
|
||||
NProgress.status = true;
|
||||
NProgress.configure({ trickle: false });
|
||||
$.bc({
|
||||
url: '../api/WS',
|
||||
method: 'GET',
|
||||
swal: false,
|
||||
callback: function (result) {
|
||||
NProgress.status = false;
|
||||
for (index in result) {
|
||||
var cate = result[index].Category;
|
||||
var msg = result[index].Message;
|
||||
switch (cate) {
|
||||
case "Notification":
|
||||
toastr.error(msg, "应用程序出现错误");
|
||||
break;
|
||||
case "Users":
|
||||
toastr.info(msg, "新用户注册");
|
||||
break;
|
||||
}
|
||||
};
|
||||
if (result.length > 0) $.reloadWidget();
|
||||
$.pullNotification();
|
||||
}
|
||||
});
|
||||
}, 5000);
|
||||
},
|
||||
reloadWidget: function () {
|
||||
if ($('.notify-row').length == 0) return;
|
||||
$.bc({
|
||||
url: Notifications.url,
|
||||
swal: false,
|
||||
method: 'GET',
|
||||
callback: function (result) {
|
||||
$('#logoutNoti').text(result.NewUsersCount);
|
||||
$('.notify-row').resetWidget();
|
||||
// tasks
|
||||
// new users
|
||||
$('#msgHeaderTask').text(result.TasksCount);
|
||||
$('#msgHeaderTaskBadge').text(result.TasksCount);
|
||||
var htmlUserTemplate = '<li><a href="../Admin/Tasks?id={3}"><span class="desc">{0}-{2}</span><span class="percent">{1}%</span></span><div class="progress progress-striped"><div class="progress-bar" role="progressbar" aria-valuenow="{1}" aria-valuemin="0" aria-valuemax="100" style="width: {1}%"><span class="sr-only">{1}% 完成</span></div></div></a></li>';
|
||||
var html = result.Tasks.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.TaskName, u.TaskProgress, u.AssignDisplayName, u.Id);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderTaskContent'));
|
||||
|
||||
// new users
|
||||
$('#msgHeaderUser').text(result.NewUsersCount);
|
||||
$('#msgHeaderUserBadge').text(result.NewUsersCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Notifications"><span class="label label-success"><i class="fa fa-plus"></i></span><div title="{2}" class="content">{1}({0})</div><span class="small italic">{3}</span></a></li>';
|
||||
html = result.Users.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.UserName, u.DisplayName, u.Description, u.Period);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderUserContent'));
|
||||
|
||||
// apps
|
||||
$('#msgHeaderApp').text(result.AppExceptionsCount);
|
||||
$('#msgHeaderAppBadge').text(result.AppExceptionsCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Exceptions"><span class="label label-warning"><i class="fa fa-bug"></i></span><div title="{1}" class="content">{0}</div><span class="small italic">{2}</span></a></li>';
|
||||
html = result.Apps.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.ExceptionType, u.Message, u.Period);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderAppContent'));
|
||||
|
||||
// dbs
|
||||
$('#msgHeaderDb').text(result.DbExceptionsCount);
|
||||
$('#msgHeaderDbBadge').text(result.DbExceptionsCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Exceptions"><span class="label label-danger"><i class="fa fa-bolt"></i></span><div title="{1}" class="content">{0}</div><span class="small italic">{2}</span></a></li>';
|
||||
html = result.Dbs.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.ErrorPage, u.Message, u.Period);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderDbContent'));
|
||||
|
||||
// messages
|
||||
$('#msgHeaderMsg').text(result.MessagesCount);
|
||||
$('#msgHeaderMsgBadge').text(result.MessagesCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Messages?id={0}"><span class="photo"><img alt="avatar" src="{1}"></span><span class="subject"><span class="from">{2}</span><span class="time">{4}</span></span><span class="message" title="{5}">{3}</span></a></li>';
|
||||
html = result.Messages.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.Id, u.FromIcon, u.FromDisplayName, u.Title, u.Period, u.Content);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderMsgContent'));
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
})(jQuery);
|
||||
|
||||
$(function () {
|
||||
toastr.options = {
|
||||
"closeButton": true,
|
||||
"debug": false,
|
||||
"progressBar": true,
|
||||
"positionClass": "toast-bottom-right",
|
||||
"onclick": null,
|
||||
"showDuration": "600",
|
||||
"hideDuration": "2000",
|
||||
"timeOut": "5000",
|
||||
"extendedTimeOut": "1000",
|
||||
"showEasing": "swing",
|
||||
"hideEasing": "linear",
|
||||
"showMethod": "fadeIn",
|
||||
"hideMethod": "fadeOut"
|
||||
}
|
||||
|
||||
var $sidebar = $("#sidebar");
|
||||
var $main = $('#main-content');
|
||||
var $breadNav = $('#breadNav');
|
||||
|
@ -90,58 +207,6 @@ $(function () {
|
|||
$('.lgbDropdown').lgbDropdown();
|
||||
|
||||
// load widget data
|
||||
$.bc({
|
||||
url: Notifications.url,
|
||||
swal: false,
|
||||
method: 'GET',
|
||||
callback: function (result) {
|
||||
$('#logoutNoti').text(result.NewUsersCount);
|
||||
|
||||
// tasks
|
||||
// new users
|
||||
$('#msgHeaderTask').text(result.TasksCount);
|
||||
$('#msgHeaderTaskBadge').text(result.TasksCount);
|
||||
var htmlUserTemplate = '<li><a href="../Admin/Tasks?id={3}"><span class="desc">{0}-{2}</span><span class="percent">{1}%</span></span><div class="progress progress-striped"><div class="progress-bar" role="progressbar" aria-valuenow="{1}" aria-valuemin="0" aria-valuemax="100" style="width: {1}%"><span class="sr-only">{1}% 完成</span></div></div></a></li>';
|
||||
var html = result.Tasks.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.TaskName, u.TaskProgress, u.AssignDisplayName, u.Id);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderTaskContent'));
|
||||
|
||||
// new users
|
||||
$('#msgHeaderUser').text(result.NewUsersCount);
|
||||
$('#msgHeaderUserBadge').text(result.NewUsersCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Notifications"><span class="label label-success"><i class="fa fa-plus"></i></span><div title="{2}" class="content">{1}({0})</div><span class="small italic">{3}</span></a></li>';
|
||||
html = result.Users.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.UserName, u.DisplayName, u.Description, u.Period);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderUserContent'));
|
||||
|
||||
// apps
|
||||
$('#msgHeaderApp').text(result.AppExceptionsCount);
|
||||
$('#msgHeaderAppBadge').text(result.AppExceptionsCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Exceptions"><span class="label label-warning"><i class="fa fa-bug"></i></span><div title="{1}" class="content">{0}</div><span class="small italic">{2}</span></a></li>';
|
||||
html = result.Apps.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.ExceptionType, u.Message, u.Period);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderAppContent'));
|
||||
|
||||
// dbs
|
||||
$('#msgHeaderDb').text(result.DbExceptionsCount);
|
||||
$('#msgHeaderDbBadge').text(result.DbExceptionsCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Exceptions"><span class="label label-danger"><i class="fa fa-bolt"></i></span><div title="{1}" class="content">{0}</div><span class="small italic">{2}</span></a></li>';
|
||||
html = result.Dbs.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.ErrorPage, u.Message, u.Period);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderDbContent'));
|
||||
|
||||
// messages
|
||||
$('#msgHeaderMsg').text(result.MessagesCount);
|
||||
$('#msgHeaderMsgBadge').text(result.MessagesCount);
|
||||
htmlUserTemplate = '<li><a href="../Admin/Messages?id={0}"><span class="photo"><img alt="avatar" src="{1}"></span><span class="subject"><span class="from">{2}</span><span class="time">{4}</span></span><span class="message" title="{5}">{3}</span></a></li>';
|
||||
html = result.Messages.map(function (u) {
|
||||
return $.format(htmlUserTemplate, u.Id, u.FromIcon, u.FromDisplayName, u.Title, u.Period, u.Content);
|
||||
}).join('');
|
||||
$(html).insertAfter($('#msgHeaderMsgContent'));
|
||||
}
|
||||
});
|
||||
$.reloadWidget();
|
||||
$.pullNotification();
|
||||
});
|
|
@ -69,7 +69,7 @@
|
|||
};
|
||||
|
||||
BootstrapAdmin.idFormatter = function (value, row, index) {
|
||||
return "<a class='edit' href='javascript:void(0)'>" + value + "</a>";
|
||||
return "<a class='edit' title='" + value + "' href='javascript:void(0)'>编辑</a>";
|
||||
};
|
||||
|
||||
BootstrapAdmin.prototype = {
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -21,7 +21,7 @@
|
|||
<div class="panel-body">
|
||||
<form class="form-inline" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-xs-12 col-sm-6 col-md-5 col-lg-5">
|
||||
<div class="form-group 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>
|
||||
|
@ -29,7 +29,7 @@
|
|||
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-xs-12 col-sm-6 col-md-5 col-lg-5">
|
||||
<div class="form-group 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>
|
||||
|
@ -37,7 +37,7 @@
|
|||
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-xs-12 col-sm-12 col-md-2 col-lg-2">
|
||||
<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>
|
||||
</div>
|
||||
|
@ -60,7 +60,7 @@
|
|||
<div class="panel-heading">
|
||||
查询结果
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="panel-body barTable">
|
||||
<table></table>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -94,7 +94,7 @@
|
|||
<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"><div class="text-center"><i class="fa fa-spinner fa-pulse fa-3x fa-fw"></i></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 class="modal-footer">
|
||||
|
|
|
@ -9,15 +9,15 @@
|
|||
@section query {
|
||||
<form class="form-inline" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-lg-5">
|
||||
<div class="form-group 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-lg-5">
|
||||
<div class="form-group 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-lg-2">
|
||||
<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>
|
||||
</div>
|
||||
|
@ -47,11 +47,11 @@
|
|||
<div class="modal-body">
|
||||
<form class="form-inline" id="dataForm" name="dataForm" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-lg-6">
|
||||
<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" />
|
||||
</div>
|
||||
<div class="form-group col-lg-6">
|
||||
<div class="form-group col-sm-6">
|
||||
<input type="text" class="form-control hidden" id="groupID" name="groupID" />
|
||||
<label class="control-label" for="groupDesc">部门描述</label>
|
||||
<input type="text" class="form-control" id="groupDesc" name="groupDesc" placeholder="描述信息(可为空),50字以内" maxlength="50" />
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
|
||||
.main-content h4 {
|
||||
color: #fff;
|
||||
margin-top: 0;
|
||||
}
|
||||
</style>
|
||||
}
|
||||
|
@ -21,4 +22,4 @@
|
|||
});
|
||||
</script>
|
||||
}
|
||||
<div><h4>欢迎使用后台管理</h4></div>
|
||||
<h4>欢迎使用后台管理</h4>
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-xs-12 col-sm-6 col-md-5">
|
||||
<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>
|
||||
|
@ -34,7 +34,7 @@
|
|||
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-xs-12 col-sm-6 col-md-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>
|
||||
|
@ -42,7 +42,7 @@
|
|||
<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-xs-12 col-sm-12 col-md-2">
|
||||
<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>
|
||||
</div>
|
||||
|
@ -54,7 +54,7 @@
|
|||
<div class="panel-heading">
|
||||
查询结果
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="panel-body barTable">
|
||||
<table></table>
|
||||
</div>
|
||||
</div>
|
|
@ -14,15 +14,15 @@
|
|||
@section query {
|
||||
<form class="form-inline" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-sm-6 col-md-3">
|
||||
<div class="form-group col-sm-12 col-md-6 col-lg-5">
|
||||
<label class="control-label" for="txt_menus_name">菜单名称</label>
|
||||
<input type="text" class="form-control" id="txt_menus_name" />
|
||||
</div>
|
||||
<div class="form-group col-sm-6 col-md-3">
|
||||
<div class="form-group col-sm-12 col-md-6 col-lg-5">
|
||||
<label class="control-label" for="txt_parent_menus_name">父级菜单</label>
|
||||
<input type="text" class="form-control" id="txt_parent_menus_name" />
|
||||
</div>
|
||||
<div class="form-group col-sm-6 col-md-2">
|
||||
<div class="form-group col-sm-6 col-md-6 col-lg-5">
|
||||
<label class="control-label" for="sel_menus_category">菜单类别</label>
|
||||
<div class="dropdown lgbDropdown">
|
||||
<a id="sel_menus_category" class="btn btn-success" data-toggle="dropdown">
|
||||
|
@ -37,7 +37,7 @@
|
|||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-sm-6 col-md-2">
|
||||
<div class="form-group col-sm-6 col-md-6 col-lg-5">
|
||||
<label class="control-label" for="sel_menus_category">菜单类型</label>
|
||||
<div class="dropdown lgbDropdown">
|
||||
<a id="sel_menus_res" class="btn btn-success" data-toggle="dropdown">
|
||||
|
@ -52,7 +52,7 @@
|
|||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-xs-12 col-sm-1">
|
||||
<div class="form-group col-lg-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>
|
||||
</div>
|
||||
|
@ -200,5 +200,5 @@
|
|||
<button type="button" class="btn btn-primary" id="btnSubmitIcon">保存</button>
|
||||
</div>
|
||||
</div>
|
||||
@Html.Partial("MenuTree")
|
||||
@Html.Partial("NavigatorConfig")
|
||||
}
|
||||
|
|
|
@ -4,11 +4,9 @@
|
|||
Layout = "~/Views/Shared/_Admin.cshtml";
|
||||
}
|
||||
@section Javascript {
|
||||
<script src="~/Scripts/sweetalert.js"></script>
|
||||
<script src="~/Scripts/noti.js"></script>
|
||||
}
|
||||
@section css {
|
||||
<link href="~/Content/sweetalert.css" rel="stylesheet" />
|
||||
<link href="~/Content/tasks.css" rel="stylesheet" />
|
||||
}
|
||||
<div class="panel panel-default">
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
}
|
||||
@section Javascript {
|
||||
<script src="~/Scripts/longbow.dataentity.js"></script>
|
||||
<script src="~/Scripts/sweetalert.js"></script>
|
||||
<script src="~/Scripts/fileinput.js"></script>
|
||||
<script src="~/Scripts/fileinput.zh.js"></script>
|
||||
<script src="~/Scripts/jquery.validate.js"></script>
|
||||
|
@ -13,7 +12,6 @@
|
|||
<script src="~/scripts/Profiles.js"></script>
|
||||
}
|
||||
@section css {
|
||||
<link href="~/Content/sweetalert.css" rel="stylesheet" />
|
||||
<link href="~/Content/tasks.css" rel="stylesheet" />
|
||||
<link href="~/Content/fileinput.css" rel="stylesheet" />
|
||||
}
|
||||
|
@ -42,15 +40,17 @@
|
|||
<div class="panel-body">
|
||||
<form id="passwordDataForm" name="passwordDataForm" class="form-inline" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-md-4 col-xs-12">
|
||||
<div class="form-group col-xs-12">
|
||||
<label class="control-label" for="currentPassword">原密码: </label>
|
||||
<input type="password" class="form-control" id="currentPassword" name="currentPassword" placeholder="原密码,50字以内" maxlength="50" />
|
||||
</div>
|
||||
<div class="form-group col-md-4 col-sm-6 col-xs-12">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group col-sm-6 col-xs-12">
|
||||
<label class="control-label" for="newPassword">新密码: </label>
|
||||
<input type="password" class="form-control" id="newPassword" name="newPassword" placeholder="新密码,50字以内" maxlength="50" />
|
||||
</div>
|
||||
<div class="form-group col-md-4 col-sm-6 col-xs-12">
|
||||
<div class="form-group col-sm-6 col-xs-12">
|
||||
<label class="control-label" for="confirmPassword">确认密码: </label>
|
||||
<input type="password" class="form-control" id="confirmPassword" name="confirmPassword" placeholder="与新密码一致,50字以内" maxlength="50" />
|
||||
</div>
|
||||
|
@ -61,6 +61,35 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">网站皮肤</div>
|
||||
<div class="panel-body">
|
||||
<form id="infoDataForm" name="cssDataForm" class="form-inline" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-xs-12">
|
||||
<label class="control-label" for="userName">样式</label>
|
||||
<select id="css" class="select form-control">
|
||||
<option value="">默认样式</option>
|
||||
@foreach (var css in Model.Csss)
|
||||
{
|
||||
if (css.Code == Model.Css)
|
||||
{
|
||||
<option selected value="@css.Code">@css.Name</option>
|
||||
}
|
||||
else
|
||||
{
|
||||
<option value="@css.Code">@css.Name</option>
|
||||
}
|
||||
}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<div class="modal-footer">
|
||||
<button id="btnSaveCss" class="btn btn-default" type="button" disabled data-admin="@LgbPrincipal.IsWebAdmin(User.Identity.Name)"><i class="fa fa-save"></i><span>保存</span></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">修改头像</div>
|
||||
<div class="panel-body">
|
||||
|
|
|
@ -15,15 +15,15 @@
|
|||
@section query {
|
||||
<form class="form-inline" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-lg-5">
|
||||
<div class="form-group 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-lg-5">
|
||||
<div class="form-group col-md-5">
|
||||
<label class="control-label" for="txt_role_desc">角色描述</label>
|
||||
<input type="text" class="form-control" id="txt_role_desc" />
|
||||
</div>
|
||||
<div class="form-group col-lg-2">
|
||||
<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>
|
||||
</div>
|
||||
|
@ -57,11 +57,11 @@
|
|||
<div class="modal-body">
|
||||
<form class="form-inline" id="dataForm" name="dataForm" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-lg-6">
|
||||
<div class="form-group col-sm-6">
|
||||
<label class="control-label" for="roleName">角色名称</label>
|
||||
<input type="text" class="form-control" id="roleName" name="roleName" placeholder="不可为空,50字以内" maxlength="50" />
|
||||
</div>
|
||||
<div class="form-group col-lg-6">
|
||||
<div class="form-group col-sm-6">
|
||||
<input type="text" class="form-control hidden" id="roleID" name="roleID" />
|
||||
<label class="control-label" for="roleDesc">角色描述</label>
|
||||
<input type="text" class="form-control" id="roleDesc" name="roleDesc" placeholder="描述信息(可为空),50字以内" maxlength="50" />
|
||||
|
|
|
@ -5,13 +5,11 @@
|
|||
}
|
||||
@section Javascript {
|
||||
<script src="~/Scripts/longbow.dataentity.js"></script>
|
||||
<script src="~/Scripts/sweetalert.js"></script>
|
||||
<script src="~/Scripts/jquery.validate.js"></script>
|
||||
<script src="~/Scripts/messages_zh.js"></script>
|
||||
<script src="~/Scripts/Settings.js"></script>
|
||||
}
|
||||
@section css {
|
||||
<link href="~/Content/sweetalert.css" rel="stylesheet" />
|
||||
<link href="~/Content/tasks.css" rel="stylesheet" />
|
||||
}
|
||||
<div class="panel panel-default">
|
||||
|
@ -48,12 +46,12 @@
|
|||
<div class="form-group col-xs-12">
|
||||
<label class="control-label">网站样式</label>
|
||||
<div class="dropdown lgbDropdown">
|
||||
<a id="dictCssDefine" class="btn btn-success" data-toggle="dropdown" data-default-val="site.css">
|
||||
<a id="dictCssDefine" class="btn btn-success" data-toggle="dropdown" data-default-val="">
|
||||
<span>默认样式</span>
|
||||
<span class="caret"></span>
|
||||
</a>
|
||||
<ul class="dropdown-menu" role="menu" id="cssContainer">
|
||||
<li><a href="#" data-val="site.css">默认样式</a></li>
|
||||
<li><a href="#" data-val="">默认样式</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<button class="btn btn-default pull-right" type="button" id="cssSave">保存</button>
|
||||
|
|
|
@ -4,11 +4,9 @@
|
|||
Layout = "~/Views/Shared/_Admin.cshtml";
|
||||
}
|
||||
@section Javascript {
|
||||
<script src="~/Scripts/sweetalert.js"></script>
|
||||
<script src="~/Scripts/tasks.js"></script>
|
||||
}
|
||||
@section css {
|
||||
<link href="~/Content/sweetalert.css" rel="stylesheet" />
|
||||
<link href="~/Content/tasks.css" rel="stylesheet" />
|
||||
}
|
||||
<div class="panel panel-default">
|
||||
|
|
|
@ -9,15 +9,15 @@
|
|||
@section query {
|
||||
<form class="form-inline" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-lg-5">
|
||||
<div class="form-group 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-lg-5">
|
||||
<div class="form-group col-md-5">
|
||||
<label class="control-label" for="txt_display_name">显示名称</label>
|
||||
<input type="text" class="form-control" id="txt_display_name" />
|
||||
</div>
|
||||
<div class="form-group col-lg-2">
|
||||
<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>
|
||||
</div>
|
||||
|
@ -47,20 +47,20 @@
|
|||
<div class="modal-body">
|
||||
<form class="form-inline" id="dataForm" name="dataForm" role="form">
|
||||
<div class="row">
|
||||
<div class="form-group col-lg-6">
|
||||
<div class="form-group col-sm-6">
|
||||
<label class="control-label" for="userName">登陆名称</label>
|
||||
<input type="text" class="form-control" id="userName" name="userName" placeholder="不可为空,50字以内" maxlength="50" />
|
||||
</div>
|
||||
<div class="form-group col-lg-6">
|
||||
<div class="form-group col-sm-6">
|
||||
<input type="text" class="form-control hidden" id="userID" name="userID" />
|
||||
<label class="control-label" for="userName">显示名称</label>
|
||||
<input type="text" class="form-control" id="displayName" name="displayName" placeholder="不可为空,50字以内" maxlength="50" />
|
||||
</div>
|
||||
<div class="form-group col-lg-6">
|
||||
<div class="form-group col-sm-6">
|
||||
<label class="control-label" for="password">登录密码</label>
|
||||
<input type="password" class="form-control" id="password" name="password" placeholder="不可为空,50字以内" maxlength="50" />
|
||||
</div>
|
||||
<div class="form-group col-lg-6">
|
||||
<div class="form-group col-sm-6">
|
||||
<label class="control-label" for="confirm">确认密码</label>
|
||||
<input type="password" class="form-control" id="confirm" name="confirm" placeholder="与登陆密码一致,50字以内" maxlength="50" />
|
||||
</div>
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
@model HeaderBarModel
|
||||
<header class="header">
|
||||
<div class="bg">
|
||||
</div>
|
||||
<a id="navbar" href="#" class="sidebar-toggle-box">
|
||||
<i class="fa fa-bars"></i>
|
||||
<span id="websiteTitle">@Model.Title</span>
|
||||
|
|
|
@ -1,3 +1,19 @@
|
|||
<div class="modal fade" id="dialogMenu" tabindex="-1" role="dialog" data-backdrop="static" aria-labelledby="myMenuModalLabel" aria-hidden="true">
|
||||
@Html.Partial("MenuTree")
|
||||
<div id="dialogSubMenu" class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h4 class="modal-title" id="myMenuModalLabel">请选择菜单</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="dd" id="nestable_menu">
|
||||
<ol class="dd-list"></ol>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
|
||||
<button type="button" class="btn btn-primary" data-dismiss="modal" id="btnSubmitMenu">保存</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -2,16 +2,20 @@
|
|||
Layout = "~/Views/Shared/_Layout.cshtml";
|
||||
}
|
||||
@section css {
|
||||
<link href="~/Content/sweetalert.css" rel="stylesheet" />
|
||||
<link href="~/Content/toastr.css" rel="stylesheet" />
|
||||
<link href="~/Content/admin.css" rel="stylesheet" />
|
||||
<link href="~/Content/admin-responsive.css" rel="stylesheet" />
|
||||
@RenderSection("css", false)
|
||||
}
|
||||
@section javascript {
|
||||
<script src="~/Scripts/sweetalert.js"></script>
|
||||
<script src="~/Scripts/jquery.dcjqaccordion.2.7.js"></script>
|
||||
<script src="~/Scripts/jquery.scrollTo.js"></script>
|
||||
<script src="~/Scripts/jquery.nicescroll.min.js"></script>
|
||||
<script src="~/Scripts/common-scripts.js"></script>
|
||||
<script src="~/Scripts/log.js"></script>
|
||||
<script src="~/Scripts/toastr.min.js"></script>
|
||||
<script src="~/Scripts/framework.js"></script>
|
||||
@RenderSection("Javascript", false)
|
||||
}
|
||||
|
|
|
@ -3,12 +3,10 @@
|
|||
}
|
||||
@section css {
|
||||
<link href="~/Content/bootstrap-table.css" rel="stylesheet" />
|
||||
<link href="~/Content/sweetalert.css" rel="stylesheet" />
|
||||
@RenderSection("css", false)
|
||||
}
|
||||
@section javascript {
|
||||
<script src="~/Scripts/longbow.dataentity.js"></script>
|
||||
<script src="~/Scripts/sweetalert.js"></script>
|
||||
<script src="~/Scripts/bootstrap-table.js"></script>
|
||||
<script src="~/Scripts/bootstrap-table-zh-CN.js"></script>
|
||||
<script src="~/Scripts/jquery.validate.js"></script>
|
||||
|
@ -49,7 +47,7 @@
|
|||
<div id="panelResultHeader" class="panel-heading">
|
||||
查询结果
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="panel-body barTable">
|
||||
<table></table>
|
||||
</div>
|
||||
</div>
|
|
@ -27,6 +27,13 @@
|
|||
</connectionStrings>
|
||||
|
||||
<cacheManager>
|
||||
<add key="BootstrapAdminPrincipal-RetrieveRoles" interval="600" desc="系统所有角色列表数据" />
|
||||
<add key="BootstrapAdminPrincipal-RetrieveRolesByUrl" interval="600" desc="指定菜单的角色数据缓存" />
|
||||
<add key="BootstrapAdminPrincipal-RetrieveRolesByUserName" interval="600" desc="指定用户名角色数据缓存" />
|
||||
<add key="BootstrapMenu-RetrieveMenus" interval="600" desc="所有菜单数据缓存" />
|
||||
<add key="BootstrapDict-RetrieveDicts" interval="600" desc="所有字典数据缓存" />
|
||||
<add key="BootstrapUser-RetrieveUsers" interval="600" desc="所有用户数据缓存" />
|
||||
<add key="BootstrapUser-RetrieveUsersByName" interval="600" desc="指定用户数据缓存" />
|
||||
<add key="UserHelper-RetrieveNewUsers" interval="30" desc="新用户数据缓存" />
|
||||
<add key="MenuHelper-RetrieveMenusByRoleId" interval="600" desc="角色菜单信息缓存" />
|
||||
<add key="RoleHelper-RetrieveRoles" interval="600" desc="所有角色数据缓存" />
|
||||
|
@ -42,15 +49,6 @@
|
|||
<add key="ExceptionHelper-RetrieveExceptions" interval="600" desc="程序异常数据缓存" />
|
||||
<add key="MessageHelper-RetrieveMessages" interval="600" desc="站内消息数据缓存" />
|
||||
<add key="TaskHelper-RetrieveTasks" interval="600" desc="所有任务数据缓存" />
|
||||
<add key="BootstrapAdminPrincipal-RetrieveAllRoles" interval="600" desc="系统所有角色列表数据" />
|
||||
<add key="BootstrapAdminPrincipal-RetrieveRolesByUrl" interval="600" desc="指定菜单的角色数据缓存" />
|
||||
<add key="BootstrapAdminPrincipal-RetrieveRolesByUserName" interval="600" desc="指定用户名角色数据缓存" />
|
||||
<add key="BootstrapAdminPrincipal-RetrieveAllGroups-BA" interval="600" desc="系统所有用户组列表数据" />
|
||||
<add key="BootstrapAdminPrincipal-RetrieveGroupsByUserName" interval="600" desc="通过用户获得用户组数据" />
|
||||
<add key="BootstrapMenu-RetrieveMenus" interval="600" desc="所有菜单数据缓存" />
|
||||
<add key="BootstrapDict-RetrieveDicts" interval="600" desc="所有字典数据缓存" />
|
||||
<add key="BootstrapUser-RetrieveUsers" interval="600" desc="所有用户数据缓存" />
|
||||
<add key="BootstrapUser-RetrieveUsersByName" interval="600" desc="指定用户数据缓存" />
|
||||
<add key="BootstrapUser-RetrieveUsersByRoleId" interval="600" desc="指定角色用户数据缓存" />
|
||||
<add key="BootstrapUser-RetrieveUsersByGroupId" interval="600" desc="指定组用户数据缓存" />
|
||||
<add key="WebApi" interval="21600" desc="WebApi 数据缓存" />
|
||||
|
@ -60,7 +58,7 @@
|
|||
|
||||
<cacheManagerList>
|
||||
<add key="bd" url="http://localhost:53233/CacheList.axd?cacheKey={0}" desc="系统缓存模块" />
|
||||
<add key="bccs" url="http://localhost:3609/CacheList.axd?cacheKey={0}" desc="集控系统缓存模块" />
|
||||
<add key="bccs" url="http://localhost:49823/CacheList.axd?cacheKey={0}" desc="集控系统缓存模块" />
|
||||
<add key="cps" url="http://localhost:43112/CacheList.axd?cacheKey={0}" desc="云心理后台缓存" />
|
||||
</cacheManagerList>
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>Bootstrap.DataAccess</RootNamespace>
|
||||
<AssemblyName>Bootstrap.DataAccess</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
|
@ -33,7 +33,7 @@
|
|||
<SignAssembly>true</SignAssembly>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<AssemblyOriginatorKeyFile>Longbow.Utility.snk</AssemblyOriginatorKeyFile>
|
||||
<AssemblyOriginatorKeyFile>..\..\Keys\Longbow.Utility.snk</AssemblyOriginatorKeyFile>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<DelaySign>true</DelaySign>
|
||||
|
@ -80,8 +80,10 @@
|
|||
<Compile Include="UserHelper.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="..\..\Keys\Longbow.Utility.snk">
|
||||
<Link>Longbow.Utility.snk</Link>
|
||||
</None>
|
||||
<None Include="ClassDiagram1.cd" />
|
||||
<None Include="Longbow.Utility.snk" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<PropertyGroup>
|
||||
|
|
|
@ -1,11 +1,9 @@
|
|||
using Bootstrap.Security;
|
||||
using Longbow.Caching;
|
||||
using Longbow.Caching.Configuration;
|
||||
using Longbow.ExceptionManagement;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
|
||||
namespace Bootstrap.DataAccess
|
||||
{
|
||||
|
@ -31,9 +29,11 @@ namespace Bootstrap.DataAccess
|
|||
{
|
||||
cacheKeys.Add(string.Format("{0}-{1}", UserHelper.RetrieveUsersByRoleIdDataKey, id));
|
||||
cacheKeys.Add(string.Format("{0}-{1}", GroupHelper.RetrieveGroupsByRoleIdDataKey, id));
|
||||
cacheKeys.Add(string.Format("{0}-{1}", MenuHelper.RetrieveMenusByRoleIdDataKey, id));
|
||||
});
|
||||
cacheKeys.Add(RoleHelper.RetrieveRolesDataKey + "*");
|
||||
cacheKeys.Add(BootstrapMenu.RetrieveMenusDataKey + "*");
|
||||
cacheKeys.Add(BootstrapAdminRolePrincipal.RetrieveAllRolesDataKey + "*");
|
||||
}
|
||||
if (userIds != null)
|
||||
{
|
||||
|
@ -55,6 +55,7 @@ namespace Bootstrap.DataAccess
|
|||
});
|
||||
cacheKeys.Add(GroupHelper.RetrieveGroupsDataKey + "*");
|
||||
cacheKeys.Add(BootstrapMenu.RetrieveMenusDataKey + "*");
|
||||
cacheKeys.Add(BootstrapAdminRolePrincipal.RetrieveAllRolesDataKey + "*");
|
||||
}
|
||||
if (menuIds != null)
|
||||
{
|
||||
|
@ -62,6 +63,7 @@ namespace Bootstrap.DataAccess
|
|||
{
|
||||
cacheKeys.Add(string.Format("{0}-{1}", RoleHelper.RetrieveRolesByMenuIdDataKey, id));
|
||||
});
|
||||
cacheKeys.Add(MenuHelper.RetrieveMenusByRoleIdDataKey + "*");
|
||||
cacheKeys.Add(BootstrapMenu.RetrieveMenusDataKey + "*");
|
||||
}
|
||||
if (dictIds != null)
|
||||
|
@ -81,29 +83,25 @@ namespace Bootstrap.DataAccess
|
|||
cacheKeys.Add(ExceptionHelper.RetrieveExceptionsDataKey + "*");
|
||||
}
|
||||
|
||||
cacheKeys.AsParallel().ForAll(key => CacheManager.Clear(k => key.EndsWith("*") ? k.Contains(key.TrimEnd('*')) : k.Equals(key)));
|
||||
System.Threading.Tasks.Task.Factory.StartNew(() =>
|
||||
{
|
||||
var section = CacheListSection.GetSection();
|
||||
section.Items.Where(item => item.Enabled).Skip(1).AsParallel().ForAll(ele =>
|
||||
{
|
||||
try
|
||||
{
|
||||
using (var client = new WebClient())
|
||||
{
|
||||
cacheKeys.ForEach(k => client.OpenRead(string.Format(ele.Url, k)));
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
System.Collections.Specialized.NameValueCollection nv = new System.Collections.Specialized.NameValueCollection();
|
||||
nv["ErrorPage"] = ele.Url;
|
||||
nv["UserId"] = "system";
|
||||
nv["UserIp"] = "::1";
|
||||
ExceptionManager.Publish(ex, nv);
|
||||
}
|
||||
});
|
||||
});
|
||||
ClearCache(cacheKeys);
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="key"></param>
|
||||
internal static void ClearCache(string key)
|
||||
{
|
||||
CacheManager.Clear(k => key.EndsWith("*") ? k.Contains(key.TrimEnd('*')) : key == k);
|
||||
CacheListSection.ClearCache(key);
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="keys"></param>
|
||||
internal static void ClearCache(IEnumerable<string> keys)
|
||||
{
|
||||
CacheManager.Clear(k => keys.Any(key => key.EndsWith("*") ? k.Contains(key.TrimEnd('*')) : key == k));
|
||||
CacheListSection.ClearCache(keys);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -160,7 +160,7 @@ namespace Bootstrap.DataAccess
|
|||
return (settings.FirstOrDefault(d => d.Name == "网站页脚" && d.Category == "网站设置" && d.Define == 0) ?? new BootstrapDict() { Code = "2016 © 通用后台管理系统" }).Code;
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// 获得系统中配置的可以使用的网站样式
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static IEnumerable<BootstrapDict> RetrieveWebCss()
|
||||
|
@ -169,7 +169,7 @@ namespace Bootstrap.DataAccess
|
|||
return data.Where(d => d.Category == "网站样式");
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// 获得网站设置中的当前样式
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static IEnumerable<BootstrapDict> RetrieveActiveCss()
|
||||
|
|
|
@ -14,7 +14,10 @@ namespace Bootstrap.DataAccess
|
|||
/// </summary>
|
||||
public static class ExceptionHelper
|
||||
{
|
||||
internal const string RetrieveExceptionsDataKey = "ExceptionHelper-RetrieveExceptions";
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public static readonly string RetrieveExceptionsDataKey = "ExceptionHelper-RetrieveExceptions";
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
|
@ -32,7 +35,7 @@ namespace Bootstrap.DataAccess
|
|||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@AppDomainName", AppDomain.CurrentDomain.FriendlyName));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@ErrorPage", additionalInfo["ErrorPage"]));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@UserID", DBAccess.ToDBValue(additionalInfo["UserId"])));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@UserIp", additionalInfo["UserIp"]));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@UserIp", DBAccess.ToDBValue(additionalInfo["UserIp"])));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@ExceptionType", ex.GetType().FullName));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@Message", ex.Message));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@StackTrace", DBAccess.ToDBValue(ex.StackTrace), ParameterDirection.Input));
|
||||
|
@ -68,8 +71,8 @@ namespace Bootstrap.DataAccess
|
|||
Id = (int)reader[0],
|
||||
AppDomainName = (string)reader[1],
|
||||
ErrorPage = (string)reader[2],
|
||||
UserId = (string)reader[3],
|
||||
UserIp = (string)reader[4],
|
||||
UserId = reader.IsDBNull(3) ? string.Empty : (string)reader[3],
|
||||
UserIp = reader.IsDBNull(4) ? string.Empty : (string)reader[4],
|
||||
ExceptionType = (string)reader[5],
|
||||
Message = (string)reader[6],
|
||||
StackTrace = (string)reader[7],
|
||||
|
|
Binary file not shown.
|
@ -16,7 +16,10 @@ namespace Bootstrap.DataAccess
|
|||
/// </summary>
|
||||
public static class MenuHelper
|
||||
{
|
||||
private const string RetrieveMenusByRoleIdDataKey = "MenuHelper-RetrieveMenusByRoleId";
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
internal const string RetrieveMenusByRoleIdDataKey = "MenuHelper-RetrieveMenusByRoleId";
|
||||
/// <summary>
|
||||
/// 删除菜单信息
|
||||
/// </summary>
|
||||
|
|
|
@ -2,10 +2,13 @@
|
|||
using Longbow.Caching;
|
||||
using Longbow.ExceptionManagement;
|
||||
using System;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Data.Common;
|
||||
using System.Linq;
|
||||
using System.Net.WebSockets;
|
||||
using System.Threading;
|
||||
|
||||
namespace Bootstrap.DataAccess
|
||||
{
|
||||
|
@ -14,8 +17,15 @@ namespace Bootstrap.DataAccess
|
|||
/// </summary>
|
||||
public static class NotificationHelper
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
internal const string RetrieveNotificationsDataKey = "NotificationHelper-RetrieveNotifications";
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public static readonly ConcurrentBag<MessageBody> MessagePool = new ConcurrentBag<MessageBody>();
|
||||
/// <summary>
|
||||
/// 新用户注册的通知的面板显示
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
|
@ -113,4 +123,57 @@ namespace Bootstrap.DataAccess
|
|||
return ret;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public class MessageBody : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public MessageBody()
|
||||
{
|
||||
timer = new Timer(state =>
|
||||
{
|
||||
var msg = this;
|
||||
NotificationHelper.MessagePool.TryTake(out msg);
|
||||
}, null, 5000, Timeout.Infinite);
|
||||
}
|
||||
private Timer timer = null;
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Message { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string Category { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public override string ToString()
|
||||
{
|
||||
return string.Format("{0};{1}-{2}", Category, Message);
|
||||
}
|
||||
private void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing)
|
||||
{
|
||||
if (timer != null)
|
||||
{
|
||||
timer.Dispose();
|
||||
timer = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public void Dispose()
|
||||
{
|
||||
Dispose(true);
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,7 +41,7 @@ namespace Bootstrap.DataAccess
|
|||
/// </summary>
|
||||
public string Description { get; set; }
|
||||
/// <summary>
|
||||
/// 获得/设置 用户当前状态 0 表示管理员注册用户 1 表示用户自己注册 2 表示管理员批复 9 表示前台remote validate
|
||||
/// 获得/设置 用户当前状态 0 表示管理员注册用户 1 表示用户自己注册 2 表示管理员批复 3 表示更改个人皮肤 9 表示前台remote validate
|
||||
/// </summary>
|
||||
public int UserStatus { get; set; }
|
||||
/// <summary>
|
||||
|
|
|
@ -145,6 +145,7 @@ namespace Bootstrap.DataAccess
|
|||
}
|
||||
CacheCleanUtility.ClearCache(userIds: p.Id == 0 ? string.Empty : p.Id.ToString());
|
||||
ret = true;
|
||||
if (p.UserStatus == 1) NotificationHelper.MessagePool.Add(new MessageBody() { Category = "Users", Message = string.Format("{0}-{1}", p.UserName, p.Description) });
|
||||
}
|
||||
catch (DbException ex)
|
||||
{
|
||||
|
@ -326,7 +327,35 @@ namespace Bootstrap.DataAccess
|
|||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@userName", userName));
|
||||
DBAccessManager.SqlDBAccess.ExecuteNonQuery(cmd);
|
||||
string key = string.Format("{0}-{1}", RetrieveUsersByNameDataKey, userName);
|
||||
CacheManager.Clear(k => key == k);
|
||||
CacheCleanUtility.ClearCache(key);
|
||||
ret = true;
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
ExceptionManager.Publish(ex);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
/// <summary>
|
||||
/// 根据用户名更改用户皮肤
|
||||
/// </summary>
|
||||
/// <param name="userName"></param>
|
||||
/// <param name="cssName"></param>
|
||||
/// <returns></returns>
|
||||
public static bool SaveUserCssByName(string userName, string cssName)
|
||||
{
|
||||
bool ret = false;
|
||||
try
|
||||
{
|
||||
string sql = "Update Users set Css = @cssName where UserName = @userName";
|
||||
using (DbCommand cmd = DBAccessManager.SqlDBAccess.CreateCommand(CommandType.Text, sql))
|
||||
{
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@cssName", DBAccess.ToDBValue(cssName)));
|
||||
cmd.Parameters.Add(DBAccessManager.SqlDBAccess.CreateParameter("@userName", userName));
|
||||
DBAccessManager.SqlDBAccess.ExecuteNonQuery(cmd);
|
||||
string key = string.Format("{0}-{1}", RetrieveUsersByNameDataKey, userName);
|
||||
CacheCleanUtility.ClearCache(key);
|
||||
ret = true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,9 +25,8 @@ INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'消息状
|
|||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'消息标签', N'一般', N'0', 0)
|
||||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'消息标签', N'紧要', N'1', 0)
|
||||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'头像地址', N'头像路径', N'~/Content/images/uploader/', 0)
|
||||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'网站样式', N'默认样式', N'site.css', 0)
|
||||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'网站样式', N'蓝色样式', N'blue.css', 0)
|
||||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'当前样式', N'使用样式', N'site.css', 0)
|
||||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'当前样式', N'使用样式', N'blue.css', 0)
|
||||
INSERT [dbo].[Dicts] ([Category], [Name], [Code], [Define]) VALUES (N'网站设置', N'前台首页', N'~/Home/Index', 0)
|
||||
|
||||
DELETE FROM Navigations
|
||||
|
|
|
@ -29,6 +29,7 @@ CREATE TABLE [dbo].[Users](
|
|||
[RejectedTime] [datetime] NULL,
|
||||
[RejectedReason] [nvarchar](50) NULL,
|
||||
[Icon] [varchar](50) NOT NULL,
|
||||
[Css] [varchar](50) NULL,
|
||||
CONSTRAINT [PK_Users] PRIMARY KEY CLUSTERED
|
||||
(
|
||||
[ID] ASC
|
||||
|
@ -258,8 +259,8 @@ CREATE TABLE [dbo].[Exceptions](
|
|||
[ID] [int] IDENTITY(1,1) NOT NULL,
|
||||
[AppDomainName] [varchar](50) NOT NULL,
|
||||
[ErrorPage] [varchar](50) NOT NULL,
|
||||
[UserID] [varchar](50) NOT NULL,
|
||||
[UserIp] [varchar](15) NOT NULL,
|
||||
[UserID] [varchar](50) NULL,
|
||||
[UserIp] [varchar](15) NULL,
|
||||
[ExceptionType] [nvarchar](max) NOT NULL,
|
||||
[Message] [nvarchar](max) NOT NULL,
|
||||
[StackTrace] [nvarchar](max) NULL,
|
||||
|
|
Loading…
Reference in New Issue