diff --git a/src/components/EditSites.vue b/src/components/EditSites.vue
index 5e0db04..f966876 100644
--- a/src/components/EditSites.vue
+++ b/src/components/EditSites.vue
@@ -29,6 +29,16 @@
+
+
+ {{scope.row.group}}
+
+
site.group))]
+ var filters = []
+ groups.forEach(g => {
+ var doc = {
+ text: g,
+ value: g
+ }
+ filters.push(doc)
+ })
+ return filters
}
},
methods: {
...mapMutations(['SET_SETTING', 'SET_EDITSITES']),
+ filterHandle (value, row) {
+ return row.group === value
+ },
getSites () {
sites.all().then(res => {
this.sites = res
@@ -225,11 +250,14 @@ export default {
var str = fs.readFileSync(file)
const json = JSON.parse(str)
json.forEach(ele => {
- if (this.sites.filter(x => x.key === ele.key).length === 0 && this.sites.filter(x => x.name === ele.name && x.url === ele.url).length === 0) {
+ if (ele.api && this.sites.filter(x => x.key === ele.key).length === 0 && this.sites.filter(x => x.name === ele.name && x.api === ele.api).length === 0) {
// 不含该key 同时也不含名字和url一样的
if (ele.isActive === undefined) {
ele.isActive = 1
}
+ if (ele.group === undefined) {
+ ele.group = '导入'
+ }
this.sites.push(ele)
}
})
diff --git a/src/lib/dexie/dexie.js b/src/lib/dexie/dexie.js
index 423329c..7d29d15 100644
--- a/src/lib/dexie/dexie.js
+++ b/src/lib/dexie/dexie.js
@@ -9,7 +9,7 @@ db.version(3).stores({
setting: 'id, theme, site, shortcut, view, externalPlayer, searchAllSites, excludeRootClasses, excludeR18Films, forwardTimeInSec',
shortcut: 'name, key, desc',
star: '++id, site, ids, name, type, year, index',
- sites: '++id, key, name, api, download, isActive',
+ sites: '++id, key, name, api, download, isActive, group',
history: '++id, site, ids, name, type, year, index, time',
mini: 'id, site, ids, name, index, time',
iptv: '++id, name, url, group'
diff --git a/src/lib/dexie/initData.js b/src/lib/dexie/initData.js
index 46d66d1..d44df0e 100644
--- a/src/lib/dexie/initData.js
+++ b/src/lib/dexie/initData.js
@@ -19,7 +19,8 @@ const sites = [
name: 'OK 资源网',
api: 'http://cj.okzy.tv/inc/api.php',
download: 'http://cj.okzy.tv/inc/apidown.php',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 2,
@@ -27,7 +28,8 @@ const sites = [
name: '最大资源网',
api: 'http://www.zdziyuan.com/inc/api.php',
download: 'http://www.zdziyuan.com/inc/apidown.php',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 3,
@@ -35,7 +37,8 @@ const sites = [
name: '豆瓣电影资源',
api: 'http://v.1988cj.com/inc/api.php',
download: 'http://v.1988cj.com/inc/apidown.php',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 4,
@@ -43,7 +46,8 @@ const sites = [
name: '135 资源网',
api: 'http://cj.zycjw1.com/inc/api.php',
download: 'http://cj.zycjw1.com/inc/apidown.php',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 5,
@@ -51,7 +55,8 @@ const sites = [
name: '酷云资源',
api: 'http://caiji.kuyun98.com/inc/ldg_api.php',
download: 'http://caiji.kuyun98.com/inc/apidown.php',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 6,
@@ -59,7 +64,8 @@ const sites = [
name: '芒果 TV 资源网',
api: 'https://api.shijiapi.com/api.php/provide/vod/at/xml/',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 7,
@@ -67,7 +73,8 @@ const sites = [
name: '速播资源站',
api: 'https://www.subo988.com/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 8,
@@ -75,7 +82,8 @@ const sites = [
name: '209 资源',
api: 'http://cj.1156zy.com/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 9,
@@ -83,7 +91,8 @@ const sites = [
name: '最新资源',
api: 'http://api.zuixinapi.com/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 10,
@@ -91,7 +100,8 @@ const sites = [
name: '酷播资源',
api: 'http://api.kbzyapi.com/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 11,
@@ -99,7 +109,8 @@ const sites = [
name: '永久资源',
api: 'http://cj.yongjiuzyw.com/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 12,
@@ -107,7 +118,8 @@ const sites = [
name: '123 资源',
api: 'http://cj.123ku2.com:12315/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 13,
@@ -115,7 +127,8 @@ const sites = [
name: '88 影视资源站',
api: 'http://www.88zyw.net/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 14,
@@ -123,7 +136,8 @@ const sites = [
name: '卧龙资源',
api: 'http://cj.wlzy.tv/inc/api_mac.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 15,
@@ -131,7 +145,8 @@ const sites = [
name: '麻花资源',
api: 'https://www.mhapi123.com/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 16,
@@ -139,7 +154,8 @@ const sites = [
name: '快快资源',
api: 'https://api.kkzy.tv/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 17,
@@ -147,7 +163,8 @@ const sites = [
name: '壹伍捌资源网',
api: 'http://cj.158zyz.net:158/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 18,
@@ -155,7 +172,8 @@ const sites = [
name: '人人资源',
api: 'https://www.rrzyw.cc/api.php/provide/vod/from/rrm3u8/at/xml/',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 19,
@@ -163,7 +181,8 @@ const sites = [
name: '魔卡资源网',
api: 'https://cj.heiyap.com/api.php/provide/vod/at/xml/',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 20,
@@ -171,7 +190,8 @@ const sites = [
name: '快影资源站',
api: 'https://www.kyzy.tv/api.php/kyyun/vod/at/xml/',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 21,
@@ -179,7 +199,8 @@ const sites = [
name: '搜乐资源网',
api: 'https://www.caijizy.vip/api.php/provide/vod/at/xml/',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 22,
@@ -187,7 +208,8 @@ const sites = [
name: '步步高顶尖资源网',
api: 'http://api.bbkdj.com/api',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 23,
@@ -195,7 +217,8 @@ const sites = [
name: '1886 资源',
api: 'http://cj.1886zy.co/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 24,
@@ -203,7 +226,8 @@ const sites = [
name: '秒播资源',
api: 'http://caiji.mb77.vip/inc/api.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
},
{
id: 25,
@@ -211,7 +235,8 @@ const sites = [
name: '605资源',
api: 'http://www.605zy.net/inc/seacmsapi.php',
download: '',
- isActive: 1
+ isActive: 1,
+ group: '默认'
}
]