Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qsh-wc
Project
Project
Details
Activity
Releases
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
honghuiliu
qsh-wc
Commits
8d738de4
Commit
8d738de4
authored
Sep 07, 2022
by
mahui
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
474788ed
90b114d9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
3 deletions
+4
-3
toilet.go
server/api/v1/web/toilet.go
+2
-1
toilet.go
server/request/toilet.go
+1
-1
qsh_partol.go
server/service/admin/qsh_partol.go
+1
-1
No files found.
server/api/v1/web/toilet.go
View file @
8d738de4
package
web
package
web
import
(
import
(
"fmt"
"gitee.com/zjlsliupei/ghelp"
"gitee.com/zjlsliupei/ghelp"
"github.com/flipped-aurora/gin-vue-admin/server/model/common/response"
"github.com/flipped-aurora/gin-vue-admin/server/model/common/response"
"github.com/flipped-aurora/gin-vue-admin/server/request"
"github.com/flipped-aurora/gin-vue-admin/server/request"
...
@@ -29,7 +30,7 @@ func GetToiletList(c *gin.Context) {
...
@@ -29,7 +30,7 @@ func GetToiletList(c *gin.Context) {
func
GetToiletDetail
(
c
*
gin
.
Context
)
{
func
GetToiletDetail
(
c
*
gin
.
Context
)
{
var
arg
request
.
GetId
var
arg
request
.
GetId
_
=
c
.
ShouldBindJSON
(
&
arg
)
_
=
c
.
ShouldBindJSON
(
&
arg
)
fmt
.
Println
(
c
.
ShouldBindJSON
(
&
arg
))
if
data
,
err
:=
toiletService
.
GetToiletDetail
(
arg
);
err
!=
nil
{
if
data
,
err
:=
toiletService
.
GetToiletDetail
(
arg
);
err
!=
nil
{
response
.
FailWithMessage
(
err
.
Error
(),
c
)
response
.
FailWithMessage
(
err
.
Error
(),
c
)
}
else
{
}
else
{
...
...
server/request/toilet.go
View file @
8d738de4
...
@@ -7,5 +7,5 @@ type Toilet struct {
...
@@ -7,5 +7,5 @@ type Toilet struct {
}
}
type
GetId
struct
{
type
GetId
struct
{
ID
string
`json:"id"`
ID
int
`json:"id"`
}
}
server/service/admin/qsh_partol.go
View file @
8d738de4
...
@@ -61,7 +61,7 @@ func (qshPartolService *QshPartolService) GetQshPartolInfoList(info adminReq.Qsh
...
@@ -61,7 +61,7 @@ func (qshPartolService *QshPartolService) GetQshPartolInfoList(info adminReq.Qsh
db
=
db
.
Where
(
"type = ?"
,
info
.
Type
)
db
=
db
.
Where
(
"type = ?"
,
info
.
Type
)
}
}
if
info
.
ToiletId
!=
0
{
if
info
.
ToiletId
!=
0
{
db
=
db
.
Where
(
"toilet_id = ?"
,
info
.
Toilet
)
db
=
db
.
Where
(
"toilet_id = ?"
,
info
.
Toilet
Id
)
}
}
err
=
db
.
Count
(
&
total
)
.
Error
err
=
db
.
Count
(
&
total
)
.
Error
if
err
!=
nil
{
if
err
!=
nil
{
...
...
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