mirror of
https://github.com/cuiocean/ZY-Player.git
synced 2026-02-14 07:55:27 +08:00
Compare commits
58 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
17be5d45f1 | ||
|
|
f493fcd24e | ||
|
|
d040bc01fc | ||
|
|
6644c97811 | ||
|
|
68960ab5bb | ||
|
|
46de044214 | ||
|
|
0cbf9ca7fb | ||
|
|
6fa40af9bd | ||
|
|
7343f1824a | ||
|
|
3df0665950 | ||
|
|
022b1b28ad | ||
|
|
55d1740354 | ||
|
|
9d71991103 | ||
|
|
361e24ecad | ||
|
|
53f80d2cce | ||
|
|
880dd9ff35 | ||
|
|
42c89120da | ||
|
|
d990aa92b0 | ||
|
|
e117564ecb | ||
|
|
99592e3fcb | ||
|
|
adc8fd4329 | ||
|
|
579caddaeb | ||
|
|
1d5344f292 | ||
|
|
22dc74ea3a | ||
|
|
72d7c91540 | ||
|
|
ef874d1831 | ||
|
|
bb9a8ca65d | ||
|
|
747abf3b26 | ||
|
|
1078cf3c63 | ||
|
|
22b877b0fb | ||
|
|
34e6b8bd08 | ||
|
|
4d039e9a63 | ||
|
|
16f3954959 | ||
|
|
17845e6ab4 | ||
|
|
292f932130 | ||
|
|
127ef9ad43 | ||
|
|
11f0ae27fd | ||
|
|
2599343943 | ||
|
|
0fb5903416 | ||
|
|
ce89720c55 | ||
|
|
8ff7fa588a | ||
|
|
8d5bbedfd8 | ||
|
|
713e0affae | ||
|
|
0f55f3b2ea | ||
|
|
c98e41201d | ||
|
|
2cfd31806d | ||
|
|
d54dab4e90 | ||
|
|
2af85fbfd1 | ||
|
|
15c542db82 | ||
|
|
1a3ccaa3ba | ||
|
|
3d01fd045f | ||
|
|
f6636a7864 | ||
|
|
dd108d3b09 | ||
|
|
0b24ded61f | ||
|
|
d21494cf86 | ||
|
|
76add8f87a | ||
|
|
5a115700e3 | ||
|
|
16e8ef2c4a |
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "zy",
|
||||
"version": "2.5.8",
|
||||
"version": "2.6.2",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"serve": "vue-cli-service serve",
|
||||
@@ -37,6 +37,7 @@
|
||||
"randomstring": "^1.1.5",
|
||||
"v-fit-columns": "^0.2.0",
|
||||
"vue": "^2.6.12",
|
||||
"vue-clickaway": "^2.2.2",
|
||||
"vue-infinite-loading": "^2.4.5",
|
||||
"vue-waterfall-plugin": "^1.1.0",
|
||||
"vuedraggable": "^2.24.2",
|
||||
|
||||
@@ -209,47 +209,76 @@
|
||||
width: calc(100% - 100px);
|
||||
height: calc(100% - 60px);
|
||||
border-radius: 5px;
|
||||
.listpage-content{
|
||||
height: 100%;
|
||||
position: relative;
|
||||
font-size: 1rem;
|
||||
.listpage-header{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
.listpage-header{
|
||||
height: 60px;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
z-index: 10;
|
||||
.header-box{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding-left: 50px;
|
||||
padding-right: 50px;
|
||||
.el-button{
|
||||
font-size: 1rem;
|
||||
border: none;
|
||||
&:hover{
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
.is-loading:before {
|
||||
background-color: none !important;
|
||||
}
|
||||
.el-input{
|
||||
width: 200px;
|
||||
}
|
||||
.el-button{
|
||||
font-size: 1rem;
|
||||
border: none;
|
||||
&:hover{
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
height: calc(100% - 40px);
|
||||
overflow-y: auto;
|
||||
.is-loading:before {
|
||||
background-color: none !important;
|
||||
}
|
||||
.el-input{
|
||||
font-size: 1rem;
|
||||
width: 200px;
|
||||
}
|
||||
.el-select-dropdown__item{
|
||||
font-size: 1rem;
|
||||
}
|
||||
.el-select{
|
||||
margin-left: 20px;
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
height: calc(100% - 60px);
|
||||
overflow-y: auto;
|
||||
position: relative;
|
||||
font-size: 1rem;
|
||||
&::-webkit-scrollbar{
|
||||
width: 5px;
|
||||
height: 1px;
|
||||
}
|
||||
&::-webkit-scrollbar-thumb {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
.show-table{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
.el-table::before{
|
||||
height: 0px;
|
||||
}
|
||||
.el-table{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
overflow-y: auto;
|
||||
overflow: hidden;
|
||||
font-size: 1rem;
|
||||
}
|
||||
.el-table__body-wrapper{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
&::-webkit-scrollbar{
|
||||
width: 10px;
|
||||
width: 5px;
|
||||
height: 1px;
|
||||
}
|
||||
&::-webkit-scrollbar-thumb {
|
||||
@@ -277,8 +306,98 @@
|
||||
font-size: 1rem;
|
||||
}
|
||||
}
|
||||
.show-picture{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
padding: 10px;
|
||||
.card{
|
||||
border-radius: 6px;
|
||||
overflow: hidden;
|
||||
.img{
|
||||
position: relative;
|
||||
min-height: 40px;
|
||||
img{
|
||||
width: 100%;
|
||||
height: auto;
|
||||
cursor: pointer;
|
||||
}
|
||||
.rate{
|
||||
position: absolute;
|
||||
top: 3%;
|
||||
right: -40%;
|
||||
width: 100%;
|
||||
background-color: #111111aa;
|
||||
color:#2f90b9;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
font-size: 14px;
|
||||
font-weight: bolder;
|
||||
text-align: center;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
.update{
|
||||
position: absolute;
|
||||
top: 5%;
|
||||
left: -40%;
|
||||
width: 100%;
|
||||
background-color: #68b88e;
|
||||
color: #cdcdcd;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
font-size: 14px;
|
||||
text-align: center;
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
.operate{
|
||||
display: none;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
background-color: #111111aa;
|
||||
width: 100%;
|
||||
font-size: 13px;
|
||||
.operate-wrap{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.o-play, .o-star, .o-share{
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 80px;
|
||||
height: 36px;
|
||||
text-align: center;
|
||||
line-height: 36px;
|
||||
color: #cdcdcd;
|
||||
&:hover{
|
||||
background-color: #111;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.name{
|
||||
font-size: 16px;
|
||||
padding: 10px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
cursor: pointer;
|
||||
}
|
||||
.info{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 12px;
|
||||
padding: 10px;
|
||||
}
|
||||
&:hover{
|
||||
.operate{
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// loading
|
||||
.zy-loading{
|
||||
width: 100%;
|
||||
|
||||
@@ -170,23 +170,6 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.pictureView{
|
||||
.body{
|
||||
background-color: var(--d-bgc-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
.show-img{
|
||||
color: var(--d-fc-1);
|
||||
.card{
|
||||
background-color: var(--d-bgc-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--d-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.play{
|
||||
background-color: var(--d-bgc-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
@@ -351,11 +334,11 @@
|
||||
background-color: var(--d-bgc-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
}
|
||||
// Page of list using el-table
|
||||
|
||||
// Page of list using table and picture
|
||||
.listpage{
|
||||
color: var(--d-fc-2);
|
||||
.listpage-content{
|
||||
.listpage-header{
|
||||
.listpage-header{
|
||||
border-bottom-color: var(--d-c-3);
|
||||
.btn{
|
||||
&:hover{
|
||||
@@ -376,24 +359,50 @@
|
||||
color: var(--d-fc-2);
|
||||
}
|
||||
}
|
||||
.el-select-dropdown{
|
||||
color: var(--d-fc-1);
|
||||
border: none;
|
||||
background-color: var(--d-bgc-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
}
|
||||
.el-select-dropdown__item{
|
||||
color: var(--d-fc-1);
|
||||
border: none;
|
||||
background-color: var(--d-bgc-1);
|
||||
}
|
||||
.el-select-dropdown__item.hover{
|
||||
background-color: var(--d-c-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected{
|
||||
color: var(--d-fc-1);
|
||||
background-color: var(--d-c-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected.hover{
|
||||
color: var(--d-fc-1);
|
||||
background-color: var(--d-c-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
color: var(--d-fc-1);
|
||||
background-color: var(--d-bgc-1);
|
||||
&:hover{
|
||||
&::-webkit-scrollbar-thumb {
|
||||
box-shadow: var(--d-bsc-scroll);
|
||||
background: var(--d-c-5);
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
box-shadow: var(--d-bsc-scroll);
|
||||
background: var(--d-bgc-1);
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
/* 设置el-table的样式*/
|
||||
.show-table{
|
||||
/* 设置el-table的样式*/
|
||||
.el-table{
|
||||
color: var(--d-fc-1);
|
||||
background-color: var(--d-bgc-1);
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--d-bgc-2);
|
||||
border: 1px solid var(--d-bgc-2);
|
||||
color: var(--d-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--d-fc-1);
|
||||
background-color: var(--d-bgc-1);
|
||||
border-bottom-color: var(--d-c-2);
|
||||
}
|
||||
.el-table__body-wrapper{
|
||||
&:hover{
|
||||
@@ -407,6 +416,18 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--d-bgc-2);
|
||||
border: 1px solid var(--d-bgc-2);
|
||||
color: var(--d-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--d-fc-1);
|
||||
background-color: var(--d-bgc-1);
|
||||
border-bottom-color: var(--d-c-2);
|
||||
}
|
||||
.el-table--enable-row-hover .el-table__body tr:hover>td{
|
||||
background-color: var(--d-bgc-2);
|
||||
}
|
||||
@@ -417,6 +438,17 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.show-picture{
|
||||
color: var(--d-fc-1);
|
||||
.card{
|
||||
background-color: var(--d-bgc-1);
|
||||
box-shadow: var(--d-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--d-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -166,23 +166,6 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.pictureView{
|
||||
.body{
|
||||
background-color: var(--g-bgc-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
.show-img{
|
||||
color: var(--g-fc-1);
|
||||
.card{
|
||||
background-color: var(--g-bgc-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--g-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.play{
|
||||
background-color: var(--g-bgc-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
@@ -347,11 +330,10 @@
|
||||
background-color: var(--g-bgc-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
}
|
||||
// Page of list using el-table
|
||||
// Page of list using table and picture
|
||||
.listpage{
|
||||
color: var(--g-fc-2);
|
||||
.listpage-content{
|
||||
.listpage-header{
|
||||
.listpage-header{
|
||||
border-bottom-color: var(--g-c-3);
|
||||
.btn{
|
||||
&:hover{
|
||||
@@ -372,24 +354,50 @@
|
||||
color: var(--g-fc-2);
|
||||
}
|
||||
}
|
||||
.el-select-dropdown{
|
||||
color: var(--g-fc-1);
|
||||
border: none;
|
||||
background-color: var(--g-bgc-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
}
|
||||
.el-select-dropdown__item{
|
||||
color: var(--g-fc-1);
|
||||
border: none;
|
||||
background-color: var(--g-bgc-1);
|
||||
}
|
||||
.el-select-dropdown__item.hover{
|
||||
background-color: var(--g-c-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected{
|
||||
color: var(--g-fc-1);
|
||||
background-color: var(--g-c-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected.hover{
|
||||
color: var(--g-fc-1);
|
||||
background-color: var(--g-c-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
color: var(--g-fc-1);
|
||||
background-color: var(--g-bgc-1);
|
||||
&:hover{
|
||||
&::-webkit-scrollbar-thumb {
|
||||
box-shadow: var(--g-bsc-scroll);
|
||||
background: var(--g-c-5);
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
box-shadow: var(--g-bsc-scroll);
|
||||
background: var(--g-bgc-1);
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
/* 设置el-table的样式*/
|
||||
.show-table{
|
||||
/* 设置el-table的样式*/
|
||||
.el-table{
|
||||
color: var(--g-fc-1);
|
||||
background-color: var(--g-bgc-1);
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--g-bgc-2);
|
||||
border: 1px solid var(--g-bgc-2);
|
||||
color: var(--g-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--g-fc-1);
|
||||
background-color: var(--g-bgc-1);
|
||||
border-bottom-color: var(--g-c-2);
|
||||
}
|
||||
.el-table__body-wrapper{
|
||||
&:hover{
|
||||
@@ -403,6 +411,18 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--g-bgc-2);
|
||||
border: 1px solid var(--g-bgc-2);
|
||||
color: var(--g-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--g-fc-1);
|
||||
background-color: var(--g-bgc-1);
|
||||
border-bottom-color: var(--g-c-2);
|
||||
}
|
||||
.el-table--enable-row-hover .el-table__body tr:hover>td{
|
||||
background-color: var(--g-bgc-2);
|
||||
}
|
||||
@@ -413,6 +433,17 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.show-picture{
|
||||
color: var(--g-fc-1);
|
||||
.card{
|
||||
background-color: var(--g-bgc-1);
|
||||
box-shadow: var(--g-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--g-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -166,23 +166,6 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.pictureView{
|
||||
.body{
|
||||
background-color: var(--l-bgc-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
.show-img{
|
||||
color: var(--l-fc-1);
|
||||
.card{
|
||||
background-color: var(--l-bgc-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--l-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.play{
|
||||
background-color: var(--l-bgc-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
@@ -347,49 +330,74 @@
|
||||
background-color: var(--l-bgc-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
}
|
||||
// Page of list using el-table
|
||||
// Page of list using table and picture
|
||||
.listpage{
|
||||
color: var(--l-fc-2);
|
||||
.listpage-content{
|
||||
.listpage-header{
|
||||
border-bottom-color: var(--l-c-3);
|
||||
.btn{
|
||||
&:hover{
|
||||
color: var(--l-fc-3)
|
||||
}
|
||||
}
|
||||
.el-button{
|
||||
background-color: var(--l-bgc-2);
|
||||
color: var(--l-fc-2);
|
||||
&:hover{
|
||||
color: var(--l-fc-3)
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--l-bgc-1);
|
||||
border: 1px solid var(--l-bgc-1);
|
||||
color: var(--l-fc-2);
|
||||
}
|
||||
.listpage-header{
|
||||
border-bottom-color: var(--l-c-3);
|
||||
.btn{
|
||||
&:hover{
|
||||
color: var(--l-fc-3)
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
/* 设置el-table的样式*/
|
||||
.el-button{
|
||||
background-color: var(--l-bgc-2);
|
||||
color: var(--l-fc-2);
|
||||
&:hover{
|
||||
color: var(--l-fc-3)
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--l-bgc-1);
|
||||
border: 1px solid var(--l-bgc-1);
|
||||
color: var(--l-fc-2);
|
||||
}
|
||||
}
|
||||
.el-select-dropdown{
|
||||
color: var(--l-fc-1);
|
||||
border: none;
|
||||
background-color: var(--l-bgc-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
}
|
||||
.el-select-dropdown__item{
|
||||
color: var(--l-fc-1);
|
||||
border: none;
|
||||
background-color: var(--l-bgc-1);
|
||||
}
|
||||
.el-select-dropdown__item.hover{
|
||||
background-color: var(--l-c-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected{
|
||||
color: var(--l-fc-1);
|
||||
background-color: var(--l-c-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected.hover{
|
||||
color: var(--l-fc-1);
|
||||
background-color: var(--l-c-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
color: var(--l-fc-1);
|
||||
background-color: var(--l-bgc-1);
|
||||
&:hover{
|
||||
&::-webkit-scrollbar-thumb {
|
||||
box-shadow: var(--l-bsc-scroll);
|
||||
background: var(--l-c-5);
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
box-shadow: var(--l-bsc-scroll);
|
||||
background: var(--l-bgc-1);
|
||||
}
|
||||
}
|
||||
.show-table{
|
||||
/* 设置el-table的样式*/
|
||||
.el-table{
|
||||
color: var(--l-fc-1);
|
||||
background-color: var(--l-bgc-1);
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--l-bgc-2);
|
||||
border: 1px solid var(--l-bgc-2);
|
||||
color: var(--l-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--l-fc-1);
|
||||
background-color: var(--l-bgc-1);
|
||||
border-bottom-color: var(--l-c-2);
|
||||
}
|
||||
.el-table__body-wrapper{
|
||||
&:hover{
|
||||
@@ -403,6 +411,18 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--l-bgc-2);
|
||||
border: 1px solid var(--l-bgc-2);
|
||||
color: var(--l-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--l-fc-1);
|
||||
background-color: var(--l-bgc-1);
|
||||
border-bottom-color: var(--l-c-2);
|
||||
}
|
||||
.el-table--enable-row-hover .el-table__body tr:hover>td{
|
||||
background-color: var(--l-bgc-2);
|
||||
}
|
||||
@@ -413,6 +433,17 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.show-picture{
|
||||
color: var(--l-fc-1);
|
||||
.card{
|
||||
background-color: var(--l-bgc-1);
|
||||
box-shadow: var(--l-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--l-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -165,23 +165,6 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.pictureView{
|
||||
.body{
|
||||
background-color: var(--p-bgc-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
.show-img{
|
||||
color: var(--p-fc-1);
|
||||
.card{
|
||||
background-color: var(--p-bgc-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--p-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.play{
|
||||
background-color: var(--p-bgc-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
@@ -346,49 +329,74 @@
|
||||
background-color: var(--p-bgc-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
}
|
||||
// Page of list using el-table
|
||||
// Page of list using table and picture
|
||||
.listpage{
|
||||
color: var(--p-fc-2);
|
||||
.listpage-content{
|
||||
.listpage-header{
|
||||
border-bottom-color: var(--p-c-3);
|
||||
.btn{
|
||||
&:hover{
|
||||
color: var(--p-fc-3)
|
||||
}
|
||||
}
|
||||
.el-button{
|
||||
background-color: var(--p-bgc-2);
|
||||
color: var(--p-fc-2);
|
||||
&:hover{
|
||||
color: var(--p-fc-3)
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--p-bgc-1);
|
||||
border: 1px solid var(--p-bgc-1);
|
||||
color: var(--p-fc-2);
|
||||
}
|
||||
.listpage-header{
|
||||
border-bottom-color: var(--p-c-3);
|
||||
.btn{
|
||||
&:hover{
|
||||
color: var(--p-fc-3)
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
/* 设置el-table的样式*/
|
||||
.el-button{
|
||||
background-color: var(--p-bgc-2);
|
||||
color: var(--p-fc-2);
|
||||
&:hover{
|
||||
color: var(--p-fc-3)
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--p-bgc-1);
|
||||
border: 1px solid var(--p-bgc-1);
|
||||
color: var(--p-fc-2);
|
||||
}
|
||||
}
|
||||
.el-select-dropdown{
|
||||
color: var(--p-fc-1);
|
||||
border: none;
|
||||
background-color: var(--p-bgc-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
}
|
||||
.el-select-dropdown__item{
|
||||
color: var(--p-fc-1);
|
||||
border: none;
|
||||
background-color: var(--p-bgc-1);
|
||||
}
|
||||
.el-select-dropdown__item.hover{
|
||||
background-color: var(--p-c-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected{
|
||||
color: var(--p-fc-1);
|
||||
background-color: var(--p-c-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
}
|
||||
.el-select-dropdown__item.selected.hover{
|
||||
color: var(--p-fc-1);
|
||||
background-color: var(--p-c-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
}
|
||||
}
|
||||
.listpage-body{
|
||||
color: var(--p-fc-1);
|
||||
background-color: var(--p-bgc-1);
|
||||
&:hover{
|
||||
&::-webkit-scrollbar-thumb {
|
||||
box-shadow: var(--p-bsc-scroll);
|
||||
background: var(--p-c-5);
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
box-shadow: var(--p-bsc-scroll);
|
||||
background: var(--p-bgc-1);
|
||||
}
|
||||
}
|
||||
.show-table{
|
||||
/* 设置el-table的样式*/
|
||||
.el-table{
|
||||
color: var(--p-fc-1);
|
||||
background-color: var(--p-bgc-1);
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--p-bgc-2);
|
||||
border: 1px solid var(--p-bgc-2);
|
||||
color: var(--p-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--p-fc-1);
|
||||
background-color: var(--p-bgc-1);
|
||||
border-bottom-color: var(--p-c-2);
|
||||
}
|
||||
.el-table__body-wrapper{
|
||||
&:hover{
|
||||
@@ -402,6 +410,18 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.el-input{
|
||||
input{
|
||||
background-color: var(--p-bgc-2);
|
||||
border: 1px solid var(--p-bgc-2);
|
||||
color: var(--p-fc-1);
|
||||
}
|
||||
}
|
||||
.el-table__header th, .el-table__header tr, .el-table__body td,.el-table__body th{
|
||||
color: var(--p-fc-1);
|
||||
background-color: var(--p-bgc-1);
|
||||
border-bottom-color: var(--p-c-2);
|
||||
}
|
||||
.el-table--enable-row-hover .el-table__body tr:hover>td{
|
||||
background-color: var(--p-bgc-2);
|
||||
}
|
||||
@@ -412,6 +432,17 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.show-picture{
|
||||
color: var(--p-fc-1);
|
||||
.card{
|
||||
background-color: var(--p-bgc-1);
|
||||
box-shadow: var(--p-bsc);
|
||||
transition: all 0.3s cubic-bezier(.25,.8,.25,1);
|
||||
&:hover{
|
||||
box-shadow: var(--p-bsc-hover);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -256,25 +256,9 @@ export default {
|
||||
}
|
||||
},
|
||||
doubanLinkEvent () {
|
||||
const open = require('open')
|
||||
const axios = require('axios')
|
||||
const cheerio = require('cheerio')
|
||||
const name = this.detail.info.name.trim()
|
||||
// 豆瓣搜索链接
|
||||
var doubanSearchLink = 'https://www.douban.com/search?q=' + name
|
||||
var link = doubanSearchLink
|
||||
axios.get(doubanSearchLink).then(res => {
|
||||
const $ = cheerio.load(res.data)
|
||||
// 比较第一和第二豆瓣搜索结果, 如果名字相符, 就打开该链接,否则打开搜索页面
|
||||
var nameInDouban = $($('div.result')[0]).find('div>div>h3>a').first()
|
||||
if (name.replace(/\s/g, '') === nameInDouban.text().replace(/\s/g, '')) {
|
||||
link = nameInDouban.attr('href')
|
||||
} else {
|
||||
nameInDouban = $($('div.result')[1]).find('div>div>h3>a').first()
|
||||
if (name.replace(/\s/g, '') === nameInDouban.text().replace(/\s/g, '')) {
|
||||
link = nameInDouban.attr('href')
|
||||
}
|
||||
}
|
||||
zy.doubanLink(name).then(link => {
|
||||
const open = require('open')
|
||||
open(link)
|
||||
})
|
||||
},
|
||||
|
||||
@@ -1,27 +1,26 @@
|
||||
<template>
|
||||
<div class="listpage" id="editSites">
|
||||
<div class="listpage-content">
|
||||
<div class="listpage-header" v-show="!enableBatchEdit">
|
||||
<el-switch v-model="enableBatchEdit" active-text="批处理分组">></el-switch>
|
||||
<el-button @click="addSite" icon="el-icon-document-add">新增</el-button>
|
||||
<el-button @click="exportSites" icon="el-icon-upload2" >导出</el-button>
|
||||
<el-button @click="importSites" icon="el-icon-download">导入</el-button>
|
||||
<el-button @click="checkAllSite" icon="el-icon-refresh" :loading="checkAllSiteLoading">检测</el-button>
|
||||
<el-button @click="removeAllSites" icon="el-icon-delete-solid">清空</el-button>
|
||||
<el-button @click="resetSitesEvent" icon="el-icon-refresh-left">重置</el-button>
|
||||
</div>
|
||||
<div class="listpage-header" v-show="enableBatchEdit">
|
||||
<el-switch v-model="enableBatchEdit" active-text="批处理分组"></el-switch>
|
||||
<el-input placeholder="新组名" v-model="batchGroupName"></el-input>
|
||||
<el-switch v-model="batchIsActive" :active-value="1" :inactive-value="0" active-text="自选源"></el-switch>
|
||||
<el-button type="primary" icon="el-icon-edit" @click.stop="saveBatchEdit">保存</el-button>
|
||||
</div>
|
||||
<div class="listpage-body" id="sites-table">
|
||||
<el-table
|
||||
<div class="listpage" id="sites">
|
||||
<div class="listpage-header" v-show="!enableBatchEdit">
|
||||
<el-switch v-model="enableBatchEdit" active-text="批处理分组">></el-switch>
|
||||
<el-checkbox v-model="setting.excludeR18Films" @change="excludeR18FilmsChangeEvent">屏蔽福利片</el-checkbox>
|
||||
<el-button @click="addSite" icon="el-icon-document-add">新增</el-button>
|
||||
<el-button @click="exportSites" icon="el-icon-upload2" >导出</el-button>
|
||||
<el-button @click="importSites" icon="el-icon-download">导入</el-button>
|
||||
<el-button @click="checkAllSite" icon="el-icon-refresh" :loading="checkAllSiteLoading">检测</el-button>
|
||||
<el-button @click="removeAllSites" icon="el-icon-delete-solid">清空</el-button>
|
||||
<el-button @click="resetSitesEvent" icon="el-icon-refresh-left">重置</el-button>
|
||||
</div>
|
||||
<div class="listpage-header" v-show="enableBatchEdit">
|
||||
<el-switch v-model="enableBatchEdit" active-text="批处理分组"></el-switch>
|
||||
<el-input placeholder="新组名" v-model="batchGroupName"></el-input>
|
||||
<el-switch v-model="batchIsActive" :active-value="1" :inactive-value="0" active-text="自选源"></el-switch>
|
||||
<el-button type="primary" icon="el-icon-edit" @click.stop="saveBatchEdit">保存</el-button>
|
||||
</div>
|
||||
<div class="listpage-body" id="sites-body">
|
||||
<div class="show-table" id="sites-table">
|
||||
<el-table size="mini" fit height="100%" row-key="id"
|
||||
ref="editSitesTable"
|
||||
size="mini" fit height="100%" row-key="id"
|
||||
:data="sites"
|
||||
:key="tableKey"
|
||||
@selection-change="handleSelectionChange"
|
||||
@sort-change="handleSortChange">
|
||||
<el-table-column
|
||||
@@ -79,7 +78,8 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 编辑页面 -->
|
||||
<div>
|
||||
<el-dialog :visible.sync="dialogVisible" v-if='dialogVisible' :title="dialogType==='edit'?'编辑源':'新增源'" :append-to-body="true" @close="closeDialog">
|
||||
@@ -108,12 +108,11 @@
|
||||
</span>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { mapMutations } from 'vuex'
|
||||
import { sites } from '../lib/dexie'
|
||||
import { sites, setting } from '../lib/dexie'
|
||||
import zy from '../lib/site/tools'
|
||||
import { remote } from 'electron'
|
||||
import { sites as defaultSites } from '../lib/dexie/initData'
|
||||
@@ -189,6 +188,12 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
...mapMutations(['SET_SETTING', 'SET_EDITSITES']),
|
||||
excludeR18FilmsChangeEvent () {
|
||||
setting.find().then(res => {
|
||||
res.excludeR18Films = this.setting.excludeR18Films
|
||||
setting.update(res)
|
||||
})
|
||||
},
|
||||
filterHandle (value, row) {
|
||||
return row.group === value
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="film pictureView">
|
||||
<div class="header">
|
||||
<div class="listpage" id="film">
|
||||
<div class="listpage-header" id="film-header">
|
||||
<div class="zy-select" @mouseleave="show.site = false">
|
||||
<div class="vs-placeholder" @click="show.site = true">{{site.name}}</div>
|
||||
<div class="vs-options" v-show="show.site">
|
||||
@@ -27,17 +27,16 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="body zy-scroll" infinite-wrapper>
|
||||
<div class="body-box" v-show="!show.find">
|
||||
<div class="show-img" v-if="setting.view === 'picture'">
|
||||
<Waterfall ref="waterfall" :list="list" :gutter="20" :width="240"
|
||||
<div class="listpage-body" id="film-body" infinite-wrapper>
|
||||
<div class="show-picture" v-if="setting.view === 'picture' && !show.find">
|
||||
<Waterfall ref="filmWaterfall" :list="list" :gutter="20" :width="240"
|
||||
:breakpoints="{ 1200: { rowPerView: 4 } }"
|
||||
animationEffect="fadeInUp"
|
||||
backgroundColor="rgba(0, 0, 0, 0)">
|
||||
<template slot="item" slot-scope="props">
|
||||
<div class="card" v-show="!setting.excludeR18Films || !containsR18Keywords(props.data.type)">
|
||||
<div class="img">
|
||||
<img style="width: 100%" :src="props.data.pic" alt="" @load="$refs.waterfall.refresh()" @click="detailEvent(site, props.data)">
|
||||
<img style="width: 100%" :src="props.data.pic" alt="" @load="$refs.filmWaterfall.refresh()" @click="detailEvent(site, props.data)">
|
||||
<div class="operate">
|
||||
<div class="operate-wrap">
|
||||
<span class="o-play" @click="playEvent(site, props.data)">播放</span>
|
||||
@@ -48,6 +47,7 @@
|
||||
</div>
|
||||
<div class="name" @click="detailEvent(site, props.data)">{{props.data.name}}</div>
|
||||
<div class="info">
|
||||
<span>{{props.data.area}}</span>
|
||||
<span>{{props.data.year}}</span>
|
||||
<span>{{props.data.note}}</span>
|
||||
<span>{{props.data.type}}</span>
|
||||
@@ -56,51 +56,124 @@
|
||||
</template>
|
||||
</Waterfall>
|
||||
<infinite-loading force-use-infinite-wrapper :identifier="infiniteId" @infinite="infiniteHandler"></infinite-loading>
|
||||
</div>
|
||||
<div class="show-table" v-if="setting.view === 'table'">
|
||||
<div class="zy-table">
|
||||
<div class="tBody">
|
||||
<ul>
|
||||
<li v-for="(i, j) in list" :key="j" @click="detailEvent(site, i)" v-show="!setting.excludeR18Films || !containsR18Keywords(i.type)">
|
||||
<span class="name">{{i.name}}</span>
|
||||
<span class="type">{{i.type}}</span>
|
||||
<span class="time">{{i.year}}</span>
|
||||
<span class="note">{{i.note}}</span>
|
||||
<span class="last">{{i.last}}</span>
|
||||
<span class="operate">
|
||||
<span class="btn" @click.stop="playEvent(site, i)">播放</span>
|
||||
<span class="btn" @click.stop="starEvent(site, i)">收藏</span>
|
||||
<span class="btn" @click.stop="shareEvent(site, i)">分享</span>
|
||||
<span class="btn" @click.stop="downloadEvent(site, i)">下载</span>
|
||||
</span>
|
||||
</li>
|
||||
</ul>
|
||||
<infinite-loading force-use-infinite-wrapper :identifier="infiniteId" @infinite="infiniteHandler"></infinite-loading>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="body-box" v-show="show.find">
|
||||
<div class="show-table">
|
||||
<div class="zy-table">
|
||||
<div class="tBody zy-scroll">
|
||||
<ul>
|
||||
<li v-for="(i, j) in searchContents" :key="j" @click="detailEvent(i.site, i)">
|
||||
<span class="name">{{i.name}}</span>
|
||||
<span class="info">{{i.site.name}}</span>
|
||||
<span class="info">{{i.type}}</span>
|
||||
<span class="info">{{i.note}}</span>
|
||||
<span class="operate">
|
||||
<span class="btn" @click.stop="playEvent(i.site, i)">播放</span>
|
||||
<span class="btn" @click.stop="starEvent(i.site, i)">收藏</span>
|
||||
<span class="btn" @click.stop="shareEvent(i.site, i)">分享</span>
|
||||
<span class="btn" @click.stop="downloadEvent(i.site, i)">下载</span>
|
||||
</span>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="show-table" v-if="setting.view === 'table' && !show.find">
|
||||
<el-table size="mini"
|
||||
:data="list.filter(res => !setting.excludeR18Films || !containsR18Keywords(res.type))"
|
||||
height="100%"
|
||||
@row-click="(row) => detailEvent(site, row)"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="片名">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="type"
|
||||
label="类型"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="year"
|
||||
label="上映"
|
||||
align="center"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="area"
|
||||
label="地区"
|
||||
align="center"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="lang"
|
||||
label="语言"
|
||||
align="center"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="note"
|
||||
label="备注">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="操作"
|
||||
header-align="center"
|
||||
align="right"
|
||||
width="200">
|
||||
<template slot-scope="scope">
|
||||
<el-button @click.stop="playEvent(site, scope.row)" type="text">播放</el-button>
|
||||
<el-button @click.stop="starEvent(site, scope.row)" type="text">收藏</el-button>
|
||||
<el-button @click.stop="shareEvent(site, scope.row)" type="text">分享</el-button>
|
||||
<el-button @click.stop="downloadEvent(site, scope.row)" type="text">下载</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<infinite-loading
|
||||
slot="append"
|
||||
:identifier="infiniteId"
|
||||
@infinite="infiniteHandler"
|
||||
force-use-infinite-wrapper=".el-table__body-wrapper">
|
||||
<div slot="no-more">数据量过少时请重复操作一次,以防网站抽风</div>
|
||||
</infinite-loading>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="show-table" v-show="show.find">
|
||||
<el-table size="mini"
|
||||
:data="searchContents.filter(res => !setting.excludeR18Films || (res.type !== undefined && !containsR18Keywords(res.type)))"
|
||||
height="100%"
|
||||
row-key="id"
|
||||
@row-click="(row) => detailEvent(row.site, row)"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="片名">
|
||||
</el-table-column>
|
||||
<el-table-column v-if="setting.searchAllSites"
|
||||
prop="site"
|
||||
label="源站"
|
||||
width="120">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.site.name }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="type"
|
||||
label="类型"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="year"
|
||||
label="上映"
|
||||
align="center"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="area"
|
||||
label="地区"
|
||||
align="center"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="lang"
|
||||
label="语言"
|
||||
align="center"
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="note"
|
||||
label="备注">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="操作"
|
||||
header-align="center"
|
||||
align="right"
|
||||
width="200">
|
||||
<template slot-scope="scope">
|
||||
<el-button @click.stop="playEvent(scope.row.site, scope.row)" type="text">播放</el-button>
|
||||
<el-button @click.stop="starEvent(scope.row.site, scope.row)" type="text">收藏</el-button>
|
||||
<el-button @click.stop="shareEvent(scope.row.site, scope.row)" type="text">分享</el-button>
|
||||
<el-button @click.stop="downloadEvent(scope.row.site, scope.row)" type="text">下载</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -180,11 +253,15 @@ export default {
|
||||
},
|
||||
sitesList () {
|
||||
return this.$store.getters.getEditSites.sites // 需要监听的数据
|
||||
},
|
||||
filterSettings () {
|
||||
return this.$store.getters.getSetting.excludeR18Films // 需要监听的数据
|
||||
}
|
||||
},
|
||||
filters: {
|
||||
classNameFilter: (name) => {
|
||||
return name.replace(/[^\u4e00-\u9fa5]/gi, '')
|
||||
const clsName = name.toString()
|
||||
return clsName.replace(/[^\u4e00-\u9fa5]/gi, '')
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@@ -196,6 +273,9 @@ export default {
|
||||
},
|
||||
sitesList () {
|
||||
this.getAllsites()
|
||||
},
|
||||
filterSettings () {
|
||||
this.siteClick(this.site)
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -211,10 +291,9 @@ export default {
|
||||
this.classList = []
|
||||
this.type = {}
|
||||
this.getClass().then(res => {
|
||||
if (res) {
|
||||
this.show.class = true
|
||||
this.infiniteId += 1
|
||||
}
|
||||
this.show.class = true
|
||||
this.infiniteId += 1
|
||||
this.classClick(this.classList[0])
|
||||
})
|
||||
}
|
||||
},
|
||||
@@ -390,11 +469,11 @@ export default {
|
||||
changeView () {
|
||||
if (this.view === 'Film') {
|
||||
if (this.setting.view === 'picture') {
|
||||
this.$refs.waterfall.refresh()
|
||||
this.$refs.filmWaterfall.refresh()
|
||||
this.getPage().then(() => {
|
||||
this.infiniteId += 1
|
||||
})
|
||||
}
|
||||
this.getPage().then(() => {
|
||||
this.infiniteId += 1
|
||||
})
|
||||
}
|
||||
},
|
||||
getAllSearch () {
|
||||
@@ -482,8 +561,10 @@ export default {
|
||||
this.sites = res.filter((item, index, self) => {
|
||||
return self.indexOf(item) >= 0 && item.isActive
|
||||
})
|
||||
this.site = this.sites[0]
|
||||
this.siteClick(this.site)
|
||||
if (this.site === undefined || !this.sites.some(x => x.key === this.site.key)) {
|
||||
this.site = this.sites[0]
|
||||
this.siteClick(this.site)
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -493,104 +574,3 @@ export default {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.film{
|
||||
height: calc(100% - 40px);
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
.header{
|
||||
height: 30px;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
z-index: 10;
|
||||
}
|
||||
.body{
|
||||
margin-top: 20px;
|
||||
flex: 1;
|
||||
width: 100%;
|
||||
border-radius: 0 0 5px 5px;
|
||||
overflow-y: scroll;
|
||||
&::-webkit-scrollbar{
|
||||
width: 5px;
|
||||
height: 1px;
|
||||
}
|
||||
&::-webkit-scrollbar-thumb {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
.body-box{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
.show-img{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
padding: 10px;
|
||||
.card{
|
||||
border-radius: 6px;
|
||||
overflow: hidden;
|
||||
.img{
|
||||
position: relative;
|
||||
min-height: 40px;
|
||||
img{
|
||||
width: 100%;
|
||||
height: auto;
|
||||
cursor: pointer;
|
||||
}
|
||||
.operate{
|
||||
display: none;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
background-color: #111111aa;
|
||||
width: 100%;
|
||||
font-size: 13px;
|
||||
.operate-wrap{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.o-play, .o-star, .o-share{
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 80px;
|
||||
height: 36px;
|
||||
text-align: center;
|
||||
line-height: 36px;
|
||||
color: #cdcdcd;
|
||||
&:hover{
|
||||
background-color: #111;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.name{
|
||||
font-size: 16px;
|
||||
padding: 10px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
cursor: pointer;
|
||||
}
|
||||
.info{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 12px;
|
||||
padding: 10px;
|
||||
}
|
||||
&:hover{
|
||||
.operate{
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
<template>
|
||||
<div class="listpage" id="history">
|
||||
<div class="listpage-content">
|
||||
<div class="listpage-header">
|
||||
<div class="listpage-header" id="history-header">
|
||||
<el-button @click.stop="exportHistory" icon="el-icon-upload2">导出</el-button>
|
||||
<el-button @click.stop="importHistory" icon="el-icon-download">导入</el-button>
|
||||
<el-button @click.stop="clearAllHistory" icon="el-icon-delete-solid">清空</el-button>
|
||||
</div>
|
||||
<div class="listpage-body" id="history-table">
|
||||
</div>
|
||||
<div class="listpage-body" id="history-body">
|
||||
<div class="show-table" id="history-table" >
|
||||
<el-table size="mini" fit height="100%" :data="history" row-key="id" @row-click="detailEvent">
|
||||
<el-table-column
|
||||
prop="name"
|
||||
@@ -42,7 +42,7 @@
|
||||
</el-table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { mapMutations } from 'vuex'
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
<template>
|
||||
<div class="listpage" id="IPTV">
|
||||
<div class="listpage-content">
|
||||
<div class="listpage-header" v-show="!enableBatchEdit">
|
||||
<div class="listpage" id="iptv">
|
||||
<div class="listpage-header" id="iptv-header" v-show="!enableBatchEdit">
|
||||
<el-switch v-model="enableBatchEdit" active-text="批处理分组"></el-switch>
|
||||
<el-button @click.stop="exportChannels" icon="el-icon-upload2" >导出</el-button>
|
||||
<el-button @click.stop="importChannels" icon="el-icon-download">导入</el-button>
|
||||
<el-button @click.stop="removeAllChannels" icon="el-icon-delete-solid">清空</el-button>
|
||||
<el-button @click.stop="resetChannelsEvent" icon="el-icon-refresh-left">重置</el-button>
|
||||
</div>
|
||||
<div class="listpage-header" v-show="enableBatchEdit">
|
||||
</div>
|
||||
<div class="listpage-header" id="iptv-header" v-show="enableBatchEdit">
|
||||
<el-switch v-model="enableBatchEdit" active-text="批处理分组"></el-switch>
|
||||
<el-input placeholder="新组名" v-model="batchGroupName"></el-input>
|
||||
<el-button type="primary" icon="el-icon-edit" @click.stop="saveBatchEdit">保存</el-button>
|
||||
</div>
|
||||
<div class="listpage-body" id="iptv-table">
|
||||
</div>
|
||||
<div class="listpage-body" id="iptv-table">
|
||||
<div class="show-table" id="iptv-table">
|
||||
<el-table
|
||||
ref="iptvTable"
|
||||
size="mini" fit height="100%" row-key="id"
|
||||
@@ -132,7 +132,9 @@ export default {
|
||||
},
|
||||
watch: {
|
||||
view () {
|
||||
this.getChannels()
|
||||
if (this.view === 'IPTV') {
|
||||
this.getChannels()
|
||||
}
|
||||
},
|
||||
searchTxt () {
|
||||
}
|
||||
|
||||
@@ -129,9 +129,9 @@
|
||||
<ul v-show="right.type === 'shortcut'" class="list-shortcut">
|
||||
<li v-for="(m, n) in right.shortcut" :key="n"><span class="title">{{m.desc}} -- [ {{m.key}} ]</span></li>
|
||||
</ul>
|
||||
<ul v-show="right.type === 'other'" class="list-other">
|
||||
<ul v-show="right.type === 'other'" class="list-other" v-on-clickaway="closeListEvent">
|
||||
<li v-show="right.other.length === 0">无数据</li>
|
||||
<li @click="otherItemEvent(m)" v-for="(m, n) in right.other" :key="n"><span class="title">{{m.name}} - [{{m.site}}]</span></li>
|
||||
<li @click="otherItemEvent(m)" v-for="(m, n) in right.other" :key="n"><span class="title">{{m.name}} - [{{m.site.name}}]</span></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@@ -145,6 +145,8 @@ import zy from '../lib/site/tools'
|
||||
import Player from 'xgplayer'
|
||||
import Hls from 'xgplayer-hls.js'
|
||||
import mt from 'mousetrap'
|
||||
import { directive as onClickaway } from 'vue-clickaway'
|
||||
|
||||
const { remote, ipcRenderer, clipboard } = require('electron')
|
||||
|
||||
const VIDEO_DETAIL_CACHE = {}
|
||||
@@ -247,6 +249,9 @@ export default {
|
||||
}
|
||||
}
|
||||
},
|
||||
directives: {
|
||||
onClickaway: onClickaway
|
||||
},
|
||||
computed: {
|
||||
view: {
|
||||
get () {
|
||||
@@ -744,48 +749,39 @@ export default {
|
||||
this.$message.warning('删除历史记录失败, 错误信息: ' + err)
|
||||
})
|
||||
},
|
||||
async getAllsites () {
|
||||
const all = await sites.all()
|
||||
async getOtherSites () {
|
||||
this.right.other = []
|
||||
for (const i of all) {
|
||||
if (i.isActive) {
|
||||
try {
|
||||
const searchRes = await zy.search(i.key, this.name)
|
||||
sites.all().then(sitesRes => {
|
||||
// 排除已关闭的源和当前源
|
||||
for (const siteItem of sitesRes.filter(x => x.isActive && x.key !== this.video.key)) {
|
||||
zy.search(siteItem.key, this.name).then(searchRes => {
|
||||
const type = Object.prototype.toString.call(searchRes)
|
||||
if (type === '[object Array]') {
|
||||
searchRes.forEach(async item => {
|
||||
const detailRes = item
|
||||
detailRes.key = i.key
|
||||
detailRes.site = i.site
|
||||
detailRes.key = siteItem.key
|
||||
detailRes.site = siteItem
|
||||
this.right.other.push(detailRes)
|
||||
})
|
||||
}
|
||||
if (type === '[object Object]') {
|
||||
const detailRes = searchRes
|
||||
detailRes.key = i.key
|
||||
detailRes.site = i.name
|
||||
detailRes.key = siteItem.key
|
||||
detailRes.site = siteItem
|
||||
this.right.other.push(detailRes)
|
||||
}
|
||||
} catch (err) {
|
||||
console.error(err)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
otherEvent (m) {
|
||||
this.right.type = 'other'
|
||||
this.getAllsites()
|
||||
this.getOtherSites()
|
||||
this.right.show = true
|
||||
},
|
||||
async otherItemEvent (e) {
|
||||
const db = await history.find({ site: e.key, ids: e.id })
|
||||
if (db) {
|
||||
this.video = { key: db.site, info: { id: db.ids, name: db.name, index: db.index, site: e.key } }
|
||||
} else {
|
||||
this.video = { key: e.key, info: { id: e.id, name: e.name, index: 0, site: e.key } }
|
||||
}
|
||||
this.right.show = false
|
||||
this.right.type = ''
|
||||
// 打开当前播放的剧集index, 定位到当前的时间
|
||||
this.video = { key: e.key, info: { id: e.id, name: e.name, site: e.site, index: this.video.info.index, time: this.xg.currentTime } }
|
||||
},
|
||||
mtEvent () {
|
||||
setting.find().then(res => {
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
<template>
|
||||
<div class="listpage recommandataions pictureView">
|
||||
<div class="listpage-content">
|
||||
<div class="listpage-header">
|
||||
<div class="listpage" id="recommandataions">
|
||||
<div class="listpage-header" id="recommandataions-header">
|
||||
<el-switch v-model="viewMode" active-text="海报" active-value="picture" inactive-text="列表" inactive-value="list" @change="updateViewMode"></el-switch>
|
||||
<el-select size="mini" v-model="selectedAreas" multiple collapse-tags style="margin-left: 20px;" placeholder="地区">
|
||||
<el-button type="text">视频数:{{ recommandations.length }}</el-button>
|
||||
<el-select v-model="selectedAreas" multiple collapse-tags placeholder="地区" :popper-append-to-body="false">
|
||||
<el-option
|
||||
v-for="item in areas"
|
||||
:key="item"
|
||||
@@ -11,7 +11,7 @@
|
||||
:value="item">
|
||||
</el-option>
|
||||
</el-select>
|
||||
<el-select size="mini" v-model="selectedTypes" multiple collapse-tags style="margin-left: 20px;" placeholder="类型">
|
||||
<el-select v-model="selectedTypes" multiple collapse-tags placeholder="类型" :popper-append-to-body="false">
|
||||
<el-option
|
||||
v-for="item in types"
|
||||
:key="item"
|
||||
@@ -20,8 +20,9 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
<el-button :loading="loading" @click.stop="updateEvent" icon="el-icon-refresh">更新推荐</el-button>
|
||||
</div>
|
||||
<div class="listpage-body" id="recommandataions-table" v-show="viewMode === 'list'">
|
||||
</div>
|
||||
<div class="listpage-body" id="recommandataions-body" >
|
||||
<div class="show-table" id="star-table" v-show="viewMode === 'list'">
|
||||
<el-table size="mini" fit height="100%" row-key="id"
|
||||
ref="recommandataionsTable"
|
||||
:data="filteredRecommandations"
|
||||
@@ -69,9 +70,8 @@
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="body zy-scroll" id="star-picture" v-show="viewMode === 'picture'">
|
||||
<div class="show-img">
|
||||
<Waterfall ref="waterfall" :list="filteredRecommandations" :gutter="20" :width="240"
|
||||
<div class="show-picture" id="star-picture" v-show="viewMode === 'picture'">
|
||||
<Waterfall ref="recommandataionsWaterfall" :list="filteredRecommandations" :gutter="20" :width="240"
|
||||
:breakpoints="{ 1200: { rowPerView: 4 } }"
|
||||
animationEffect="fadeInUp"
|
||||
backgroundColor="rgba(0, 0, 0, 0)">
|
||||
@@ -79,9 +79,9 @@
|
||||
<div class="card">
|
||||
<div class="img">
|
||||
<div class="rate" v-if="props.data.rate && props.data.rate !== '暂无评分'">
|
||||
<span>豆瓣: {{props.data.rate}}</span>
|
||||
<span>{{props.data.rate}}分</span>
|
||||
</div>
|
||||
<img style="width: 100%" :src="props.data.detail.pic" alt="" @load="$refs.waterfall.refresh()" @click="detailEvent(props.data)">
|
||||
<img style="width: 100%" :src="props.data.detail.pic" alt="" @load="$refs.recommandataionsWaterfall.refresh()" @click="detailEvent(props.data)">
|
||||
<div class="operate">
|
||||
<div class="operate-wrap">
|
||||
<span class="o-play" @click="playEvent(props.data)">播放</span>
|
||||
@@ -100,8 +100,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</Waterfall>
|
||||
</div>
|
||||
</Waterfall>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -170,7 +169,10 @@ export default {
|
||||
},
|
||||
watch: {
|
||||
view () {
|
||||
this.getRecommandations()
|
||||
if (this.view === 'Recommandation') {
|
||||
this.getRecommandations()
|
||||
this.$refs.recommandataionsWaterfall.refresh()
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -192,11 +194,11 @@ export default {
|
||||
axios.get(url).then(res => {
|
||||
if (res.status === 200) {
|
||||
if (res.data.length > 0) {
|
||||
this.recommandations = res.data
|
||||
this.recommandations.sort(function (a, b) {
|
||||
this.recommandations = res.data.sort(function (a, b) {
|
||||
return b.detail.year - a.detail.year
|
||||
})
|
||||
recommandation.clear().then(recommandation.bulkAdd(this.recommandations))
|
||||
this.getFilterData()
|
||||
this.$message.success('更新推荐成功')
|
||||
}
|
||||
}
|
||||
@@ -273,9 +275,8 @@ export default {
|
||||
},
|
||||
getRecommandations () {
|
||||
recommandation.all().then(res => {
|
||||
this.recommandations = res
|
||||
this.recommandations.sort(function (a, b) {
|
||||
return b.detail.year - a.detail.year
|
||||
this.recommandations = res.sort(function (a, b) {
|
||||
return b.id - a.id
|
||||
})
|
||||
this.getFilterData()
|
||||
})
|
||||
@@ -302,104 +303,3 @@ export default {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.recommandataions{
|
||||
.body{
|
||||
height: calc(100% - 40px);
|
||||
display: flex;
|
||||
position: relative;
|
||||
overflow-y: auto;
|
||||
&::-webkit-scrollbar{
|
||||
width: 5px;
|
||||
height: 1px;
|
||||
}
|
||||
&::-webkit-scrollbar-thumb {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
.body-box{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
.show-img{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
padding: 10px;
|
||||
.card{
|
||||
border-radius: 6px;
|
||||
overflow: hidden;
|
||||
.img{
|
||||
position: relative;
|
||||
min-height: 40px;
|
||||
img{
|
||||
width: 100%;
|
||||
height: auto;
|
||||
cursor: pointer;
|
||||
}
|
||||
.rate{
|
||||
position: absolute;
|
||||
top: 10%;
|
||||
right: -35%;
|
||||
width: 100%;
|
||||
background-color: #111111aa;
|
||||
color: #cdcdcd;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
font-size: 14px;
|
||||
text-align: center;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
.operate{
|
||||
display: none;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
background-color: #111111aa;
|
||||
width: 100%;
|
||||
font-size: 13px;
|
||||
.operate-wrap{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.o-play, .o-star, .o-share{
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 80px;
|
||||
height: 36px;
|
||||
text-align: center;
|
||||
line-height: 36px;
|
||||
color: #cdcdcd;
|
||||
&:hover{
|
||||
background-color: #111;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.name{
|
||||
font-size: 16px;
|
||||
padding: 10px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
cursor: pointer;
|
||||
}
|
||||
.info{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 12px;
|
||||
padding: 10px;
|
||||
}
|
||||
&:hover{
|
||||
.operate{
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -68,11 +68,11 @@
|
||||
<div class="zy-select">
|
||||
<div class="vs-placeholder vs-noAfter" @click="selectLocalPlayer">选择本地播放器</div>
|
||||
</div>
|
||||
<div class="zy-select" @click = "editPlayerPath = true">
|
||||
<div class="vs-placeholder vs-noAfter" v-show = "editPlayerPath == false">
|
||||
<div class="zy-select" @click = "show.editPlayerPath = true">
|
||||
<div class="vs-placeholder vs-noAfter" v-show = "show.editPlayerPath == false">
|
||||
<label>编辑</label>
|
||||
</div>
|
||||
<input class="zy-input" v-show = "editPlayerPath == true" v-model = "d.externalPlayer"
|
||||
<input class="zy-input" v-show = "show.editPlayerPath == true" v-model = "d.externalPlayer"
|
||||
@blur= "updateSettingEvent"
|
||||
@keyup.enter = "updateSettingEvent">
|
||||
</div>
|
||||
@@ -87,9 +87,6 @@
|
||||
<div class="zy-input" @click="toggleExcludeRootClasses">
|
||||
<input type="checkbox" v-model = "d.excludeRootClasses" @change="updateSettingEvent"> 屏蔽主分类
|
||||
</div>
|
||||
<div class="zy-input" @click="toggleExcludeR18Films">
|
||||
<input type="checkbox" v-model = "d.excludeR18Films" @change="updateSettingEvent"> 屏蔽福利片
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="theme">
|
||||
@@ -130,12 +127,39 @@
|
||||
</div>
|
||||
<div class="clearDB">
|
||||
<span @click="clearDBEvent" class="clearBtn">软件重置</span>
|
||||
<span class="clearTips">如果新安装用户, 无法显示资源, 请点击软件重置. 如非必要, 切勿点击. 会清空用户数据, 恢复默认设置. 点击即软件重置, 并关闭软件.</span>
|
||||
<span @click="changePasswordEvent" class="clearBtn">设置密码</span>
|
||||
<div class="clearTips">如果新安装用户, 无法显示资源, 请点击软件重置. 如非必要, 切勿点击. 会清空用户数据, 恢复默认设置. 点击即软件重置, 并关闭软件.</div>
|
||||
</div>
|
||||
<div class="Tips">
|
||||
<span>所有资源来自网上, 该软件不参与任何制作, 上传, 储存等内容, 禁止传播违法资源. 该软件仅供学习参考, 请于安装后24小时内删除.</span>
|
||||
</div>
|
||||
</div>
|
||||
<div> <!-- 输入密码页面 -->
|
||||
<el-dialog :visible.sync="show.checkPasswordDialog" v-if='show.checkPasswordDialog' :append-to-body="true" @close="closeDialog" width="300px">
|
||||
<el-form label-width="75px" label-position="left">
|
||||
<el-form-item label="当前密码" prop='name'>
|
||||
<el-input v-model="inputPassword" placeholder="请输入您的当前密码" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="closeDialog">取消</el-button>
|
||||
<el-button type="primary" @click="checkPasswordEvent">确定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</div>
|
||||
<div> <!-- 修改密码页面 -->
|
||||
<el-dialog :visible.sync="show.changePasswordDialog" v-if='show.changePasswordDialog' :append-to-body="true" @close="closeDialog" width="300px">
|
||||
<el-form label-width="75px" label-position="left">
|
||||
<el-form-item label="新密码" prop='name'>
|
||||
<el-input v-model="inputPassword" placeholder="请输入您的新密码" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="closeDialog">取消</el-button>
|
||||
<el-button type="primary" @click="confirmedChangePasswordEvent">确定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
@@ -155,26 +179,15 @@ export default {
|
||||
show: {
|
||||
site: false,
|
||||
shortcut: false,
|
||||
view: false
|
||||
},
|
||||
externalPlayer: '',
|
||||
editPlayerPath: false,
|
||||
excludeR18Films: true,
|
||||
latestVersion: pkg.version,
|
||||
forwardTimeInSec: 5,
|
||||
d: {
|
||||
id: 0,
|
||||
site: '',
|
||||
theme: '',
|
||||
shortcut: true,
|
||||
searchAllSites: true,
|
||||
view: 'picture',
|
||||
externalPlayer: '',
|
||||
view: false,
|
||||
editPlayerPath: false,
|
||||
excludeRootClasses: true,
|
||||
excludeR18Films: true,
|
||||
forwardTimeInSec: 5
|
||||
}
|
||||
checkPasswordDialog: false,
|
||||
changePasswordDialog: false
|
||||
},
|
||||
d: { },
|
||||
latestVersion: pkg.version,
|
||||
inputPassword: '',
|
||||
action: ''
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -246,7 +259,7 @@ export default {
|
||||
this.$message.success(`清除缓存成功, 共清理 ${mb} MB`)
|
||||
},
|
||||
updateSettingEvent () {
|
||||
this.editPlayerPath = false
|
||||
this.show.editPlayerPath = false
|
||||
this.setting = this.d
|
||||
setting.update(this.d)
|
||||
},
|
||||
@@ -254,10 +267,6 @@ export default {
|
||||
this.d.searchAllSites = !this.d.searchAllSites
|
||||
this.updateSettingEvent()
|
||||
},
|
||||
toggleExcludeR18Films () {
|
||||
this.d.excludeR18Films = !this.d.excludeR18Films
|
||||
this.updateSettingEvent()
|
||||
},
|
||||
toggleExcludeRootClasses () {
|
||||
this.d.excludeRootClasses = !this.d.excludeRootClasses
|
||||
this.updateSettingEvent()
|
||||
@@ -290,11 +299,48 @@ export default {
|
||||
},
|
||||
updatePlayerPath () {
|
||||
this.$message.success('设定第三方播放器路径为:' + this.d.externalPlayer)
|
||||
this.editPlayerPath = false
|
||||
this.show.editPlayerPath = false
|
||||
this.updateSettingEvent()
|
||||
},
|
||||
editSitesEvent () {
|
||||
this.view = 'EditSites'
|
||||
if (this.d.password) {
|
||||
this.action = 'EditSites'
|
||||
this.show.checkPasswordDialog = true
|
||||
} else {
|
||||
this.view = 'EditSites'
|
||||
}
|
||||
},
|
||||
closeDialog () {
|
||||
this.show.checkPasswordDialog = false
|
||||
this.show.changePasswordDialog = false
|
||||
this.inputPassword = ''
|
||||
},
|
||||
checkPasswordEvent () {
|
||||
if (this.inputPassword === this.d.password) {
|
||||
this.closeDialog()
|
||||
if (this.action === 'EditSites') {
|
||||
this.view = 'EditSites'
|
||||
} else if (this.action === 'ChangePassword') {
|
||||
this.show.changePasswordDialog = true
|
||||
} else if (this.action === 'CleanDB') {
|
||||
this.clearDB()
|
||||
}
|
||||
} else {
|
||||
this.$message.error('您输入的密码错误,请重试')
|
||||
}
|
||||
},
|
||||
changePasswordEvent () {
|
||||
if (this.d.password) {
|
||||
this.action = 'ChangePassword'
|
||||
this.show.checkPasswordDialog = true
|
||||
} else {
|
||||
this.show.changePasswordDialog = true
|
||||
}
|
||||
},
|
||||
confirmedChangePasswordEvent () {
|
||||
this.d.password = this.inputPassword
|
||||
this.updateSettingEvent()
|
||||
this.closeDialog()
|
||||
},
|
||||
changeTheme (e) {
|
||||
this.d.theme = e
|
||||
@@ -323,6 +369,14 @@ export default {
|
||||
})
|
||||
},
|
||||
clearDBEvent () {
|
||||
if (this.d.password) {
|
||||
this.action = 'CleanDB'
|
||||
this.show.checkPasswordDialog = true
|
||||
} else {
|
||||
this.clearDB()
|
||||
}
|
||||
},
|
||||
clearDB () {
|
||||
db.delete().then(res => {
|
||||
this.$message.success('重置成功')
|
||||
const win = remote.getCurrentWindow()
|
||||
@@ -509,9 +563,9 @@ export default {
|
||||
line-height: 32px;
|
||||
}
|
||||
.clearTips{
|
||||
margin: 10px 0 0 20px;
|
||||
font-size: 12px;
|
||||
color: #ff000088;
|
||||
margin-left: 10px;
|
||||
}
|
||||
}
|
||||
.Tips{
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="share" id="share" @click="shareClickEvent">
|
||||
<div class="share" id="share" @click="shareClickEvent" v-on-clickaway="shareClickEvent">
|
||||
<div class="left">
|
||||
<img :src="pic" alt="" @load="picLoadEvent">
|
||||
</div>
|
||||
@@ -22,6 +22,7 @@ import { mapMutations } from 'vuex'
|
||||
import QrcodeVue from 'qrcode.vue'
|
||||
import html2canvas from 'html2canvas'
|
||||
import zy from '../lib/site/tools'
|
||||
import { directive as onClickaway } from 'vue-clickaway'
|
||||
const { clipboard, nativeImage } = require('electron')
|
||||
export default {
|
||||
name: 'share',
|
||||
@@ -56,6 +57,9 @@ export default {
|
||||
deep: true
|
||||
}
|
||||
},
|
||||
directives: {
|
||||
onClickaway: onClickaway
|
||||
},
|
||||
methods: {
|
||||
...mapMutations(['SET_SHARE']),
|
||||
shareClickEvent () {
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
<template>
|
||||
<div class="listpage star pictureView">
|
||||
<div class="listpage-content">
|
||||
<div class="listpage-header">
|
||||
<div class="listpage" id="star">
|
||||
<div class="listpage-header" id="star-header">
|
||||
<el-switch v-model="viewMode" active-text="海报" active-value="picture" inactive-text="列表" inactive-value="list" @change="updateViewMode"></el-switch>
|
||||
<el-button @click.stop="exportFavoritesEvent" icon="el-icon-upload2">导出</el-button>
|
||||
<el-button @click.stop="importFavoritesEvent" icon="el-icon-download">导入</el-button>
|
||||
<el-button @click.stop="clearFavoritesEvent" icon="el-icon-delete-solid">清空</el-button>
|
||||
<el-button @click.stop="updateAllEvent" icon="el-icon-refresh">同步所有收藏</el-button>
|
||||
</div>
|
||||
<div class="listpage-body" id="star-table" v-show="viewMode === 'list'">
|
||||
</div>
|
||||
<div class="listpage-body" id="star-body">
|
||||
<div class="show-table" id="star-table" v-show="viewMode === 'list'">
|
||||
<el-table size="mini" fit height="100%" row-key="id"
|
||||
ref="starTable"
|
||||
:data="list"
|
||||
@@ -21,6 +21,14 @@
|
||||
prop="name"
|
||||
label="片名">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="site.name"
|
||||
width="120"
|
||||
label="源站">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ getSiteName(scope.row) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:sort-by="['detail.type', 'name']"
|
||||
sortable
|
||||
@@ -37,14 +45,6 @@
|
||||
width="100"
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="site.name"
|
||||
width="120"
|
||||
label="源站">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ getSiteName(scope.row) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column v-if="list.some(e => e.detail.note)"
|
||||
prop="detail.note"
|
||||
width="120"
|
||||
@@ -76,9 +76,8 @@
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="body zy-scroll" id="star-picture" v-show="viewMode === 'picture'">
|
||||
<div class="show-img">
|
||||
<Waterfall ref="waterfall" :list="list" :gutter="20" :width="240"
|
||||
<div class="show-picture" id="star-picture" v-show="viewMode === 'picture'">
|
||||
<Waterfall ref="starWaterfall" :list="list" :gutter="20" :width="240"
|
||||
:breakpoints="{ 1200: { rowPerView: 4 } }"
|
||||
animationEffect="fadeInUp"
|
||||
backgroundColor="rgba(0, 0, 0, 0)">
|
||||
@@ -86,9 +85,12 @@
|
||||
<div class="card">
|
||||
<div class="img">
|
||||
<div class="rate" v-if="props.data.rate && props.data.rate !== '暂无评分'">
|
||||
<span>豆瓣: {{props.data.rate}}</span>
|
||||
<span>{{props.data.rate}}分</span>
|
||||
</div>
|
||||
<img style="width: 100%" :src="props.data.detail.pic" alt="" @load="$refs.waterfall.refresh()" @click="detailEvent(props.data)">
|
||||
<div class="update" v-if="props.data.hasUpdate">
|
||||
<span>有更新</span>
|
||||
</div>
|
||||
<img style="width: 100%" :src="props.data.detail.pic" alt="" @load="$refs.starWaterfall.refresh()" @click="detailEvent(props.data)">
|
||||
<div class="operate">
|
||||
<div class="operate-wrap">
|
||||
<span class="o-play" @click="playEvent(props.data)">播放</span>
|
||||
@@ -100,21 +102,21 @@
|
||||
</div>
|
||||
<div class="name" @click="detailEvent(props.data)">{{props.data.name}}</div>
|
||||
<div class="info">
|
||||
<span>{{props.data.detail.area}}</span>
|
||||
<span>{{props.data.detail.year}}</span>
|
||||
<span>{{props.data.detail.note}}</span>
|
||||
<span>{{props.data.detail.type}}</span>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</Waterfall>
|
||||
</div>
|
||||
</Waterfall>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { mapMutations } from 'vuex'
|
||||
import { star, history, sites, setting } from '../lib/dexie'
|
||||
import { star, sites, setting } from '../lib/dexie'
|
||||
import zy from '../lib/site/tools'
|
||||
import { remote } from 'electron'
|
||||
import fs from 'fs'
|
||||
@@ -127,7 +129,8 @@ export default {
|
||||
return {
|
||||
list: [],
|
||||
sites: [],
|
||||
viewMode: 'picture'
|
||||
viewMode: 'picture',
|
||||
numNoUpdate: 0
|
||||
}
|
||||
},
|
||||
components: {
|
||||
@@ -169,8 +172,18 @@ export default {
|
||||
},
|
||||
watch: {
|
||||
view () {
|
||||
this.getAllsites()
|
||||
this.getFavorites()
|
||||
if (this.view === 'Star') {
|
||||
this.getAllsites()
|
||||
this.getFavorites()
|
||||
this.$refs.starWaterfall.refresh()
|
||||
}
|
||||
},
|
||||
numNoUpdate () {
|
||||
// 如果所有收藏都没有更新的话
|
||||
if (this.numNoUpdate === this.list.length) {
|
||||
this.numNoUpdate = 0
|
||||
this.$message.warning('未查询到任何更新')
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -198,9 +211,8 @@ export default {
|
||||
}
|
||||
},
|
||||
async playEvent (e) {
|
||||
const db = await history.find({ site: e.key, ids: e.ids })
|
||||
if (db) {
|
||||
this.video = { key: e.key, info: { id: db.ids, name: db.name, index: db.index } }
|
||||
if (e.index) {
|
||||
this.video = { key: e.key, info: { id: e.ids, name: e.name, index: e.index } }
|
||||
} else {
|
||||
this.video = { key: e.key, info: { id: e.ids, name: e.name, index: 0 } }
|
||||
}
|
||||
@@ -251,14 +263,12 @@ export default {
|
||||
index: e.index
|
||||
}
|
||||
star.get(e.id).then(resStar => {
|
||||
var msg = ''
|
||||
if (e.detail.last === detailRes.last) {
|
||||
msg = `同步"${e.name}"成功, 未查询到更新。`
|
||||
this.$message.info(msg)
|
||||
} else {
|
||||
if (!e.hasUpdate && e.detail.last !== detailRes.last) {
|
||||
doc.hasUpdate = true
|
||||
msg = `同步"${e.name}"成功, 检查到更新。`
|
||||
var msg = `同步"${e.name}"成功, 检查到更新。`
|
||||
this.$message.success(msg)
|
||||
} else {
|
||||
this.numNoUpdate += 1
|
||||
}
|
||||
star.update(e.id, doc)
|
||||
this.getFavorites()
|
||||
@@ -269,6 +279,7 @@ export default {
|
||||
})
|
||||
},
|
||||
updateAllEvent () {
|
||||
this.numNoUpdate = 0
|
||||
this.list.forEach(e => {
|
||||
this.updateEvent(e)
|
||||
})
|
||||
@@ -334,7 +345,9 @@ export default {
|
||||
},
|
||||
getFavorites () {
|
||||
star.all().then(res => {
|
||||
this.list = res.reverse()
|
||||
this.list = res.sort(function (a, b) {
|
||||
return b.id - a.id
|
||||
})
|
||||
})
|
||||
},
|
||||
getAllsites () {
|
||||
@@ -355,7 +368,7 @@ export default {
|
||||
remote.dialog.showSaveDialog(options).then(result => {
|
||||
if (!result.canceled) {
|
||||
fs.writeFileSync(result.filePath, str)
|
||||
this.$message.success('已保存成功')
|
||||
this.$message.success('导出收藏成功')
|
||||
}
|
||||
}).catch(err => {
|
||||
this.$message.error(err)
|
||||
@@ -372,14 +385,16 @@ export default {
|
||||
}
|
||||
remote.dialog.showOpenDialog(options).then(result => {
|
||||
if (!result.canceled) {
|
||||
var starList = this.list
|
||||
var starList = Array.from(this.list)
|
||||
var id = this.list.length + 1
|
||||
result.filePaths.forEach(file => {
|
||||
var str = fs.readFileSync(file)
|
||||
const json = JSON.parse(str)
|
||||
json.forEach(ele => {
|
||||
const starExists = starList.includes(x => x.key === ele.key && x.ids === ele.ids)
|
||||
json.reverse().forEach(ele => {
|
||||
const starExists = starList.some(x => x.key === ele.key && x.ids === ele.ids)
|
||||
if (!starExists) {
|
||||
var doc = {
|
||||
id: id,
|
||||
key: ele.key,
|
||||
ids: ele.ids,
|
||||
site: ele.site === undefined ? ele.site = this.sites.find(x => x.key === ele.key) : ele.site,
|
||||
@@ -398,6 +413,7 @@ export default {
|
||||
note: ele.note
|
||||
} : ele.detail
|
||||
}
|
||||
id += 1
|
||||
starList.push(doc)
|
||||
}
|
||||
})
|
||||
@@ -464,104 +480,3 @@ export default {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.star{
|
||||
.body{
|
||||
height: calc(100% - 40px);
|
||||
display: flex;
|
||||
position: relative;
|
||||
overflow-y: auto;
|
||||
&::-webkit-scrollbar{
|
||||
width: 5px;
|
||||
height: 1px;
|
||||
}
|
||||
&::-webkit-scrollbar-thumb {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
}
|
||||
.body-box{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
.show-img{
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
padding: 10px;
|
||||
.card{
|
||||
border-radius: 6px;
|
||||
overflow: hidden;
|
||||
.img{
|
||||
position: relative;
|
||||
min-height: 40px;
|
||||
img{
|
||||
width: 100%;
|
||||
height: auto;
|
||||
cursor: pointer;
|
||||
}
|
||||
.rate{
|
||||
position: absolute;
|
||||
top: 10%;
|
||||
right: -35%;
|
||||
width: 100%;
|
||||
background-color: #111111aa;
|
||||
color: #cdcdcd;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
font-size: 14px;
|
||||
text-align: center;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
.operate{
|
||||
display: none;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
background-color: #111111aa;
|
||||
width: 100%;
|
||||
font-size: 13px;
|
||||
.operate-wrap{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.o-play, .o-star, .o-share{
|
||||
cursor: pointer;
|
||||
display: inline-block;
|
||||
width: 80px;
|
||||
height: 36px;
|
||||
text-align: center;
|
||||
line-height: 36px;
|
||||
color: #cdcdcd;
|
||||
&:hover{
|
||||
background-color: #111;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.name{
|
||||
font-size: 16px;
|
||||
padding: 10px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
cursor: pointer;
|
||||
}
|
||||
.info{
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 12px;
|
||||
padding: 10px;
|
||||
}
|
||||
&:hover{
|
||||
.operate{
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -6,7 +6,7 @@ const db = new Dexie('zy')
|
||||
db.version(4).stores({
|
||||
search: '++id, keywords',
|
||||
iptvSearch: '++id, keywords',
|
||||
setting: 'id, theme, site, shortcut, view, externalPlayer, searchAllSites, excludeRootClasses, excludeR18Films, forwardTimeInSec, starViewMode, recommandationViewMode',
|
||||
setting: 'id, theme, site, shortcut, view, externalPlayer, searchAllSites, excludeRootClasses, excludeR18Films, forwardTimeInSec, starViewMode, recommandationViewMode, password',
|
||||
shortcut: 'name, key, desc',
|
||||
star: '++id, [key+ids], site, name, detail, index, rate, hasUpdate',
|
||||
recommandation: '++id, [key+ids], site, name, detail, index, rate, hasUpdate',
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -10,7 +10,8 @@ const setting = [
|
||||
excludeR18Films: true,
|
||||
forwardTimeInSec: 5,
|
||||
starViewMode: 'picture',
|
||||
recommandationViewMode: 'picture'
|
||||
recommandationViewMode: 'picture',
|
||||
password: ''
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import Vue from 'vue'
|
||||
import { Message, Button, Table, TableColumn, Tag, Input, Dialog, Form, FormItem, Switch, Select, Option } from 'element-ui'
|
||||
import { Message, Button, Table, TableColumn, Tag, Input, Dialog, Form, FormItem, Switch, Select, Option, Checkbox } from 'element-ui'
|
||||
import Plugin from 'v-fit-columns'
|
||||
Vue.use(Button)
|
||||
Vue.use(Table)
|
||||
@@ -13,4 +13,5 @@ Vue.use(Switch)
|
||||
Vue.use(Plugin)
|
||||
Vue.use(Select)
|
||||
Vue.use(Option)
|
||||
Vue.use(Checkbox)
|
||||
Vue.prototype.$message = Message
|
||||
|
||||
@@ -214,11 +214,11 @@ const zy = {
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 获取豆瓣评分
|
||||
* 获取豆瓣页面链接
|
||||
* @param {*} name 视频名称
|
||||
* @returns 豆瓣评分
|
||||
* @returns 豆瓣页面链接,如果没有搜到该视频,返回搜索页面链接
|
||||
*/
|
||||
doubanRate (name) {
|
||||
doubanLink (name) {
|
||||
return new Promise((resolve, reject) => {
|
||||
// 豆瓣搜索链接
|
||||
var nameToSearch = name.replace(/\s/g, '')
|
||||
@@ -229,17 +229,38 @@ const zy = {
|
||||
var link = ''
|
||||
var linkInDouban = $($('div.result')[0]).find('div>div>h3>a').first()
|
||||
var nameInDouban = linkInDouban.text().replace(/\s/g, '')
|
||||
if (nameToSearch.includes(nameInDouban) || nameInDouban.includes(nameToSearch)) {
|
||||
if (nameToSearch === nameInDouban) {
|
||||
link = linkInDouban.attr('href')
|
||||
} else {
|
||||
linkInDouban = $($('div.result')[1]).find('div>div>h3>a').first()
|
||||
nameInDouban = linkInDouban.text().replace(/\s/g, '')
|
||||
if (nameToSearch.includes(nameInDouban) || nameInDouban.includes(nameToSearch)) {
|
||||
if (nameToSearch === nameInDouban) {
|
||||
link = linkInDouban.attr('href')
|
||||
}
|
||||
}
|
||||
// 如果找到链接,就打开该链接获取评分
|
||||
if (link) {
|
||||
resolve(link)
|
||||
} else {
|
||||
// 如果没找到符合的链接,返回搜索页面
|
||||
resolve(doubanSearchLink)
|
||||
}
|
||||
}).catch(err => {
|
||||
reject(err)
|
||||
})
|
||||
})
|
||||
},
|
||||
/**
|
||||
* 获取豆瓣评分
|
||||
* @param {*} name 视频名称
|
||||
* @returns 豆瓣评分
|
||||
*/
|
||||
doubanRate (name) {
|
||||
return new Promise((resolve, reject) => {
|
||||
var nameToSearch = name.replace(/\s/g, '')
|
||||
this.doubanLink(nameToSearch).then(link => {
|
||||
if (link.includes('https://www.douban.com/search')) {
|
||||
resolve('暂无评分')
|
||||
} else {
|
||||
axios.get(link).then(response => {
|
||||
const parsedHtml = cheerio.load(response.data)
|
||||
var rating = parsedHtml('body').find('#interest_sectl').first().find('strong').first()
|
||||
@@ -251,8 +272,6 @@ const zy = {
|
||||
}).catch(err => {
|
||||
reject(err)
|
||||
})
|
||||
} else {
|
||||
resolve('暂无评分')
|
||||
}
|
||||
}).catch(err => {
|
||||
reject(err)
|
||||
|
||||
Reference in New Issue
Block a user