Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
CnChunfeng
/
crm_server
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
70c6386b
authored
Mar 20, 2020
by
Joneq
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
增加1的打印
parent
d13698a3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
cmd/main.go
cmd/main.go
View file @
70c6386b
...
@@ -13,17 +13,17 @@ func main() {
...
@@ -13,17 +13,17 @@ func main() {
var
user_info
model
.
UserInfo
var
user_info
model
.
UserInfo
var
user_company
model
.
UserCompany
var
user_company
model
.
UserCompany
//查找
手机号
//查找
公司名称
err
:=
dao
.
Get
CmsDb
()
.
QueryRowx
(
"select mobile from user_info where userId = ?"
,
1599
)
.
StructScan
(
&
user_info
)
err
:=
dao
.
Get
Db
()
.
QueryRowx
(
"select com_name from lie_user_company where user_id = ?"
,
1
)
.
StructScan
(
&
user_company
)
if
err
!=
nil
{
if
err
!=
nil
{
fmt
.
Println
(
err
)
fmt
.
Println
(
err
)
}
}
fmt
.
Println
(
user_
info
.
Mobil
e
)
fmt
.
Println
(
user_
company
.
Com_nam
e
)
//查找
公司名称
//查找
手机号
err
=
dao
.
Get
Db
()
.
QueryRowx
(
"select com_name from lie_user_company where user_id = ?"
,
1
)
.
StructScan
(
&
user_company
)
err
=
dao
.
Get
CmsDb
()
.
QueryRowx
(
"select mobile from user_info where userId = ?"
,
1599
)
.
StructScan
(
&
user_info
)
if
err
!=
nil
{
if
err
!=
nil
{
fmt
.
Println
(
err
)
fmt
.
Println
(
err
)
}
}
fmt
.
Println
(
user_
company
.
Com_nam
e
)
fmt
.
Println
(
user_
info
.
Mobil
e
)
}
}
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