Commit 2de48d50 authored by sgjj's avatar sgjj
Browse files

更新资源文件

parent 241a1809
body {
margin: 0;
padding: 0;
background: #eee !important;
}
a:link,a:visited,a:active{text-decoration: none; color:#409EFF;}
.ms-container {
margin: 12px;
height: 100%;
padding: 14px 14px 0 14px;
background: #fff;
}
.ms-header {
padding: 10px;
margin: 0;
border-bottom: 1px solid #ddd;
background: #fff;
height: 50px
}
.ms-pagination {
padding: 20px 0;
text-align: right;
}
.ms-fr {
float: right;
}
.ms-tr {
text-align: right;
}
.el-button+.el-button {
margin-left: 0
}
.ms-select{
display: block;
}
.ms-datetimerange{
width: 100% !important;
}
#index .ms-search{
background: #fff;
}
#index .ms-search .ms-search-footer{
line-height: 60px;
text-align: center;
}
#index .ms-table-pagination {
height: calc(100% - 75px);
}
#myPageTop {
width: 252px;
}
#myPageTop input {
width: 242px;
}
#form .iconfont {
font-size: 12px;
margin-right: 5px;
}
#form .ms-container{
height:calc(100vh - 74px);
}
#index .ms-container{
height: calc(100vh - 74px);
}
[v-cloak]{
display: none;
}
\ No newline at end of file
/*
*这里的值严格按照UI设计图标注值来进行设置
*/
/*
*颜色
*/
/*
*页面的边距
*/
/*
*字体
*/
/*
*头像
*/
/*
* 按钮
*/
/*
*对常见的多行样式进行了方法封装,方便调用,加快开发效率
*/
html,
body {
min-height: 100vh;
width: 100vw;
background-color: #eee;
margin: 0;
display: flex;
font-weight: initial !important;
font-size: 14px !important;
color: #333 !important;
}
html *,
body * {
text-decoration: none !important;
font-family: Verdana, Arial, Helvetica, sans-serif;
box-sizing: border-box;
}
.ms-ellipsis {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
display: block;
}
.ms-align-center {
display: flex;
align-items: center;
}
input::-webkit-input-placeholder,
textarea::-webkit-input-placeholder {
font-weight: initial;
font-size: 12px;
color: #999;
resize: none;
}
*::-webkit-scrollbar {
width: 8px;
height: 8px;
}
/*定义滚动条轨道 内阴影+圆角*/
*::-webkit-scrollbar-track {
border-radius: 10px;
/*滚动条的背景区域的圆角*/
background-color: #eee;
/*滚动条的背景颜色*/
}
/*定义滑块 内阴影+圆角*/
*::-webkit-scrollbar-thumb {
border-radius: 10px;
/*滚动条的圆角*/
background-color: #e6e6e6;
/*滚动条的背景颜色*/
}
.ms-container {
margin: 12px;
height: calc(100% - 24px);
padding: 14px;
background: #fff;
}
.ms-header {
padding: 10px;
margin: 0;
border-bottom: 1px solid #ddd;
background: #fff;
height: 50px;
}
.ms-header button {
height: 30px;
}
.ms-pagination {
padding: 20px 0;
text-align: right;
}
.ms-fr {
float: right;
}
.ms-tr {
text-align: right;
}
.ms-weixin-content {
width: calc(100% - 140px);
}
.ms-weixin-dialog .el-dialog__header {
height: 55px;
box-sizing: border-box;
padding: 10px 10px 25px 10px;
border-bottom: 1px solid #e6e6e6;
}
.ms-weixin-dialog .el-dialog__header .el-dialog__title {
font-weight: bold;
font-size: 14px;
color: #333;
}
.ms-weixin-dialog .el-dialog__footer {
border-top: 1px solid #e6e6e6;
padding: 15px !important;
}
.ms-hover {
cursor: pointer;
}
.ms-hover:hover {
color: #0099ff;
background: #fff;
border-color: #0099ff;
}
.ms-header-select {
font-size: 0;
}
.ms-header-select > .el-select:nth-of-type(2) {
margin: 0 10px;
}
.el-submenu .el-menu-item.is-active {
border-radius: 4px;
}
.el-card,
.el-message {
border-radius: 0 !important;
}
.sortable-ghost {
opacity: .3;
background: #ccc !important;
border-color: transparent !important;
color: transparent !important;
}
.sortable-ghost * {
background: #ccc !important;
border-color: transparent !important;
color: transparent !important;
}
.index {
width: 100%;
display: flex;
}
.ms-admin-header {
display: flex;
padding: 0;
background-color: #0099ff;
height: 50px !important;
}
.ms-admin-header .ms-admin-header-menu {
background-color: #0099ff;
border-bottom: none;
position: relative;
}
.ms-admin-header .ms-admin-header-menu > .ms-admin-menu-item > *,
.ms-admin-header .ms-admin-header-menu > .ms-admin-menu-item {
height: 50px !important;
line-height: 50px !important;
background-color: #0099ff !important;
color: rgba(255, 255, 255, 0.65) !important;
border-bottom: none !important;
font-size: 1em;
}
.ms-admin-header .ms-admin-header-menu > .ms-admin-menu-item > *:hover,
.ms-admin-header .ms-admin-header-menu > .ms-admin-menu-item:hover {
color: #fff !important;
}
.ms-admin-header .ms-admin-header-menu > .ms-admin-menu-item > *.is-active,
.ms-admin-header .ms-admin-header-menu > .ms-admin-menu-item.is-active {
color: #fff !important;
}
.ms-admin-header .ms-admin-header-menu .ms-admin-shortcut-menu {
padding: 0;
user-select: none;
outline: none;
width: 100%;
min-width: 500px;
min-height: 200px;
background-color: #fff !important;
height: auto;
flex-wrap: wrap;
position: absolute;
right: 0;
top: 0;
z-index: 9;
background: #ffffff;
border: 1px solid #e6e6e6;
box-shadow: 2px 3px 5px 0.1px rgba(0, 0, 0, 0.1);
}
.ms-admin-header .ms-admin-header-menu .ms-admin-shortcut-menu > li {
margin: 0;
padding: 0 20px;
text-align: left;
display: -webkit-inline-box;
display: inline-block;
height: 50px;
line-height: 50px;
font-weight: normal;
font-size: 14px;
color: #333;
}
.ms-admin-header .ms-admin-header-menu .ms-admin-shortcut-menu > li:hover {
cursor: pointer;
color: #0099ff;
}
.ms-admin-header .ms-admin-header-menu .ms-admin-shortcut-menu i {
position: absolute;
top: 18px;
right: 19px;
font-weight: normal;
font-size: 14px;
color: #333;
}
.ms-admin-header .ms-admin-header-menu .ms-admin-shortcut-menu i:hover {
cursor: pointer;
}
.ms-admin-logo {
min-width: 200px;
width: 200px;
display: flex;
align-items: center;
overflow: hidden;
}
.ms-admin-logo > img {
padding: 20px 0 20px 20px;
width: 80px;
}
.ms-admin-logo > div {
display: flex;
align-items: center;
}
.ms-admin-logo > div img {
margin-top: -10px;
margin-left: 3px;
}
.ms-admin-logo > div span {
margin-top: -7px;
position: absolute;
margin-left: 6px;
font-size: 12px;
}
.ms-admin-logo .iconfont {
color: #fff;
margin-left: auto;
margin-right: 20px;
cursor: pointer;
}
.ms-admin-mstore {
margin-left: auto;
min-width: 200px;
display: flex;
align-items: center;
justify-content: flex-end;
padding: 0;
line-height: 1;
}
.ms-admin-mstore .ms-admin-people-head {
width: 30px !important;
height: 30px !important;
margin-right: 10px;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
background: #fff;
color: #0099ff;
}
.ms-admin-mstore .ms-admin-mstore-icon {
min-width: 50px;
width: 50px;
height: 50px;
background-color: #0080FF;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
}
.ms-admin-mstore .ms-admin-mstore-icon span {
border-radius: 50%;
font-weight: initial;
font-size: 12px;
color: #fff;
background: #f00;
position: absolute;
width: 1.2em;
height: 1.2em;
display: flex;
align-items: center;
justify-content: center;
top: 0.6em;
right: 0.6em;
z-index: 2;
}
.ms-admin-mstore .ms-admin-mstore-icon .iconfont {
color: #fff;
animation: rubberBand 1.4s 1s both infinite;
font-size: 1.5em;
}
.ms-admin-login {
display: flex;
align-items: center;
}
.ms-admin-login > span {
width: 130px;
padding: 0 15px;
height: 50px;
display: flex;
align-items: center;
cursor: pointer;
outline: none;
}
.ms-admin-login > span img {
border-radius: 50%;
width: 20px;
height: 20px;
margin-right: 8px;
}
.ms-admin-login > span span {
color: #fff;
}
.ms-admin-login .active {
background: #fff;
}
.ms-admin-login .active .ms-admin-people-head {
background: #0099ff;
color: #fff;
}
.ms-admin-login .active span {
color: #333;
}
.ms-admin-login-down {
width: 130px;
padding: 0 15px;
border: none;
margin: 0 !important;
padding: 0 !important;
border-radius: 0;
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.1);
}
.ms-admin-login-down > .popper__arrow {
display: none;
}
.ms-admin-menu-aside {
width: 200px !important;
height: 100%;
position: relative;
overflow: visible;
}
.ms-admin-menu-aside .ms-admin-menu {
width: 200px;
height: 100%;
position: relative;
}
.ms-admin-menu-aside .ms-admin-menu .el-menu--inline .is-active {
border-left: 2px solid #0099ff;
}
.ms-admin-menu-aside .ms-admin-menu .ms-admin-icon {
font-weight: initial;
font-size: 1.5em;
color: #999;
}
.ms-admin-menu-aside .ms-menu-expand {
transform: rotate(270deg);
position: absolute;
right: -34px;
top: 50%;
z-index: 999;
cursor: pointer;
display: flex;
flex-direction: column;
}
.ms-admin-menu-aside .ms-menu-expand i {
font-weight: initial;
font-size: 14px;
color: #333;
position: absolute;
transform: rotate(90deg);
top: 5px;
right: 43%;
}
.ms-admin-menu-aside .ms-menu-expand::before {
border-color: transparent transparent #eee;
border-style: none solid solid;
border-width: 0 30px 22px;
content: "";
display: block;
height: 0;
left: -10px;
width: 30px;
}
.ms-admin-menu-aside .ms-menu-expand {
transition: right .3s;
}
.ms-admin-menu-aside .ms-menu-expand-active {
transform: rotate(90deg);
right: -56px;
}
.ms-admin-menu-aside .ms-admin-menu-active {
width: 60px;
height: 100%;
}
.ms-admin-menu-aside-active {
width: 60px !important;
}
.ms-admin-container {
height: calc(100vh - 60px);
}
.ms-admin-container > .ms-admin-main {
padding: 0;
background-color: #fff;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs {
height: 100%;
display: flex;
flex-direction: column;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__content {
height: 100%;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__content .el-tab-pane {
height: 100%;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__header {
background: #fafafa;
margin-bottom: 0;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__header .el-tabs__nav-scroll .el-tabs__nav {
border-left: none;
border-radius: 0;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .ms-admin-refresh {
float: right;
width: 40px;
height: 40px;
text-align: center;
border-left: 1px solid #e6e6e6;
cursor: pointer;
position: relative;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .ms-admin-refresh::before {
position: absolute;
left: 34%;
top: 50%;
transform: translateY(-50%);
color: #999;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__nav-next,
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__nav-prev {
width: 40px;
height: 40px;
display: flex;
justify-content: center;
align-items: center;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__nav-next {
border-left: 1px solid #e6e6e6;
}
.ms-admin-container > .ms-admin-main .ms-admin-tabs .el-tabs__nav-prev {
border-right: 1px solid #e6e6e6;
}
.ms-admin-container > .ms-admin-main iframe {
width: 100%;
height: 100%;
border: none !important;
}
@keyframes rubberBand {
0 {
-webkit-transform: scale3d(1, 1, 1);
transform: scale3d(1, 1, 1);
}
10% {
-webkit-transform: scale3d(1.25, 0.75, 1);
transform: scale3d(1.25, 0.75, 1);
}
20% {
-webkit-transform: scale3d(0.75, 1.25, 1);
transform: scale3d(0.75, 1.25, 1);
}
30% {
-webkit-transform: scale3d(1.15, 0.85, 1);
transform: scale3d(1.15, 0.85, 1);
}
40% {
-webkit-transform: scale3d(0.95, 1.05, 1);
transform: scale3d(0.95, 1.05, 1);
}
50% {
-webkit-transform: scale3d(1.05, 0.95, 1);
transform: scale3d(1.05, 0.95, 1);
}
51% {
-webkit-transform: scale3d(1, 1, 1);
transform: scale3d(1, 1, 1);
}
}
.el-scrollbar__wrap{overflow-x:hidden;}
.el-scrollbar {
position: static;
}
[v-cloak] {
display: none;
}
\ No newline at end of file
/*
*这里的值严格按照UI设计图标注值来进行设置
*/
/*
*颜色
*/
/*
*页面的边距
*/
/*
*字体
*/
/*
*头像
*/
/*
* 按钮
*/
/*
*对常见的多行样式进行了方法封装,方便调用,加快开发效率
*/
html,
body {
min-height: 100vh;
width: 100vw;
background-color: #eee;
margin: 0;
display: flex;
font-weight: initial !important;
font-size: 14px !important;
color: #333 !important;
}
html *,
body * {
text-decoration: none !important;
font-family: Verdana, Arial, Helvetica, sans-serif;
box-sizing: border-box;
}
.ms-ellipsis {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
display: block;
}
.ms-align-center {
display: flex;
align-items: center;
}
input::-webkit-input-placeholder,
textarea::-webkit-input-placeholder {
font-weight: initial;
font-size: 12px;
color: #aaa;
resize: none;
}
*::-webkit-scrollbar {
width: 8px;
height: 8px;
}
/*定义滚动条轨道 内阴影+圆角*/
*::-webkit-scrollbar-track {
border-radius: 10px;
/*滚动条的背景区域的圆角*/
background-color: #eee;
/*滚动条的背景颜色*/
}
/*定义滑块 内阴影+圆角*/
*::-webkit-scrollbar-thumb {
border-radius: 10px;
/*滚动条的圆角*/
background-color: #ddd;
/*滚动条的背景颜色*/
}
.ms-container {
margin: 12px;
height: calc(100% - 24px);
padding: 14px 14px 0 14px;
background: #fff;
}
.ms-header {
padding: 10px;
margin: 0;
border-bottom: 1px solid #ddd;
background: #fff;
height: 50px;
}
.ms-pagination {
padding: 20px 0;
text-align: right;
}
.ms-fr {
float: right;
}
.ms-tr {
text-align: right;
}
.ms-weixin-content {
width: calc(100% - 140px);
}
.ms-weixin-dialog .el-dialog__header {
height: 55px;
box-sizing: border-box;
padding: 10px 10px 25px 10px;
border-bottom: 1px solid #ddd;
}
.ms-weixin-dialog .el-dialog__header .el-dialog__title {
font-weight: bold;
font-size: 14px;
color: #333;
}
.ms-weixin-dialog .el-dialog__footer {
border-top: 1px solid #ddd;
padding: 15px !important;
}
.login {
width: 100vw;
height: 100vh;
}
.login .ms-admin-login-container {
height: 100%;
background: url('../images/login-bg.jpg') center no-repeat;
background-size: cover;
}
.login .ms-admin-login-container .ms-admin-login-main {
display: flex;
justify-content: center;
align-items: center;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp {
display: flex;
justify-content: center;
align-items: center;
width: 680px;
height: 320px;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp > img {
flex: 1;
display: inline-block;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form {
flex: 1;
height: 320px;
background: #fff;
padding: 20px 54px;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form h1 {
line-height: 1;
font-weight: initial;
font-size: 12px;
color: #999999;
margin: 0 0 20px 0;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form h1 span {
font-weight: initial;
font-size: 16px;
color: #0099ff;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item {
margin-bottom: 20px;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item > div {
margin-left: 0 !important;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item .el-form-item__content,
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item .el-input,
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item input {
height: 34px !important;
line-height: 34px !important;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-code .el-form-item__content {
display: flex;
justify-content: space-between;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-code .el-form-item__content .el-input__inner,
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-code .el-form-item__content .el-input {
width: 110px;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-code .el-form-item__content > img {
width: 66px;
height: 34px;
margin: 0 6px;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-code .el-form-item__content p {
display: flex;
justify-content: space-between;
line-height: 1;
flex-direction: column;
margin: 0;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-code .el-form-item__content p span:nth-of-type(1) {
font-weight: initial;
font-size: 10px;
color: #999999;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-code .el-form-item__content p span:nth-of-type(2) {
font-weight: initial;
font-size: 10px;
color: #0099ff;
cursor: pointer;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-checkout .el-form-item__content,
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-checkout .el-input,
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-form-item-checkout input {
height: auto !important;
line-height: 1px !important;
}
.login .ms-admin-login-container .ms-admin-login-main .ms-admin-login-warp .ms-admin-login-form .ms-admin-login-btn {
width: 100%;
height: 34px;
line-height: 5px;
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/**
* 上传js
* 官方插件文档:https://www.plupload.com
* 参数方法文档:https://www.cnblogs.com/2050/p/3913184.html
*/
(function() {
// 默认支持上传的文件类型
var mimeTypes = {
"image": {
title: "Image files",
extensions: "jpg,JPG,jpeg,PNG,gif,png"
},
"file": {
title: "Zip files",
extensions: "ZIP,zip,DOC,doc,docx,xls,XLS,xlsx,RAR,rar"
},
"video": {
title: "video files",
extensions: "MP3,MP4"
},
"all": {
title: "all files",
extensions: "jpg,JPG,jpeg,PNG,gif,png,ZIP,zip,DOC,doc,docx,xls,XLS,xlsx,RAR,rar"
}
};
/**
* 文件上传
* id: id属性
* {
* url:"", //(可选)默认ms.base + "/file/upload.do"
* mime_types:"image", //(可选)默认图片,支持image、file、video、all(表示包含前三种),也可以设置allowedFile参数覆盖
* allowedFile:""//(可选)自定义上传文件后缀例如:jpg,gif
* max_file_size:"1mb", //(可选)默认1mb,单位kb,mb,gb,tb,注意后端ms.properties文件也有配置上传大小,优先上传控件大小
* multi_selection:false, //(可选)默认单文件
* uploadPath:"", //(可选)默认上传upload文件夹下面(如果非upload,需要设置uploadFloderPath参数)对应的站点下面,例如uload/1/xxxxx.jpg
* uploadFloderPath:"", //(可选)自定义上传文件夹路径,最终文件路径格式 uploadFloderPath/uploadPath/xxxxxx.jpg,注意这里的uploadPath已经没有了upload文件夹与站点id
* diyPath:"", //(可选)自定义上传文件夹路径,可以定义盘符路径
* isRename:true,//(可选)文件重命名,默认根据时间命名
* fileFiltered:function //每次选择一个文件都会触发
* filesAdded:function //每次选择好文件后都会触发
* beforeUpload:function //上传文件之前触发,确认上传 业务的情况下有用
* uploadProgress:function //处理进度条
* fileUploaded:function //(必填)上传成功返回,主要会用到第三个参数的response,这个值是上传成功后返回的数据
* }
*/
function upload(id, cfg) {
var uploadCfg = {
url: basePath+"/file/upload.do",
mime_types: mimeTypes["image"],
max_file_size: "1mb",
multi_selection: false,
uploadPath: "",
diyPath:"",
uploadFloderPath: "",
chunk: "",
chunks: "",
prevent_duplicates: true,
isRename: true,
fileFiltered: function(uploader, file) {},
filesAdded: function(uploader, files) {},
beforeUpload: function(uploader, file) {},
uploadProgress: function(uploader, file) {},
fileUploaded: function(uploader, file, responseObject) {},
error: function(uploader, errObject) {
if (errObject.code == -600) {
$('.ms-notifications').offset({top:43}).notify({
type:'warning',
message: { text:errObject.file.name + "文件超过" +
uploadCfg.max_file_size + "大小" }
}).show();
} else if (errObject.code == -601) {
$('.ms-notifications').offset({top:43}).notify({
type:'warning',
message: { text:errObject.file.name + "格式错误" }
}).show();
} else if (errObject.code == -700) {
$('.ms-notifications').offset({top:43}).notify({
type:'warning',
message: { text:errObject.file.name + "格式错误"}
}).show();
} else if (errObject.code == -300) {
$('.ms-notifications').offset({top:43}).notify({
type:'warning',
message: { text:errObject.file.name + "发生磁盘读写错误时的错误代码,例如本地上某个文件不可读"}
}).show();
} else if (errObject.code == -602) {
$('.ms-notifications').offset({top:43}).notify({
type:'warning',
message: { text:errObject.file.name + "文件已上传过,不能重复上传。"}
}).show();
} else if (errObject.code == -702) {
$('.ms-notifications').offset({top:43}).notify({
type:'warning',
message: { text:errObject.file.name + "文件网页上传不支持,太大的文件请通过其他途径上传。"}
}).show();
} else {
$('.ms-notifications').offset({top:43}).notify({
type:'warning',
message: { text:errObject.code + errObject.file.name}
}).show();
}
},
};
var multipart_params = {}; // 上传表单参数
multipart_params.maxSize = calculationMaxSize();
multipart_params.allowedFile = uploadCfg.mime_types.extensions;
// 判断cfg是否为json格式,不是则将默认参数传给cfg
if (cfg != undefined && validator.isJSON(JSON.stringify(cfg))) {
// 重新定义后台上传路径
if (cfg.url != undefined && cfg.url != "") {
uploadCfg.url = cfg.url;
}
// 允许上传的后缀
if (cfg.allowedFile != undefined && cfg.allowedFile != "") {
uploadCfg.mime_types =
{
title: "all files",
extensions: cfg.allowedFile
};
multipart_params.allowedFile = cfg.allowedFile;
}
//组织后台需要的参数
if (cfg.max_file_size != undefined && cfg.max_file_size != "") {
uploadCfg.max_file_size = cfg.max_file_size;
multipart_params.maxSize = calculationMaxSize();
}
if (cfg.path != undefined && cfg.path != "") {
uploadCfg.uploadPath = cfg.path;
multipart_params.uploadPath = cfg.path;
}
if (cfg.diyPath != undefined && cfg.diyPath != "") {
uploadCfg.diyPath = cfg.diyPath;
multipart_params.diyPath = cfg.diyPath;
}
if (cfg.uploadFloderPath != undefined && cfg.uploadFloderPath != "") {
uploadCfg.uploadFloderPath = cfg.uploadFloderPath;
multipart_params.uploadFloderPath = cfg.uploadFloderPath;
}
if (cfg.chunk != undefined && cfg.chunk != "") {
multipart_params.chunk = cfg.chunk;
}
if (cfg.chunks != undefined && cfg.chunks != "") {
multipart_params.chunks = cfg.chunks;
}
if (cfg.name != undefined && cfg.name != "") {
multipart_params.name = cfg.name;
}
if (cfg.isRename != undefined) {
multipart_params.isRename = cfg.isRename;
}
if (cfg.multi_selection != undefined ) {
uploadCfg.multi_selection = cfg.multi_selection;
}
if (cfg.prevent_duplicates != undefined) {
uploadCfg.prevent_duplicates = cfg.prevent_duplicates;
}
//回调事件
if (cfg.fileUploaded != undefined && cfg.fileUploaded != "") {
uploadCfg.fileUploaded = cfg.fileUploaded;
}
if (cfg.filesAdded != undefined && cfg.filesAdded != "") {
uploadCfg.filesAdded = cfg.filesAdded;
}
if (cfg.fileFiltered != undefined && cfg.fileFiltered != "") {
uploadCfg.fileFiltered = cfg.fileFiltered;
}
if (cfg.beforeUpload != undefined && cfg.beforeUpload != "") {
uploadCfg.beforeUpload = cfg.beforeUpload;
}
if (cfg.uploadProgress != undefined && cfg.uploadProgress != "") {
uploadCfg.uploadProgress = cfg.uploadProgress;
}
if (cfg.error != undefined && cfg.error != "") {
uploadCfg.error = cfg.error;
}
}
// 实例化一个plupload上传对象
var uploader = new plupload.Uploader({
browse_button: id, // 预览按钮元素
url: uploadCfg.url, // 上传地址
flash_swf_url: 'js/Moxie.swf',
silverlight_xap_url: 'js/Moxie.xap',
multi_selection: uploadCfg.multi_selection, // 禁止浏览框多选
multipart_params: multipart_params,
filters: { // 文件类型 大小设置,对不同场景的文件上传配置此参数
mime_types: [uploadCfg.mime_types],
max_file_size: uploadCfg.max_file_size, // 最大只能上传400kb的文件
prevent_duplicates: uploadCfg.prevent_duplicates //布尔类型
// 不允许选取重复文件
},
});
uploader.init();
/**
* 选择了多少文件就会触发多少次
*uploader为当前的plupload实例对象,file为触发此事件的文件对象
*/
uploader.bind('FileFiltered', function(uploader, file) {
eval(uploadCfg.fileFiltered(uploader, file));
});
/**
* 当文件添加到上传队列后触发
* uploader为当前的plupload实例对象,files为一个数组,里面的元素为本次添加到上传队列里的文件对象
* 每一次选择文件都会触发,不管选择多个文件还是单个文件都只会触发一次
*/
uploader.bind('FilesAdded', function(uploader, files) {
eval(uploadCfg.filesAdded(uploader, files));
});
/**
* 当队列中的某一个文件正要开始上传前触发
* uploader为当前的plupload实例对象,file为触发此事件的文件对象
*/
uploader.bind('BeforeUpload', function(uploader, file) {
eval(uploadCfg.beforeUpload(uploader, file));
});
/**
* 会在文件上传过程中不断触发,可以用此事件来显示上传进度
* uploader为当前的plupload实例对象,file为触发此事件的文件对象
*/
uploader.bind('UploadProgress', function(uploader, file) {
eval(uploadCfg.uploadProgress(uploader, file));
});
/**
* 当队列中的某一个文件上传完成后触发监听函数参数:(uploader,file,responseObject)
* uploader为当前的plupload实例对象,
* file为触发此事件的文件对象,
* responseObject为服务器返回的信息对象,它有以下3个属性:
* response:服务器返回的文本
* responseHeaders:服务器返回的头信息
* status:服务器返回的http状态码,比如200
*/
uploader.bind('FileUploaded', function(uploader, file, responseObject) {
eval(uploadCfg.fileUploaded(uploader, file, responseObject));
});
/**
* 当发生错误时触发监听函数参数:(uploader,errObject)
* uploader为当前的plupload实例对象,
* errObject为错误对象,它至少包含以下3个属性(因为不同类型的错误,属性可能会不同):
* code:错误代码,具体请参考plupload上定义的表示错误代码的常量属性
* file:与该错误相关的文件对象
* message:错误信息
*/
uploader.bind('Error', function(uploader, errObject) {
eval(uploadCfg.error(uploader, errObject));
});
/**
* 计算后台的上传大小,因为前端上传空间与后端的大小单位不一致
*/
function calculationMaxSize() {
var size = parseInt(uploadCfg.max_file_size);
if (uploadCfg.max_file_size.indexOf("kb") > -1) {
return parseInt(size) / 1024;
} else if (uploadCfg.max_file_size.indexOf("mb") > -1) {
return size;
} else if (uploadCfg.max_file_size.indexOf("gb") > -1) {
return size * 1024;
} else if (uploadCfg.max_file_size.indexOf("tb") > -1) {
return size * 1024 * 1024;
}
}
return uploader;
}
if (ms == undefined) {
ms = {};
}
window.ms.upload = upload;
}());
\ No newline at end of file
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
return cloneData.filter(father => { return cloneData.filter(father => {
let branchArr = cloneData.filter(child => father[id] == child[parentId]); let branchArr = cloneData.filter(child => father[id] == child[parentId]);
branchArr.length > 0 ? father[children] = branchArr : '' branchArr.length > 0 ? father[children] = branchArr : ''
return father[parentId] == 0 // 如果第一层不是parentId=0,请自行修改 return !father[parentId] // 如果第一层不是parentId=0,请自行修改
}) })
} }
......
.ms-upgrader-number,.topDiv{display:none}.ms-text2-hide,.ms-text3-hide,.ms-text8-hide{-webkit-box-orient:vertical}.ms-text-hide,.ms-text2-hide,.ms-text3-hide,.ms-text8-hide{text-overflow:ellipsis}.email-login,.weixin-login{position:absolute;top:15%;left:32%}html{height:100%}::-webkit-scrollbar{width:7px;height:7px}::-webkit-scrollbar-thumb{background-color:rgba(50,50,50,.3)}::-webkit-scrollbar-thumb:hover{background-color:rgba(50,50,50,.6)}::-webkit-scrollbar-track{background-color:rgba(50,50,50,.1)}::-webkit-scrollbar-track:hover{background-color:rgba(50,50,50,.2)}.topDiv{height:125px;width:100%}.ms-text-hide{word-break:keep-all;white-space:nowrap;overflow:hidden}.ms-text2-hide{display:-webkit-box;-webkit-line-clamp:2}.ms-text3-hide{display:-webkit-box;-webkit-line-clamp:3}.ms-text8-hide{display:-webkit-box;-webkit-line-clamp:8}.email-login{width:472px;border:1px solid #eaeaea;padding-top:20px;background:#fff;box-shadow:0 0 15px -5px #888}.email-login form{width:300px;margin:0 auto}.email-login .title{font-size:20px;text-align:center;margin-bottom:15px}.email-login .email-login-tit{margin-right:-15px;margin-left:-15px}.fixed-filter,.fixed-top{background:#fff;position:fixed}#login_container{margin:0 auto;width:472px;background:url(http://static.ming-soft.net/images/scorback.jpg)no-repeat #fcfcfc;text-align:center;padding-top:51px}.small-font{font-size:12px}.padding-clear{padding:0}.pageNav{text-align:right;margin-bottom:30px;padding-right:8px;overflow:hidden}.fixed-top{top:-10px;z-index:1000;left:0;margin-left:-15px;padding-left:15px}.fixed-filter{top:42px;z-index:1000;width:100%;left:0;box-shadow:0 5px 10px #d3d3d3}.mstore-content{overflow:auto;padding:15px;min-width:1100px}.mstore-content .free-font{color:#1E8BDD;font-weight:700}.mstore-content .price-font{color:#FB803C;font-weight:700}.mstore-content .glyphicon-star,.mstore-content .glyphicon-star-empty{color:#fb803c}.mstore-content .glyphicon-heart{color:#d9534f}.mstore-content .carousel{height:240px}.mstore-content .item img{margin:0 auto;max-width:100%}.mstore-content .group-button-active{background-color:#e6e6e6}.mstore-content .mswidth{width:100%}.mstore-content .content-new{margin-top:15px;border:1px solid #ddd;overflow:hidden;border-bottom:0}.mstore-content .content-new .new-upload{width:78%;float:left}.mstore-content .content-new .new-upload .table-title{padding:10px;height:40px;border-bottom:1px solid #ddd;border-right:1px #ddd solid;clear:both;font-weight:700;font-size:18px}.mstore-content .content-new .new-upload ul li{height:260px;border-radius:0;margin:0;border-left:none;border-top:none;float:left;cursor:pointer}.mstore-content .content-new .new-upload ul li .pic{display:block;height:74%;overflow:hidden;margin-bottom:5px}.mstore-content .content-new .new-upload ul li .share-info{min-width:220px;width:80%;float:left}.mstore-content .content-new .new-upload ul li .share-info .share-title{margin:5px 0}.mstore-content .content-new .new-upload ul li .share-user{width:40px;float:right;height:62px;overflow:hidden}.mstore-content .content-new .new-upload ul li .share-user img{width:100%}.mstore-content .content-new .new-upload ul li .share-user p{font-size:12px;line-height:25px}.mstore-content .content-new .order-user-list{width:22%;float:left;overflow:hidden;height:520px}.mstore-content .content-new .order-user-list .list-title{border-bottom:1px solid #ddd;margin:10px;padding-bottom:10px;font-weight:700}.mstore-content .order-user{width:33%;max-width:90px;float:left;height:95px;overflow:hidden;line-height:38px}.mstore-content .order-user p{font-size:12px}.mstore-content .content-people{border:1px solid #ddd;overflow:hidden;border-top:0}.mstore-content .content-people .solve-user-list{width:78%;float:left}.mstore-content .content-people .solve-user-list .table-title{padding:10px;height:40px;border-bottom:1px solid #ddd;border-right:1px #ddd solid;clear:both;font-weight:700;font-size:18px}.mstore-content .content-people .solve-user-list .solve-user-detail{border-radius:0;margin:0;border-left:none;height:295px;border-top:none;border-bottom:none}.mstore-content .content-people .solve-user-list .solve-user-detail .solve-user-head{width:50px;float:left;padding-right:5px}.mstore-content .content-people .solve-user-list .solve-user-detail .solve-user-info{float:left}.mstore-content .content-people .solve-user-list .solve-user-detail .solve-user-info .solve-heart{margin-top:5px}.mstore-content .content-people .solve-user-list .solve-user-detail .solve-descrip{height:60%;overflow:hidden;width:100%;padding:5px;line-height:23px}.mstore-content .content-people .solve-user-list .solve-user-detail .solve-bottom{position:absolute;bottom:10px;right:10px}.mstore-content .content-people .solve-user-list .solve-user-detail .solve-bottom .solve-btn{padding:0 10px}.mstore-content .content-people .download-top{width:22%;float:left}.mstore-content .content-people .download-top .list-title{border-bottom:1px solid #ddd;margin:10px;padding-bottom:10px;font-weight:700}.mstore-content .content-people .download-top .download-info{width:100%;margin-bottom:9px;float:left}.mstore-content .content-people .download-top .download-info .download-head{width:40px;float:left;margin:0 10px}.mstore-content .content-people .download-top .download-info strong{cursor:pointer}.mstore-content .model-all{margin:10px 0}.mstore-content .model-filter{margin-bottom:10px;padding:10px 15px}.mstore-content .nav-pills li{cursor:pointer}.mstore-content .nav-pills li a{padding:1px 20px}.mstore-content .share-detail{padding:0 5px}.mstore-content .share-detail .thumbnail{height:260px;cursor:pointer;margin-bottom:10px}.mstore-content .share-detail .pic{display:block;height:74%;overflow:hidden;margin-bottom:5px}.mstore-content .share-detail .pic .tit{position:absolute;padding:5px;top:5px;right:10px;text-align:center;color:#fff;background:#868686}.mstore-content .share-detail .pic .describe{color:#666;line-height:25px;margin-top:4px;font-size:12px;text-decoration:none}.mstore-content .share-detail .pic .describe:hover,.mstore-content .share-detail .pic:hover{text-decoration:none}.mstore-content .share-detail .share-info{width:70%;float:left}.mstore-content .share-detail .share-info .share-title{margin:5px 0}.mstore-content .share-detail .share-user{width:40px;float:right;height:62px;overflow:hidden}.mstore-content .share-detail .share-user img{width:100%}.mstore-content .share-detail .share-user p{font-size:12px;line-height:25px}.mstore-content .share-detail-user{margin-bottom:10px;overflow:hidden}.mstore-content .share-detail-user img{width:50px;height:50px;margin-right:10px}.mstore-content .read-more{margin-left:20px;color:#fff}.mstore-content .comment-info{border-bottom:1px dotted #ddd;padding-bottom:15px}.mstore-content .comment-info .comment-name{color:#337ab7;font-size:14px;font-weight:700}.mstore-content #detail-comment{max-height:500px;overflow-y:auto}
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment