Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-operation-4
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
达摩4.0重构
haoban-operation-4
Commits
272c5b88
Commit
272c5b88
authored
Aug 21, 2020
by
caoyanzhi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: 去掉全局禁用eslint检测的/* eslint-disable */
parent
3d0c662d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
8 deletions
+8
-8
public.js
src/common/js/public.js
+2
-1
emitter.js
src/mixins/emitter.js
+6
-7
No files found.
src/common/js/public.js
View file @
272c5b88
...
...
@@ -95,8 +95,9 @@ export function formatNum(num) {
/**
* 表情过滤
* @param {String} str
* @return {string}
*/
/* eslint-disable */
export
function
emojiToStr
(
str
)
{
str
=
str
.
replace
(
/
\u
D83C
[\u
DF00-
\u
DFFF
]
|
\u
D83D
[\u
DC00-
\u
DE4F
]
|
[\u
D800-
\u
DBFF
]
|
[\u
DC00-
\u
DFFF
]
|
[^\u
0020-
\u
007E
\u
00A0-
\u
00BE
\u
2E80-
\u
A4CF
\u
F900-
\u
FAFF
\u
FE30-
\u
FE4F
\u
FF00-
\u
FFEF
\u
0080-
\u
009F
\u
2000-
\u
201f
\u
2026
\u
2022
\u
20ac
\r\n]
/g
,
''
);
return
unescape
(
escape
(
str
).
replace
(
/
\%
uD.
{3}
/g
,
''
));
...
...
src/mixins/emitter.js
View file @
272c5b88
'use strict'
;
/* eslint-disable */
function
_broadcast
(
componentName
,
eventName
,
params
)
{
this
.
$children
.
forEach
(
function
(
child
)
{
var
name
=
child
.
$options
.
componentName
;
const
name
=
child
.
$options
.
componentName
;
if
(
name
===
componentName
)
{
child
.
$emit
.
apply
(
child
,
[
eventName
].
concat
(
params
));
child
.
$emit
.
apply
(
child
,
[
eventName
].
concat
(
params
));
}
else
{
_broadcast
.
apply
(
child
,
[
componentName
,
eventName
].
concat
([
params
]));
_broadcast
.
apply
(
child
,
[
componentName
,
eventName
].
concat
([
params
]));
}
});
}
...
...
@@ -15,8 +14,8 @@ function _broadcast(componentName, eventName, params) {
export
default
{
methods
:
{
dispatch
:
function
dispatch
(
componentName
,
eventName
,
params
)
{
var
parent
=
this
.
$parent
||
this
.
$root
;
var
name
=
parent
.
$options
.
componentName
;
let
parent
=
this
.
$parent
||
this
.
$root
;
let
name
=
parent
.
$options
.
componentName
;
while
(
parent
&&
(
!
name
||
name
!==
componentName
))
{
parent
=
parent
.
$parent
;
...
...
@@ -26,7 +25,7 @@ export default {
}
}
if
(
parent
)
{
parent
.
$emit
.
apply
(
parent
,
[
eventName
].
concat
(
params
));
parent
.
$emit
.
apply
(
parent
,
[
eventName
].
concat
(
params
));
}
},
broadcast
:
function
broadcast
(
componentName
,
eventName
,
params
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment