Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
张磊
/
FileStorageBeego
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
d05270d2
authored
2014-02-26 15:02:58 +0800
by
asta.xie
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
GetStrings action as GetString
1 parent
04a19685
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
controller.go
controller.go
View file @
d05270d
...
...
@@ -308,11 +308,11 @@ func (c *Controller) GetString(key string) string {
// GetStrings returns the input string slice by key string.
// it's designed for multi-value input field such as checkbox(input[type=checkbox]), multi-selection.
func
(
c
*
Controller
)
GetStrings
(
key
string
)
[]
string
{
r
:=
c
.
Ctx
.
Request
if
r
.
Form
==
nil
{
f
:=
c
.
Input
()
if
f
==
nil
{
return
[]
string
{}
}
vs
:=
r
.
Form
[
key
]
vs
:=
f
[
key
]
if
len
(
vs
)
>
0
{
return
vs
}
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment