Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
Laisi_AutoMES2
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
jiawei.su
Laisi_AutoMES2
Commits
0d23be4e
Commit
0d23be4e
authored
Feb 01, 2021
by
xin.yang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bug
parent
b5559d19
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
2 deletions
+13
-2
LocationController.cs
Server/Apis/Siger.ApiWMS/Controllers/LocationController.cs
+13
-2
No files found.
Server/Apis/Siger.ApiWMS/Controllers/LocationController.cs
View file @
0d23be4e
...
@@ -1174,9 +1174,11 @@ namespace Siger.ApiWMS.Controllers
...
@@ -1174,9 +1174,11 @@ namespace Siger.ApiWMS.Controllers
{
{
throw
new
BadRequestException
(
CommonEnum
.
Fail
);
throw
new
BadRequestException
(
CommonEnum
.
Fail
);
}
}
var
tmp1
=
location
.
Get
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
realname
==
Location
.
val
&&
q
.
typeid
==
locationType
.
id
&&
q
.
parentid
==
parentid
&&
q
.
storageid
==
req
.
warehouseid
&&
q
.
id
!=
Location
.
locationid
.
ToInt
());
var
tmp
=
location
.
Get
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
realname
==
Location
.
val
&&
var
tmp
=
location
.
Get
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
realname
==
Location
.
val
&&
q
.
typeid
==
locationType
.
id
&&
q
.
parentid
==
parentid
&&
q
.
storageid
==
req
.
warehouseid
);
q
.
typeid
==
locationType
.
id
&&
q
.
parentid
==
parentid
&&
q
.
storageid
==
req
.
warehouseid
&&
q
.
id
==
Location
.
locationid
.
ToInt
()
);
if
(
tmp
!=
null
&&
tmp
.
typeid
==
locationTypeId
&&
!
ids
.
Any
()
&&
tmp
.
name
==
Location
.
val
&&
tmp
.
id
!=
Location
.
locationid
.
ToInt
()
)
if
(
tmp
1
!=
null
&&
tmp1
.
typeid
==
locationTypeId
&&
!
ids
.
Any
()
&&
tmp1
.
name
==
Location
.
val
)
{
{
throw
new
BadRequestException
(
RequestEnum
.
DataExist
);
throw
new
BadRequestException
(
RequestEnum
.
DataExist
);
}
}
...
@@ -1221,6 +1223,15 @@ namespace Siger.ApiWMS.Controllers
...
@@ -1221,6 +1223,15 @@ namespace Siger.ApiWMS.Controllers
}
}
else
else
{
{
if
(
Location
.
id
==
locationTypeId
)
{
var
locationIdExist
=
location
.
Get
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
typeid
==
locationTypeId
&&
q
.
locationid
==
req
.
storeID
.
ToInt
()
&&
q
.
id
!=
Location
.
locationid
.
ToInt
()
&&
q
.
storageid
==
req
.
warehouseid
);
if
(
locationIdExist
!=
null
)
{
throw
new
BadRequestException
(
RequestEnum
.
IDExist
);
}
}
tmp
.
status
=
req
.
status
==
(
int
)
RowState
.
Valid
?
(
int
)
RowState
.
Valid
:
(
int
)
RowState
.
Invalid
;
tmp
.
status
=
req
.
status
==
(
int
)
RowState
.
Valid
?
(
int
)
RowState
.
Valid
:
(
int
)
RowState
.
Invalid
;
tmp
.
locationid
=
Location
.
id
==
locationTypeId
?
req
.
storeID
.
ToInt
()
:
0
;
tmp
.
locationid
=
Location
.
id
==
locationTypeId
?
req
.
storeID
.
ToInt
()
:
0
;
parentid
=
InsertLocation
(
tmp
,
waveHouse
.
name
);
parentid
=
InsertLocation
(
tmp
,
waveHouse
.
name
);
...
...
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