Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
swifteditor
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
fukai
swifteditor
Commits
a8e8af48
Commit
a8e8af48
authored
Dec 11, 2018
by
gq777
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'ncb' of
https://gitee.com/zeng_hui/swifteditor
into ncb
parents
6574e7a6
8dcb9aeb
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
155 additions
and
1 deletions
+155
-1
T31G.js
src/swift/Tags/T31G.js
+152
-0
index.js
src/swift/Tags/index.js
+3
-1
No files found.
src/swift/Tags/T31G.js
0 → 100644
View file @
a8e8af48
import
React
,
{
Component
}
from
'react'
import
{
Form
,
Input
,
DatePicker
,
Row
,
Col
,
TimePicker
,
Button
,
Icon
,
Select
}
from
'antd'
;
import
{
InputSize
,
Currency
,
FormatAmount
}
from
"./Utils"
const
FormItem
=
Form
.
Item
;
const
Option
=
Select
.
Option
export
default
class
T31G
extends
Component
{
name
=
'T31G'
desp
=
"(Code)(Common Reference)"
pattern
=
" 6!n/4!n/12a"
tno
=
-
1
keys
=
[
1
,
2
,
3
]
onChange
=
(
index
,
value
)
=>
{
let
obj
=
{};
if
(
!
value
)
value
=
""
let
objtemp
=
this
.
props
.
value
objtemp
=
objtemp
&&
objtemp
.
length
?
objtemp
[
0
]
:
{}
objtemp
[
"s"
+
index
]
=
value
;
this
.
keys
.
forEach
(
i
=>
{
obj
[
's'
+
i
]
=
objtemp
[
's'
+
i
]
});
let
mval
=
""
;
mval
=
`
${
obj
.
s1
||
''
}${
obj
.
s2
?
`/
${
obj
.
s2
}
`
:
''
}${
obj
.
s3
?
`/
${
obj
.
s3
}
`
:
''
}
`
this
.
props
.
onValue
([
obj
,
mval
])
}
render
()
{
let
value
=
this
.
props
.
value
let
mval
=
value
&&
value
.
length
?
value
[
1
]
:
''
let
errmsg
=
value
&&
value
.
length
==
3
?
value
[
2
]
:
{}
value
=
value
&&
value
.
length
?
value
[
0
]
:
{}
return
(
<
Row
>
<
Col
style
=
{{
"minWidth"
:
'100px'
}}
span
=
{
3
}
>
<
FormItem
label
=
"Date"
required
=
{
this
.
props
.
status
==
'M'
||
mval
?
'required'
:
null
}
help
=
{
errmsg
.
s1
}
validateStatus
=
{
errmsg
.
s1
?
'error'
:
null
}
>
<
DatePicker
defaultValue
=
""
format
=
"yyMMdd"
value
=
{
value
.
s1
}
onChange
=
{(
date
,
dateString
)
=>
this
.
onChange
(
1
,
dateString
)}
/
>
<
/FormItem
>
<
/Col
>
<
Col
style
=
{{
"minWidth"
:
'100px'
}}
span
=
{
3
}
>
<
FormItem
label
=
"Time"
required
=
{
this
.
props
.
status
==
'M'
||
mval
?
'required'
:
null
}
help
=
{
errmsg
.
s2
}
validateStatus
=
{
errmsg
.
s2
?
'error'
:
null
}
>
<
TimePicker
defaultValue
=
""
format
=
"HHmm"
value
=
{
value
.
s2
}
onChange
=
{(
date
,
dateString
)
=>
this
.
onChange
(
2
,
dateString
)}
/
>
<
/FormItem
>
<
/Col
>
<
Col
span
=
{
4
}
>
<
FormItem
label
=
"Location"
required
=
{
this
.
props
.
status
==
'M'
||
mval
?
'required'
:
null
}
help
=
{
errmsg
.
s3
}
validateStatus
=
{
errmsg
.
s3
?
'error'
:
null
}
>
<
Select
allowClear
=
{
true
}
value
=
{
value
.
s3
}
style
=
{{
width
:
"100%"
}}
placeholder
=
"Location"
onChange
=
{(
val
)
=>
this
.
onChange
(
3
,
val
)}
>
<
Option
value
=
"ARBA"
>
ARBA
<
/Option
>
<
Option
value
=
"ATVI"
>
ATVI
<
/Option
>
<
Option
value
=
"AUME"
>
AUME
<
/Option
>
<
Option
value
=
"AUSY"
>
AUSY
<
/Option
>
<
Option
value
=
"BEBR"
>
BEBR
<
/Option
>
<
Option
value
=
"BRSP"
>
BRSP
<
/Option
>
<
Option
value
=
"CAMO"
>
CAMO
<
/Option
>
<
Option
value
=
"CATO"
>
CATO
<
/Option
>
<
Option
value
=
"CHGE"
>
CHGE
<
/Option
>
<
Option
value
=
"CHZU"
>
CHZU
<
/Option
>
<
Option
value
=
"CLSA"
>
CLSA
<
/Option
>
<
Option
value
=
"CNBE"
>
CNBE
<
/Option
>
<
Option
value
=
"CZPR"
>
CZPR
<
/Option
>
<
Option
value
=
"DECB"
>
DECB
<
/Option
>
<
Option
value
=
"DEFR"
>
DEFR
<
/Option
>
<
Option
value
=
"DKCO"
>
DKCO
<
/Option
>
<
Option
value
=
"EETA"
>
EETA
<
/Option
>
<
Option
value
=
"ESMA"
>
ESMA
<
/Option
>
<
Option
value
=
"EUTA"
>
EUTA
<
/Option
>
<
Option
value
=
"FIHE"
>
FIHE
<
/Option
>
<
Option
value
=
"FRPA"
>
FRPA
<
/Option
>
<
Option
value
=
"GBLO"
>
GBLO
<
/Option
>
<
Option
value
=
"GRAT"
>
GRAT
<
/Option
>
<
Option
value
=
"HKHK"
>
HKHK
<
/Option
>
<
Option
value
=
"HUBU"
>
HUBU
<
/Option
>
<
Option
value
=
"IDJA"
>
IDJA
<
/Option
>
<
Option
value
=
"IEDU"
>
IEDU
<
/Option
>
<
Option
value
=
"ILTA"
>
ILTA
<
/Option
>
<
Option
value
=
"INMU"
>
INMU
<
/Option
>
<
Option
value
=
"ITMI"
>
ITMI
<
/Option
>
<
Option
value
=
"ITRO"
>
ITRO
<
/Option
>
<
Option
value
=
"JPTO"
>
JPTO
<
/Option
>
<
Option
value
=
"KRSE"
>
KRSE
<
/Option
>
<
Option
value
=
"LBBE"
>
LBBE
<
/Option
>
<
Option
value
=
"LKCO"
>
LKCO
<
/Option
>
<
Option
value
=
"LULU"
>
LULU
<
/Option
>
<
Option
value
=
"MXMC"
>
MXMC
<
/Option
>
<
Option
value
=
"MYKL"
>
MYKL
<
/Option
>
<
Option
value
=
"NLAM"
>
NLAM
<
/Option
>
<
Option
value
=
"NOOS"
>
NOOS
<
/Option
>
<
Option
value
=
"NYFD"
>
NYFD
<
/Option
>
<
Option
value
=
"NYSE"
>
NYSE
<
/Option
>
<
Option
value
=
"NZAU"
>
NZAU
<
/Option
>
<
Option
value
=
"NZWE"
>
NZWE
<
/Option
>
<
Option
value
=
"PAPC"
>
PAPC
<
/Option
>
<
Option
value
=
"PHMA"
>
PHMA
<
/Option
>
<
Option
value
=
"PLWA"
>
PLWA
<
/Option
>
<
Option
value
=
"PTLI"
>
PTLI
<
/Option
>
<
Option
value
=
"ROBU"
>
ROBU
<
/Option
>
<
Option
value
=
"RUMO"
>
RUMO
<
/Option
>
<
Option
value
=
"SARI"
>
SARI
<
/Option
>
<
Option
value
=
"SEST"
>
SEST
<
/Option
>
<
Option
value
=
"SGSI"
>
SGSI
<
/Option
>
<
Option
value
=
"SKBR"
>
SKBR
<
/Option
>
<
Option
value
=
"THBA"
>
THBA
<
/Option
>
<
Option
value
=
"TRAN"
>
TRAN
<
/Option
>
<
Option
value
=
"TRIS"
>
TRIS
<
/Option
>
<
Option
value
=
"TWTA"
>
TWTA
<
/Option
>
<
Option
value
=
"USCH"
>
USCH
<
/Option
>
<
Option
value
=
"USGS"
>
USGS
<
/Option
>
<
Option
value
=
"USLA"
>
USLA
<
/Option
>
<
Option
value
=
"USNY"
>
USNY
<
/Option
>
<
Option
value
=
"VNHA"
>
VNHA
<
/Option
>
<
Option
value
=
"ZAJO"
>
ZAJO
<
/Option
>
<
/Select
>
<
/FormItem
>
<
/Col
>
<
/Row>
)
}
}
\ No newline at end of file
src/swift/Tags/index.js
View file @
a8e8af48
...
...
@@ -561,7 +561,8 @@ export default function(tag,props,onValue){
case
"T50G"
:
return
<
T50G
{...
props
}
onValue
=
{
onValue
}
/>
;
case
"T50H"
:
return
<
T50H
{...
props
}
onValue
=
{
onValue
}
/>
;
case
"T25A"
:
return
<
T25A
{...
props
}
onValue
=
{
onValue
}
/>
;
case
"T31G"
:
return
<
T31G
{...
props
}
onValue
=
{
onValue
}
/>
;
}
}
\ No newline at end of file
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