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
657f60cf
Commit
657f60cf
authored
Jan 27, 2021
by
xin.yang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
some update
parent
31eab02c
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
78 additions
and
3 deletions
+78
-3
en-US.js
Html/src/locale/lang/en-US.js
+3
-0
zh-CN.js
Html/src/locale/lang/zh-CN.js
+3
-0
storagemaintenance.vue
Html/src/view/wms/config/storagemaintenance.vue
+21
-0
LocationController.cs
Server/Apis/Siger.ApiWMS/Controllers/LocationController.cs
+37
-3
WaveHouseController.cs
Server/Apis/Siger.ApiWMS/Controllers/WaveHouseController.cs
+5
-0
RequestEnum.cs
Server/Common/Siger.Middlelayer.Share/Enum/RequestEnum.cs
+9
-0
No files found.
Html/src/locale/lang/en-US.js
View file @
657f60cf
...
...
@@ -721,6 +721,9 @@ export default {
'9000496'
:
'ID重复'
,
'9000497'
:
'父级和子级不能相同'
,
'9000498'
:
'该类型绑定了工装,不能删除'
,
'9000499'
:
'储位层级错误'
,
'9000500'
:
'该类别绑定了储位,不能删除'
,
'9000501'
:
'该仓库绑定了储位,不能删除'
,
'9100000'
:
'Departments cannot be empty'
,
'9100001'
:
'Position cannot be empty'
,
...
...
Html/src/locale/lang/zh-CN.js
View file @
657f60cf
...
...
@@ -748,6 +748,9 @@ export default {
'9000496'
:
'ID重复'
,
'9000497'
:
'父级和子级不能相同'
,
'9000498'
:
'该类型绑定了工装,不能删除'
,
'9000499'
:
'储位层级错误'
,
'9000500'
:
'该类别绑定了储位,不能删除'
,
'9000501'
:
'该仓库绑定了储位,不能删除'
,
'9100000'
:
'部门不能为空'
,
...
...
Html/src/view/wms/config/storagemaintenance.vue
View file @
657f60cf
...
...
@@ -292,6 +292,27 @@ export default {
},
//添加提交
addPost
(){
if
(
!
this
.
stid
){
this
.
$Message
.
error
(
"请填写ID"
);
return
false
;
}
if
(
!
this
.
whid1
){
this
.
$Message
.
error
(
"请选择仓库"
);
return
false
;
}
if
(
!
this
.
sTypes
||
this
.
sTypes
.
length
===
0
){
this
.
$Message
.
error
(
"请填写储位层级"
);
return
false
;
}
else
{
for
(
var
i
=
0
;
i
<
this
.
sTypes
.
length
;
i
++
){
if
(
!
this
.
sTypes
[
i
].
val
){
this
.
$Message
.
error
(
"请填写"
+
this
.
sTypes
[
i
].
name
);
return
false
;
}
}
}
let
code
=
0
;
if
(
!
this
.
stid
){
code
=
1
;
...
...
Server/Apis/Siger.ApiWMS/Controllers/LocationController.cs
View file @
657f60cf
...
...
@@ -21,6 +21,7 @@ using Siger.Middlelayer.WmsRepository.Repositories.Interface;
using
Siger.Middlelayer.WmsRepository.Request
;
using
Siger.Middlelayer.WmsRepository.Response
;
using
Siger.Middlelayer.Common.Extensions
;
using
Siger.Middlelayer.Log
;
namespace
Siger.ApiWMS.Controllers
{
...
...
@@ -237,6 +238,10 @@ namespace Siger.ApiWMS.Controllers
throw
new
BadRequestException
(
CommonEnum
.
LayerNotClean
);
}
//存在此列表记录
if
(
location
.
GetList
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
typeid
==
req
.
id
).
Any
())
{
throw
new
BadRequestException
(
RequestEnum
.
CategoryBindLocationData
);
}
entity
.
status
=
(
int
)
RowState
.
Invalid
;
entity
.
update_time
=
DateTime
.
Now
;
...
...
@@ -396,7 +401,7 @@ namespace Siger.ApiWMS.Controllers
locationData
=
locationAllData
.
Where
(
f
=>
typeids
.
Contains
(
f
.
typeid
)).
Skip
((
page
-
1
)
*
pageSize
).
Take
(
pageSize
).
ToList
();
}
Dictionary
<
int
,
string
>
waveHouseDic
=
new
Dictionary
<
int
,
string
>();
storage
.
GetList
(
f
=>
f
.
status
==
(
int
)
RowState
.
Valid
&&
f
.
projectid
==
ProjectId
).
Select
(
f
=>
new
{
f
.
id
,
f
.
name
}).
ToList
().
ForEach
(
f
=>
storage
.
GetList
(
f
=>
f
.
projectid
==
ProjectId
).
Select
(
f
=>
new
{
f
.
id
,
f
.
name
}).
ToList
().
ForEach
(
f
=>
{
waveHouseDic
.
Add
(
f
.
id
,
f
.
name
);
});
...
...
@@ -413,7 +418,7 @@ namespace Siger.ApiWMS.Controllers
{
id
=
item
.
id
,
pid
=
item
.
parentid
,
storageName
=
waveHouseDic
[
item
.
storageid
]
,
storageName
=
waveHouseDic
.
ContainsKey
(
item
.
storageid
)
?
waveHouseDic
[
item
.
storageid
]
:
""
,
serialNumber
=
item
.
serial_number
,
state
=
item
.
status
,
field
=
new
List
<
FiledName
>(),
...
...
@@ -458,8 +463,9 @@ namespace Siger.ApiWMS.Controllers
}
result
.
Add
(
tmp
);
}
catch
(
Exception
)
catch
(
Exception
e
)
{
Logger
.
WriteLineError
(
e
.
Message
);
}
}
...
...
@@ -927,6 +933,20 @@ namespace Siger.ApiWMS.Controllers
throw
new
BadRequestException
(
RequestEnum
.
LocationTypeNotFound
);
}
var
sonLocationTypes
=
GetSonTypes
(
0
,
locationTypes
).
ToList
();
if
(
req
.
storeArr
.
Count
!=
sonLocationTypes
.
Count
)
{
throw
new
BadRequestException
(
RequestEnum
.
LocationLevelError
);
}
foreach
(
var
store
in
req
.
storeArr
)
{
if
(
string
.
IsNullOrEmpty
(
store
.
val
))
{
throw
new
BadRequestException
(
RequestEnum
.
ParameterMiss
);
}
}
var
locationTypeId
=
sonLocationTypes
.
LastOrDefault
()?.
id
??
0
;
var
waveHouse
=
storage
.
Get
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
id
==
req
.
warehouseid
);
if
(
waveHouse
==
null
)
...
...
@@ -1060,6 +1080,20 @@ namespace Siger.ApiWMS.Controllers
throw
new
BadRequestException
(
RequestEnum
.
LocationTypeNotFound
);
}
var
sonLocationTypes
=
GetSonTypes
(
0
,
locationTypes
).
ToList
();
if
(
req
.
storeArr
.
Count
!=
sonLocationTypes
.
Count
)
{
throw
new
BadRequestException
(
RequestEnum
.
LocationLevelError
);
}
foreach
(
var
store
in
req
.
storeArr
)
{
if
(
string
.
IsNullOrEmpty
(
store
.
val
))
{
throw
new
BadRequestException
(
RequestEnum
.
ParameterMiss
);
}
}
var
locationTypeId
=
sonLocationTypes
.
LastOrDefault
()?.
id
??
0
;
var
waveHouse
=
storage
.
Get
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
id
==
req
.
warehouseid
);
if
(
waveHouse
==
null
)
...
...
Server/Apis/Siger.ApiWMS/Controllers/WaveHouseController.cs
View file @
657f60cf
...
...
@@ -188,6 +188,11 @@ namespace Siger.ApiWMS.Controllers
if
(
entity
==
null
)
throw
new
BadRequestException
(
CommonEnum
.
NoData
);
if
(
location
.
GetList
(
q
=>
q
.
projectid
==
ProjectId
&&
q
.
status
==
(
int
)
RowState
.
Valid
&&
q
.
storageid
==
req
.
id
).
Any
())
{
throw
new
BadRequestException
(
RequestEnum
.
WavehouseBindLocationData
);
}
entity
.
status
=
(
int
)
RowState
.
Valid
;
storage
.
Update
(
entity
);
if
(
_unitOfWork
.
Commit
()
>
0
)
...
...
Server/Common/Siger.Middlelayer.Share/Enum/RequestEnum.cs
View file @
657f60cf
...
...
@@ -1479,5 +1479,14 @@ namespace Siger.Middlelayer.Common
[
Description
(
"该类型绑定了工装,不能删除"
)]
CategoryBindFixtureToolData
,
[
Description
(
"储位层级错误"
)]
LocationLevelError
,
[
Description
(
"该类别绑定了储位,不能删除"
)]
CategoryBindLocationData
,
[
Description
(
"该仓库绑定了储位,不能删除"
)]
WavehouseBindLocationData
,
}
}
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