Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hg-smart
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
platform
hg-smart
Commits
52073409
Commit
52073409
authored
Jun 06, 2024
by
wuwenlong
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
f11b3af7
f42ec271
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
115 additions
and
66 deletions
+115
-66
DdynamicEnum.java
src/main/java/com/baosight/hggp/common/DdynamicEnum.java
+8
-0
HGKC006A.java
src/main/java/com/baosight/hggp/hg/kc/domain/HGKC006A.java
+22
-1
ServiceHGKC006A.java
...java/com/baosight/hggp/hg/kc/service/ServiceHGKC006A.java
+2
-11
HGKC006A.xml
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC006A.xml
+7
-1
ServiceHGPZ005.java
.../java/com/baosight/hggp/hg/pz/service/ServiceHGPZ005.java
+27
-9
HGYX001C.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001C.xml
+1
-1
HGKC006.js
src/main/webapp/HG/KC/HGKC006.js
+0
-1
HGKC006A.js
src/main/webapp/HG/KC/HGKC006A.js
+35
-28
HGKC006A.jsp
src/main/webapp/HG/KC/HGKC006A.jsp
+5
-6
HGKC007A.jsp
src/main/webapp/HG/KC/HGKC007A.jsp
+2
-2
HGYX001A.jsp
src/main/webapp/HG/YX/HGYX001A.jsp
+6
-6
No files found.
src/main/java/com/baosight/hggp/common/DdynamicEnum.java
View file @
52073409
...
...
@@ -115,6 +115,14 @@ public enum DdynamicEnum {
INVENT_ALL_BOX_BLOCK_ID
(
"invent_all_box_block_id"
,
"id"
,
"spec"
,
"material"
,
"unit"
,
"length"
,
"width"
,
"thick"
,
"coefficient"
,
"status"
,
"HGPZ005.queryInventBoxAll"
),
/**
* 模块:规格下拉框
* 用途:入库下拉框
* 编写:jhs
*/
INVENT_SPEC_BOX_BLOCK_ID
(
"invent_spec_box_block_id"
,
"spec"
,
"spec"
,
"length"
,
"width"
,
"thick"
,
"coefficient"
,
"id"
,
"status"
,
"HGPZ005.queryInventBoxAll"
),
/**
* 模块:存货档案(ALL 不默认状态)
...
...
src/main/java/com/baosight/hggp/hg/kc/domain/HGKC006A.java
View file @
52073409
...
...
@@ -62,11 +62,12 @@ public class HGKC006A extends DaoEPBase {
public
static
final
String
FIELD_PART_TYPE
=
"partType"
;
/* 零件类型*/
public
static
final
String
FIELD_PART_CODE
=
"partCode"
;
/* 零件编码*/
public
static
final
String
FIELD_PART_NAME
=
"partName"
;
/* 零件名称*/
public
static
final
String
FIELD_PART_LENGTH
=
"partLength"
;
/* 零件-长*/
public
static
final
String
FIELD_PART_LENGTH
=
"partLength"
;
/* 零件-长*/
public
static
final
String
FIELD_PART_WIDTH
=
"partWidth"
;
/* 零件-宽*/
public
static
final
String
FIELD_PART_THICK
=
"partThick"
;
/* 零件-厚*/
public
static
final
String
FIELD_PART_SPEC
=
"partSpec"
;
/* 零件规格*/
public
static
final
String
FIELD_PART_SPEC_ID
=
"partSpecId"
;
/* 零件规格ID*/
public
static
final
String
FIELD_PART_COEFFICIENT
=
"partCoefficient"
;
/* 零件系数*/
public
static
final
String
FIELD_PRIMARY_ID
=
"primaryId"
;
/* 主表id*/
public
static
final
String
FIELD_PRICE
=
"price"
;
/* 单价*/
...
...
@@ -118,6 +119,7 @@ public class HGKC006A extends DaoEPBase {
public
static
final
String
COL_PART_THICK
=
"PART_THICK"
;
/* 零件-厚*/
public
static
final
String
COL_PART_SPEC
=
"PART_SPEC"
;
/* 零件规格*/
public
static
final
String
COL_PART_SPEC_ID
=
"PART_SPEC_ID"
;
/* 零件规格ID*/
public
static
final
String
COL_PART_COEFFICIENT
=
"PART_COEFFICIENT"
;
/* 零件系数*/
public
static
final
String
COL_PRIMARY_ID
=
"PRIMARY_ID"
;
/* 主表id*/
public
static
final
String
COL_PRICE
=
"PRICE"
;
/* 单价*/
public
static
final
String
COL_AMOUNT
=
"AMOUNT"
;
/* 金额*/
...
...
@@ -173,6 +175,7 @@ public class HGKC006A extends DaoEPBase {
private
BigDecimal
partWidth
=
new
BigDecimal
(
0.000
);
/* 零件-宽*/
private
BigDecimal
partThick
=
new
BigDecimal
(
0.000
);
/* 零件-厚*/
private
String
partSpec
=
" "
;
/* 零件规格*/
private
BigDecimal
partCoefficient
=
new
BigDecimal
(
0.000
);
/* 零件-系数*/
private
Long
partSpecId
=
new
Long
(
0
);
/* 规格id*/
private
Long
primaryId
=
new
Long
(
0
);
/* 主表id*/
private
BigDecimal
price
=
new
BigDecimal
(
"0"
);
/* 单价*/
...
...
@@ -385,6 +388,14 @@ public class HGKC006A extends DaoEPBase {
eiColumn
.
setDescName
(
"零件-厚"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_PART_COEFFICIENT
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
3
);
eiColumn
.
setFieldLength
(
12
);
eiColumn
.
setDescName
(
"零件-系数"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_PART_SPEC
);
eiColumn
.
setDescName
(
"零件规格"
);
eiMetadata
.
addMeta
(
eiColumn
);
...
...
@@ -1202,6 +1213,14 @@ public class HGKC006A extends DaoEPBase {
this
.
partSpecId
=
partSpecId
;
}
public
BigDecimal
getPartCoefficient
()
{
return
partCoefficient
;
}
public
void
setPartCoefficient
(
BigDecimal
partCoefficient
)
{
this
.
partCoefficient
=
partCoefficient
;
}
/**
* get the value from Map.
*
...
...
@@ -1253,6 +1272,7 @@ public class HGKC006A extends DaoEPBase {
setPartLength
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_PART_LENGTH
)),
partLength
));
setPartWidth
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_PART_WIDTH
)),
partWidth
));
setPartThick
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_PART_THICK
)),
partThick
));
setPartCoefficient
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_PART_COEFFICIENT
)),
partCoefficient
));
setPartSpec
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_PART_SPEC
)),
partSpec
));
setPartSpecId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_PART_SPEC_ID
)),
partSpecId
));
setPrimaryId
(
NumberUtils
.
toLong
(
StringUtils
.
toString
(
map
.
get
(
FIELD_PRIMARY_ID
)),
primaryId
));
...
...
@@ -1311,6 +1331,7 @@ public class HGKC006A extends DaoEPBase {
map
.
put
(
FIELD_PART_LENGTH
,
StringUtils
.
toString
(
partLength
,
eiMetadata
.
getMeta
(
FIELD_PART_LENGTH
)));
map
.
put
(
FIELD_PART_WIDTH
,
StringUtils
.
toString
(
partWidth
,
eiMetadata
.
getMeta
(
FIELD_PART_WIDTH
)));
map
.
put
(
FIELD_PART_THICK
,
StringUtils
.
toString
(
partThick
,
eiMetadata
.
getMeta
(
FIELD_PART_THICK
)));
map
.
put
(
FIELD_PART_COEFFICIENT
,
StringUtils
.
toString
(
partCoefficient
,
eiMetadata
.
getMeta
(
FIELD_PART_COEFFICIENT
)));
map
.
put
(
FIELD_PART_SPEC
,
StringUtils
.
toString
(
partSpec
,
eiMetadata
.
getMeta
(
FIELD_PART_SPEC
)));
map
.
put
(
FIELD_PART_SPEC_ID
,
StringUtils
.
toString
(
partSpecId
,
eiMetadata
.
getMeta
(
FIELD_PART_SPEC_ID
)));
map
.
put
(
FIELD_PRIMARY_ID
,
StringUtils
.
toString
(
primaryId
,
eiMetadata
.
getMeta
(
FIELD_PRIMARY_ID
)));
...
...
src/main/java/com/baosight/hggp/hg/kc/service/ServiceHGKC006A.java
View file @
52073409
...
...
@@ -41,7 +41,7 @@ public class ServiceHGKC006A extends ServiceBase {
map
.
put
(
HGKC006A
.
FIELD_WH_CODE
,
whCode
);
map
.
put
(
HGKC006A
.
FIELD_COMPANY_CODE
,
companyCode
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
INVENT_TYPE_BOX_BLOCK_ID
,
DdynamicEnum
.
INVENT_
CODE_BOX_BLOCK_ID
,
DdynamicEnum
.
SPEC_BOX_BLOCK_ID
),
map
,
false
Arrays
.
asList
(
DdynamicEnum
.
INVENT_TYPE_BOX_BLOCK_ID
,
DdynamicEnum
.
INVENT_
RECORD_BLOCK_ID
,
DdynamicEnum
.
INVENT_
SPEC_BOX_BLOCK_ID
),
map
,
false
);
inInfo
.
addBlock
(
EiConstant
.
resultBlock
).
addBlockMeta
(
new
HGKC006A
().
eiMetadata
);
}
catch
(
PlatException
e
)
{
...
...
@@ -68,7 +68,7 @@ public class ServiceHGKC006A extends ServiceBase {
map
.
put
(
HGKC006A
.
FIELD_WH_CODE
,
whCode
);
map
.
put
(
HGKC006A
.
FIELD_COMPANY_CODE
,
companyCode
);
CommonMethod
.
initBlock
(
inInfo
,
Arrays
.
asList
(
DdynamicEnum
.
INVENT_TYPE_BOX_BLOCK_ID
,
DdynamicEnum
.
INVENT_
CODE_BOX_BLOCK_ID
,
DdynamicEnum
.
SPEC_BOX_BLOCK_ID
),
map
,
false
Arrays
.
asList
(
DdynamicEnum
.
INVENT_TYPE_BOX_BLOCK_ID
,
DdynamicEnum
.
INVENT_
RECORD_BLOCK_ID
,
DdynamicEnum
.
INVENT_
SPEC_BOX_BLOCK_ID
),
map
,
false
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
...
...
@@ -126,15 +126,6 @@ public class ServiceHGKC006A extends ServiceBase {
AssertUtils
.
isEmpty
(
UserSessionUtils
.
getAccountCode
(),
"当前用户未绑定公司,无法操作数据,请联系管理员!"
);
AssertUtils
.
isEmpty
(
UserSessionUtils
.
getOrgId
(),
"当前用户未绑定部门,无法操作数据,请联系管理员!"
);
AssertUtils
.
isNull
(
hgkc006a
.
getPrimaryId
(),
"未获取到其他入库单ID信息"
);
HGKC010
hgkc010
=
HGKCTools
.
HgKc010
.
get
(
hgkc006a
.
getCompanyCode
(),
hgkc006a
.
getWhCode
(),
hgkc006a
.
getPartSpecId
());
if
(
hgkc010
==
null
){
throw
new
PlatException
(
"实时库存不存在!"
);
}
int
result
=
hgkc006a
.
getInvQty
().
compareTo
(
hgkc010
.
getInvQty
());
if
(
result
>
0
){
throw
new
PlatException
(
"实时库存数量不够,无法保存!"
);
}
}
/**
...
...
src/main/java/com/baosight/hggp/hg/kc/sql/HGKC006A.xml
View file @
52073409
...
...
@@ -132,6 +132,9 @@
<isNotEmpty
prepend=
" AND "
property=
"partThick"
>
PART_THICK = #partThick#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"partCoefficient"
>
PART_COEFFICIENT = #partCoefficient#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"partSpec"
>
PART_SPEC = #partSpec#
</isNotEmpty>
...
...
@@ -198,6 +201,7 @@
PART_LENGTH as "partLength",
<!-- 零件-长 -->
PART_WIDTH as "partWidth",
<!-- 零件-宽 -->
PART_THICK as "partThick",
<!-- 零件-厚 -->
PART_COEFFICIENT as "partCoefficient",
<!-- 零件-系数 -->
PART_SPEC as "partSpec",
<!-- 零件规格 -->
PART_SPEC_ID as "partSpecId",
<!-- 零件规格id -->
PRIMARY_ID as "primaryId",
<!-- 主表id -->
...
...
@@ -267,6 +271,7 @@
PART_LENGTH,
<!-- 零件-长 -->
PART_WIDTH,
<!-- 零件-宽 -->
PART_THICK,
<!-- 零件-厚 -->
PART_COEFFICIENT,
<!-- 零件系数 -->
PART_SPEC,
<!-- 零件规格 -->
PART_SPEC_ID,
<!-- 零件规格id -->
PRIMARY_ID,
<!-- 主表id -->
...
...
@@ -274,7 +279,7 @@
AMOUNT,
<!-- 金额 -->
SOURCE
<!-- 数据来源 -->
)
VALUES (#id#, #accountCode#, #depCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #deleteFlag#, #companyCode#, #companyName#, #otherEnterDate#, #otherEnterNo#, #whCode#, #whName#, #inventRecordId#, #inventType#, #inventCode#, #inventName#, #invQty#, #invUnitWeight#, #invWeight#, #otherEnterNoOld#, #remark#, #factoryCode#, #prodOrderNo#, #prodTaskNo#, #projCode#, #projName#, #prdtType#, #prdtCode#, #prdtName#, #prdtLength#, #prdtWidth#, #prdtThick#, #prdtSpec#, #partType#, #partCode#, #partName#, #partLength#, #partWidth#, #partThick#, #partSpec#,#partSpecId#, #primaryId#, #price#, #amount#, #source#)
VALUES (#id#, #accountCode#, #depCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #deleteFlag#, #companyCode#, #companyName#, #otherEnterDate#, #otherEnterNo#, #whCode#, #whName#, #inventRecordId#, #inventType#, #inventCode#, #inventName#, #invQty#, #invUnitWeight#, #invWeight#, #otherEnterNoOld#, #remark#, #factoryCode#, #prodOrderNo#, #prodTaskNo#, #projCode#, #projName#, #prdtType#, #prdtCode#, #prdtName#, #prdtLength#, #prdtWidth#, #prdtThick#, #prdtSpec#, #partType#, #partCode#, #partName#, #partLength#, #partWidth#, #partThick#, #part
Coefficient#, #part
Spec#,#partSpecId#, #primaryId#, #price#, #amount#, #source#)
</insert>
<delete
id=
"delete"
>
...
...
@@ -326,6 +331,7 @@
PART_LENGTH = #partLength#,
<!-- 零件-长 -->
PART_WIDTH = #partWidth#,
<!-- 零件-宽 -->
PART_THICK = #partThick#,
<!-- 零件-厚 -->
PART_COEFFICIENT = #partCoefficient#,
<!-- 零件-系数 -->
PART_SPEC = #partSpec#,
<!-- 零件规格 -->
PART_SPEC_ID = #partSpecId#,
<!-- 零件规格id -->
PRIMARY_ID = #primaryId#,
<!-- 主表id -->
...
...
src/main/java/com/baosight/hggp/hg/pz/service/ServiceHGPZ005.java
View file @
52073409
...
...
@@ -37,7 +37,7 @@ import java.util.*;
* @date:2024/1/15,11:20
*/
public
class
ServiceHGPZ005
extends
ServiceBase
{
/**
* 画面初始化
*
...
...
@@ -55,7 +55,7 @@ public class ServiceHGPZ005 extends ServiceBase {
}
return
inInfo
;
}
/**
* 查询数据列表
*
...
...
@@ -72,7 +72,7 @@ public class ServiceHGPZ005 extends ServiceBase {
}
return
inInfo
;
}
/**
* 保存操作.
*
...
...
@@ -110,7 +110,7 @@ public class ServiceHGPZ005 extends ServiceBase {
}
return
inInfo
;
}
/**
* 校验保存的数据
*
...
...
@@ -124,7 +124,7 @@ public class ServiceHGPZ005 extends ServiceBase {
AssertUtils
.
isNull
(
hgpz005
.
getStatus
(),
"是否启用不能为空"
);
}
}
/**
* 新增企业信息
*
...
...
@@ -135,7 +135,7 @@ public class ServiceHGPZ005 extends ServiceBase {
hgpz005
.
setInventCode
(
SequenceGenerator
.
getNextSequence
(
HGConstant
.
SequenceId
.
INVENT_CODE
));
DaoUtils
.
insert
(
HGPZ005
.
INSERT
,
hgpz005
);
}
/**
* 修改数据
*
...
...
@@ -144,7 +144,7 @@ public class ServiceHGPZ005 extends ServiceBase {
private
void
modify
(
HGPZ005
hgpz005
)
{
DaoUtils
.
update
(
HGPZ005
.
UPDATE
,
hgpz005
);
}
/**
* 新增操作.
*
...
...
@@ -173,7 +173,7 @@ public class ServiceHGPZ005 extends ServiceBase {
return
inInfo
;
}
/**
* 修改操作
*
...
...
@@ -199,7 +199,7 @@ public class ServiceHGPZ005 extends ServiceBase {
}
return
inInfo
;
}
/**
* 删除操作
*
...
...
@@ -301,6 +301,24 @@ public class ServiceHGPZ005 extends ServiceBase {
return
inInfo
;
}
/**
* 下拉框
*
* @param inInfo
* @return
*/
@OperationLogAnnotation
(
operModul
=
"存货档案规格下拉框"
,
operType
=
"查询"
,
operDesc
=
"下拉框(不默认状态)"
)
public
EiInfo
queryInventSpecBox
(
EiInfo
inInfo
)
{
try
{
List
<
DdynamicEnum
>
list
=
new
ArrayList
<>();
list
.
add
(
DdynamicEnum
.
INVENT_SPEC_BOX_BLOCK_ID
);
CommonMethod
.
initBlock
(
inInfo
,
list
,
EiInfoUtils
.
getFirstRow
(
inInfo
),
false
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询规格失败"
);
}
return
inInfo
;
}
public
EiInfo
queryInventNameBox
(
EiInfo
inInfo
)
{
try
{
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX001C.xml
View file @
52073409
...
...
@@ -120,7 +120,7 @@
SELECT
<include
refid=
"column"
/>
FROM ${hggpSchema}.HGKC010
WHERE 1=1
WHERE 1=1
AND INV_QTY >0
<include
refid=
"condition"
/>
<include
refid=
"orderBy"
/>
</select>
...
...
src/main/webapp/HG/KC/HGKC006.js
View file @
52073409
let
whNameGlobalData
=
[];
$
(
function
()
{
var
companyCodes
=
__eiInfo
.
getBlock
(
"companyBox_block_id"
).
getMappedRows
();
IPLATUI
.
EFGrid
.
result
=
{
...
...
src/main/webapp/HG/KC/HGKC006A.js
View file @
52073409
...
...
@@ -2,8 +2,8 @@ $(function () {
$
(
".row"
).
children
().
attr
(
"class"
,
"col-md-3"
);
var
inventRecordBoxBlocks
=
__eiInfo
.
getBlock
(
"invent_
code_box
_block_id"
).
getMappedRows
();
var
specBoxBlocks
=
__eiInfo
.
getBlock
(
"spec_box_block_id"
).
getMappedRows
();
var
inventRecordBoxBlocks
=
__eiInfo
.
getBlock
(
"invent_
record
_block_id"
).
getMappedRows
();
var
specBoxBlocks
=
__eiInfo
.
getBlock
(
"
invent_
spec_box_block_id"
).
getMappedRows
();
// 查询
$
(
"#QUERY"
).
on
(
"click"
,
query
);
...
...
@@ -58,26 +58,12 @@ $(function () {
return
template
;
},
editor
:
function
(
container
,
options
)
{
let
inInfo
=
new
EiInfo
();
inInfo
.
set
(
"inqu_status-0-whCode"
,
options
.
model
[
"whCode"
]);
inInfo
.
set
(
"inqu_status-0-companyCode"
,
options
.
model
[
"companyCode"
]);
inInfo
.
set
(
"inqu_status-0-inventType"
,
options
.
model
[
"inventType"
]);
inInfo
.
set
(
"inqu_status-0-inventCode"
,
options
.
model
[
"inventCode"
]);
inInfo
.
set
(
"field"
,
options
.
field
);
let
dataSource
;
EiCommunicator
.
send
(
"HGKC010"
,
"querySpecBox"
,
inInfo
,
{
onSuccess
:
function
(
ei
)
{
dataSource
=
ei
.
getBlock
(
"spec_box_block_id"
).
getMappedRows
();
},
onFail
:
function
(
ei
)
{
}
},
{
async
:
false
});
var
input
=
$
(
'<input />'
);
input
.
attr
(
"name"
,
options
.
field
);
input
.
attr
(
"id"
,
options
.
field
);
input
.
appendTo
(
container
);
input
.
kendoDropDownList
({
dataSource
:
dataSource
,
dataSource
:
specBoxBlocks
,
minLength
:
0
,
dataTextField
:
"textField"
,
dataValueField
:
"valueField"
,
...
...
@@ -89,6 +75,13 @@ $(function () {
}
},
{
field
:
"invQty"
,
template
:
function
(
item
)
{
calUnitWeight
(
item
,
item
.
partLength
,
item
.
partWidth
,
item
.
partThick
,
item
.
partCoefficient
);
return
item
.
invQty
==
0
?
"-"
:
item
.
invQty
;
}
},
{
field
:
"primaryId"
,
template
:
function
(
item
)
{
item
[
'primaryId'
]
=
$
(
"#inqu_status-0-primaryId"
).
val
();
...
...
@@ -98,11 +91,10 @@ $(function () {
{
field
:
"whCode"
,
template
:
function
(
item
)
{
item
[
'whCode'
]
=
$
(
"#inqu_status-0-whCode"
).
val
();
item
[
'whCode'
]
=
$
(
"#inqu_status-0-whCode"
).
val
();
return
$
(
"#inqu_status-0-whCode"
).
val
();
}
}
,
},
{
field
:
"companyCode"
,
template
:
function
(
item
)
{
...
...
@@ -125,6 +117,7 @@ $(function () {
let
totalAmount
=
item
.
price
*
item
.
invQty
;
resultGrid
.
setCellValue
(
item
,
'amount'
,
totalAmount
)
}
calUnitWeight
(
item
,
item
.
partLength
,
item
.
partWidth
,
item
.
partThick
,
item
.
partCoefficient
);
loadChange
(
grid
,
e
,
"price"
);
}
//单价计算
...
...
@@ -137,12 +130,10 @@ $(function () {
if
(
e
.
field
==
"inventType"
)
{
//选择后,先加载此方法,再加载属性中的方法,所以存货类型加载时,先修改存货编号下拉框的查询
let
inInfo
=
new
EiInfo
();
inInfo
.
set
(
"inqu_status-0-whCode"
,
item
.
whCode
);
inInfo
.
set
(
"inqu_status-0-companyCode"
,
item
.
companyCode
);
inInfo
.
set
(
"inqu_status-0-inventType"
,
item
.
inventType
);
EiCommunicator
.
send
(
"HG
KC010"
,
"queryInventCode
Box"
,
inInfo
,
{
EiCommunicator
.
send
(
"HG
PZ005"
,
"queryCombo
Box"
,
inInfo
,
{
onSuccess
:
function
(
ei
)
{
inventRecordBoxBlocks
=
ei
.
getBlock
(
"invent_
code_box
_block_id"
).
getMappedRows
();
inventRecordBoxBlocks
=
ei
.
getBlock
(
"invent_
record
_block_id"
).
getMappedRows
();
},
onFail
:
function
(
ei
)
{
}
...
...
@@ -166,6 +157,16 @@ $(function () {
resultGrid
.
setCellValue
(
item
,
'inventName'
,
inventRecordBoxBlocks
[
i
][
'textField'
])
}
}
let
specInInfo
=
new
EiInfo
();
specInInfo
.
set
(
"inqu_status-0-inventType"
,
item
.
inventType
);
specInInfo
.
set
(
"inqu_status-0-inventCode"
,
item
.
inventCode
);
EiCommunicator
.
send
(
"HGPZ005"
,
"queryInventSpecBox"
,
specInInfo
,
{
onSuccess
:
function
(
ei
)
{
specBoxBlocks
=
ei
.
getBlock
(
"invent_spec_box_block_id"
).
getMappedRows
();
},
onFail
:
function
(
ei
)
{
}
},
{
async
:
false
});
resultGrid
.
setCellValue
(
item
,
'partSpecId'
,
""
)
resultGrid
.
setCellValue
(
item
,
'partSpec'
,
""
)
resultGrid
.
setCellValue
(
item
,
'partLength'
,
""
)
...
...
@@ -182,10 +183,9 @@ $(function () {
resultGrid
.
setCellValue
(
item
,
'partLength'
,
specBoxBlocks
[
i
][
'param1Field'
])
resultGrid
.
setCellValue
(
item
,
'partWidth'
,
specBoxBlocks
[
i
][
'param2Field'
])
resultGrid
.
setCellValue
(
item
,
'partThick'
,
specBoxBlocks
[
i
][
'param3Field'
])
resultGrid
.
setCellValue
(
item
,
'invQty'
,
specBoxBlocks
[
i
][
'param4Field'
])
resultGrid
.
setCellValue
(
item
,
'invUnitWeight'
,
specBoxBlocks
[
i
][
'param5Field'
])
resultGrid
.
setCellValue
(
item
,
'invWeight'
,
specBoxBlocks
[
i
][
'param6Field'
])
resultGrid
.
setCellValue
(
item
,
'partSpecId'
,
specBoxBlocks
[
i
][
'param7Field'
])
resultGrid
.
setCellValue
(
item
,
'partCoefficient'
,
specBoxBlocks
[
i
][
'param4Field'
])
resultGrid
.
setCellValue
(
item
,
'partSpecId'
,
specBoxBlocks
[
i
][
'param5Field'
])
calUnitWeight
(
item
,
item
.
partLength
,
item
.
partWidth
,
item
.
partThick
,
item
.
partCoefficient
);
}
}
resultGrid
.
setCellValue
(
item
,
'price'
,
""
)
...
...
@@ -236,6 +236,13 @@ let query = function () {
resultGrid
.
dataSource
.
page
(
1
);
}
let
calUnitWeight
=
function
(
item
,
length
,
width
,
thick
,
coefficient
)
{
if
(
length
&&
width
&&
thick
&&
coefficient
){
let
amount
=
length
*
width
*
thick
*
coefficient
/
1000000
;
//item['amount'] = amount.toString();
resultGrid
.
setCellValue
(
item
,
'invUnitWeight'
,
amount
);
}
}
/**
* 保存
*/
...
...
src/main/webapp/HG/KC/HGKC006A.jsp
View file @
52073409
...
...
@@ -43,15 +43,15 @@
columnTemplate=
"#=textField#"
itemTemplate=
"#=textField#"
readonly=
"false"
filter=
"contains"
>
</EF:EFComboColumn>
<EF:EFColumn
ename=
"inventCode"
cname=
"存货
名称
"
width=
"120"
align=
"center"
required=
"true"
readonly=
"true"
/>
<EF:EFColumn
ename=
"inventName"
cname=
"存货名称"
hidden=
"tru
e"
/>
<EF:EFColumn
ename=
"inventCode"
cname=
"存货
编码
"
width=
"120"
align=
"center"
required=
"true"
readonly=
"true"
/>
<EF:EFColumn
ename=
"inventName"
cname=
"存货名称"
width=
"120"
align=
"center"
required=
"true"
enable=
"fals
e"
/>
<EF:EFColumn
ename=
"partSpec"
cname=
"规格"
width=
"120"
align=
"center"
required=
"true"
enable=
"true"
/>
<EF:EFColumn
ename=
"partSpecId"
cname=
"规格id"
hidden=
"true"
/>
<EF:EFColumn
ename=
"inventRecordId"
cname=
"存货档案id"
width=
"120"
align=
"center"
required=
"true"
enable=
"false"
hidden=
"true"
/>
<EF:EFColumn
ename=
"partLength"
cname=
"长(MM)"
enable=
"false"
width=
"80"
align=
"right"
format=
"{0:N3}"
/>
<EF:EFColumn
ename=
"partWidth"
cname=
"宽(MM)"
enable=
"false"
width=
"80"
align=
"right"
format=
"{0:N3}"
/>
<EF:EFColumn
ename=
"partThick"
cname=
"厚(MM)"
enable=
"false"
width=
"80"
align=
"right"
format=
"{0:N3}"
/>
<EF:EFColumn
ename=
"
coefficient"
cname=
"系数"
width=
"80"
align=
"right"
format=
"{0:N2}"
maxLength=
"10"
enable=
"false"
hidden=
"true
"
/>
<EF:EFColumn
ename=
"
partCoefficient"
cname=
"系数"
enable=
"false"
width=
"80"
align=
"right"
format=
"{0:N3}
"
/>
<EF:EFColumn
ename=
"invQty"
cname=
"数量"
width=
"120"
align=
"right"
format=
"{0:N0}"
defaultValue=
"0"
data-regex=
"/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
...
...
@@ -60,10 +60,9 @@
<EF:EFColumn
ename=
"invUnitWeight"
cname=
"单重"
width=
"120"
align=
"right"
format=
"{0:N3}"
defaultValue=
"0"
data-regex=
"/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt=
"请输入数字,该值最大可设置17位整数和3位小数!"
/>
data-errorprompt=
"请输入数字,该值最大可设置17位整数和3位小数!"
enable=
"false"
/>
<EF:EFColumn
ename=
"invWeight"
cname=
"总重"
width=
"120"
align=
"right"
enable=
"false"
format=
"{0:N3}"
/>
<EF:EFColumn
ename=
"prdtCode"
cname=
"部件编码"
enable=
"false"
width=
"120"
align=
"center"
hidden=
"true"
/>
<EF:EFColumn
ename=
"partCode"
cname=
"零件编码"
enable=
"false"
width=
"120"
align=
"center"
hidden=
"true"
/>
<EF:EFColumn
ename=
"price"
cname=
"单价"
width=
"120"
align=
"right"
format=
"{0:N3}"
defaultValue=
"0"
data-regex=
"/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
...
...
src/main/webapp/HG/KC/HGKC007A.jsp
View file @
52073409
...
...
@@ -35,8 +35,8 @@
columnTemplate=
"#=textField#"
itemTemplate=
"#=textField#"
readonly=
"false"
filter=
"contains"
>
</EF:EFComboColumn>
<EF:EFColumn
ename=
"inventCode"
cname=
"存货
名称
"
width=
"120"
align=
"center"
required=
"true"
readonly=
"true"
/>
<EF:EFColumn
ename=
"inventName"
cname=
"存货名称"
hidden=
"tru
e"
/>
<EF:EFColumn
ename=
"inventCode"
cname=
"存货
编码
"
width=
"120"
align=
"center"
required=
"true"
readonly=
"true"
/>
<EF:EFColumn
ename=
"inventName"
cname=
"存货名称"
width=
"120"
align=
"center"
required=
"true"
enable=
"fals
e"
/>
<EF:EFColumn
ename=
"partSpec"
cname=
"规格"
width=
"120"
align=
"center"
enable=
"true"
required=
"true"
/>
<EF:EFColumn
ename=
"partSpecId"
cname=
"规格id"
hidden=
"true"
/>
<EF:EFColumn
ename=
"inventRecordId"
cname=
"规格id"
width=
"120"
align=
"center"
required=
"true"
enable=
"false"
hidden=
"true"
/>
...
...
src/main/webapp/HG/YX/HGYX001A.jsp
View file @
52073409
...
...
@@ -72,25 +72,25 @@
<EF:EFRegion id="result" title="明细信息">
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true">
<EF:EFColumn ename="id" cname="主键" hidden="true"/>
<EF:EFComboColumn ename="inventType" cname="存货类型" enable="
tru
e" width="120" align="center" required="true"
<EF:EFComboColumn ename="inventType" cname="存货类型" enable="
fals
e" width="120" align="center" required="true"
blockName="invent_type_box_block_id" textField="textField" valueField="valueField"
columnTemplate="#=textField#" itemTemplate="#=textField#" readonly="false"
filter="contains">
</EF:EFComboColumn>
<EF:EFComboColumn ename="inventCode" cname="存货名称" enable="
tru
e" width="120" align="center" required="true"
<EF:EFComboColumn ename="inventCode" cname="存货名称" enable="
fals
e" width="120" align="center" required="true"
blockName="invent_code_box_block_id" textField="textField" valueField="valueField"
columnTemplate="#=textField#" itemTemplate="#=textField#" readonly="false"
filter="contains">
</EF:EFComboColumn>
<EF:EFComboColumn ename="spec" cname="规格" enable="
tru
e" width="120" align="center" required="true"
<EF:EFComboColumn ename="spec" cname="规格" enable="
fals
e" width="120" align="center" required="true"
blockName="spec_box_block_id" textField="textField" valueField="valueField"
columnTemplate="#=textField#" itemTemplate="#=textField#" readonly="false"
filter="contains">
</EF:EFComboColumn>
<EF:EFColumn ename="inventRecordId" cname="规格ID" width="120" enable="true" readonly="true" align="center" hidden="true" maxLength="50"/>
<EF:EFColumn ename="length" cname="长度(MM)" enable="
tru
e" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="
tru
e" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="
tru
e" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="length" cname="长度(MM)" enable="
fals
e" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="
fals
e" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="
fals
e" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N0}" editType="text"
displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
...
...
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