Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hp-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
hp-smart
Commits
993afb3e
Commit
993afb3e
authored
Mar 27, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2024-03-26 企业管理添加log上传
parent
7b2dbe38
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
366 additions
and
26 deletions
+366
-26
HPPZ009.java
src/main/java/com/baosight/hpjx/hp/pz/domain/HPPZ009.java
+33
-0
ServiceHPPZ009.java
.../java/com/baosight/hpjx/hp/pz/service/ServiceHPPZ009.java
+5
-0
HPPZ009.xml
src/main/java/com/baosight/hpjx/hp/pz/sql/HPPZ009.xml
+7
-1
iPlatV7-index.js
src/main/resources/META-INF/resources/iPlatV7-index.js
+9
-6
HPPZ009.js
src/main/webapp/HP/PZ/HPPZ009.js
+236
-12
HPPZ009.jsp
src/main/webapp/HP/PZ/HPPZ009.jsp
+76
-3
HPXS003.jsp
src/main/webapp/HP/XS/HPXS003.jsp
+0
-4
No files found.
src/main/java/com/baosight/hpjx/hp/pz/domain/HPPZ009.java
View file @
993afb3e
...
@@ -26,6 +26,8 @@ public class HPPZ009 extends DaoEPBase {
...
@@ -26,6 +26,8 @@ public class HPPZ009 extends DaoEPBase {
public
static
final
String
FIELD_COMPANY_NAME
=
"companyName"
;
/* 企业名称*/
public
static
final
String
FIELD_COMPANY_NAME
=
"companyName"
;
/* 企业名称*/
public
static
final
String
FIELD_VALID_FLAG
=
"validFlag"
;
/* 是否启用:1.启用,0.停用*/
public
static
final
String
FIELD_VALID_FLAG
=
"validFlag"
;
/* 是否启用:1.启用,0.停用*/
public
static
final
String
FIELD_LOGIN_PREFIX
=
"loginPrefix"
;
/* 登录前缀*/
public
static
final
String
FIELD_LOGIN_PREFIX
=
"loginPrefix"
;
/* 登录前缀*/
public
static
final
String
FIELD_DOC_ID_PC
=
"docIdPc"
;
/* 登录前缀*/
public
static
final
String
FIELD_DOC_ID_APP
=
"docIdApp"
;
/* 登录前缀*/
public
static
final
String
FIELD_REMARK
=
"remark"
;
/* 备注*/
public
static
final
String
FIELD_REMARK
=
"remark"
;
/* 备注*/
public
static
final
String
FIELD_CREATED_BY
=
"createdBy"
;
/* 创建人*/
public
static
final
String
FIELD_CREATED_BY
=
"createdBy"
;
/* 创建人*/
public
static
final
String
FIELD_CREATED_NAME
=
"createdName"
;
/* 创建人名称*/
public
static
final
String
FIELD_CREATED_NAME
=
"createdName"
;
/* 创建人名称*/
...
@@ -60,6 +62,8 @@ public class HPPZ009 extends DaoEPBase {
...
@@ -60,6 +62,8 @@ public class HPPZ009 extends DaoEPBase {
private
String
companyName
=
" "
;
/* 企业名称*/
private
String
companyName
=
" "
;
/* 企业名称*/
private
Integer
validFlag
;
/* 是否启用:1.启用,0.停用*/
private
Integer
validFlag
;
/* 是否启用:1.启用,0.停用*/
private
String
loginPrefix
=
" "
;
/* 登录前缀*/
private
String
loginPrefix
=
" "
;
/* 登录前缀*/
private
String
docIdPc
=
" "
;
/* 登录前缀*/
private
String
docIdApp
=
" "
;
/* 登录前缀*/
private
String
remark
=
" "
;
/* 备注*/
private
String
remark
=
" "
;
/* 备注*/
private
String
createdBy
=
" "
;
/* 创建人*/
private
String
createdBy
=
" "
;
/* 创建人*/
private
String
createdName
=
" "
;
/* 创建人名称*/
private
String
createdName
=
" "
;
/* 创建人名称*/
...
@@ -96,6 +100,14 @@ public class HPPZ009 extends DaoEPBase {
...
@@ -96,6 +100,14 @@ public class HPPZ009 extends DaoEPBase {
eiColumn
.
setDescName
(
"登录前缀"
);
eiColumn
.
setDescName
(
"登录前缀"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_DOC_ID_PC
);
eiColumn
.
setDescName
(
"pc文档标识"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_DOC_ID_APP
);
eiColumn
.
setDescName
(
"app文档标识"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_REMARK
);
eiColumn
=
new
EiColumn
(
FIELD_REMARK
);
eiColumn
.
setDescName
(
"备注"
);
eiColumn
.
setDescName
(
"备注"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
...
@@ -218,6 +230,23 @@ public class HPPZ009 extends DaoEPBase {
...
@@ -218,6 +230,23 @@ public class HPPZ009 extends DaoEPBase {
public
void
setLoginPrefix
(
String
loginPrefix
)
{
public
void
setLoginPrefix
(
String
loginPrefix
)
{
this
.
loginPrefix
=
loginPrefix
;
this
.
loginPrefix
=
loginPrefix
;
}
}
public
String
getDocIdPc
()
{
return
docIdPc
;
}
public
void
setDocIdPc
(
String
docIdPc
)
{
this
.
docIdPc
=
docIdPc
;
}
public
String
getDocIdApp
()
{
return
docIdApp
;
}
public
void
setDocIdApp
(
String
docIdApp
)
{
this
.
docIdApp
=
docIdApp
;
}
/**
/**
* get the remark - 备注.
* get the remark - 备注.
* @return the remark
* @return the remark
...
@@ -359,6 +388,8 @@ public class HPPZ009 extends DaoEPBase {
...
@@ -359,6 +388,8 @@ public class HPPZ009 extends DaoEPBase {
setCompanyName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_COMPANY_NAME
)),
companyName
));
setCompanyName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_COMPANY_NAME
)),
companyName
));
setValidFlag
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_VALID_FLAG
)),
validFlag
));
setValidFlag
(
NumberUtils
.
toInteger
(
StringUtils
.
toString
(
map
.
get
(
FIELD_VALID_FLAG
)),
validFlag
));
setLoginPrefix
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_LOGIN_PREFIX
)),
loginPrefix
));
setLoginPrefix
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_LOGIN_PREFIX
)),
loginPrefix
));
setDocIdPc
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_DOC_ID_PC
)),
docIdPc
));
setDocIdApp
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_DOC_ID_APP
)),
docIdApp
));
setRemark
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_REMARK
)),
remark
));
setRemark
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_REMARK
)),
remark
));
setCreatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_CREATED_BY
)),
createdBy
));
setCreatedBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_CREATED_BY
)),
createdBy
));
setCreatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_CREATED_NAME
)),
createdName
));
setCreatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_CREATED_NAME
)),
createdName
));
...
@@ -381,6 +412,8 @@ public class HPPZ009 extends DaoEPBase {
...
@@ -381,6 +412,8 @@ public class HPPZ009 extends DaoEPBase {
map
.
put
(
FIELD_COMPANY_NAME
,
StringUtils
.
toString
(
companyName
,
eiMetadata
.
getMeta
(
FIELD_COMPANY_NAME
)));
map
.
put
(
FIELD_COMPANY_NAME
,
StringUtils
.
toString
(
companyName
,
eiMetadata
.
getMeta
(
FIELD_COMPANY_NAME
)));
map
.
put
(
FIELD_VALID_FLAG
,
StringUtils
.
toString
(
validFlag
,
eiMetadata
.
getMeta
(
FIELD_VALID_FLAG
)));
map
.
put
(
FIELD_VALID_FLAG
,
StringUtils
.
toString
(
validFlag
,
eiMetadata
.
getMeta
(
FIELD_VALID_FLAG
)));
map
.
put
(
FIELD_LOGIN_PREFIX
,
StringUtils
.
toString
(
loginPrefix
,
eiMetadata
.
getMeta
(
FIELD_LOGIN_PREFIX
)));
map
.
put
(
FIELD_LOGIN_PREFIX
,
StringUtils
.
toString
(
loginPrefix
,
eiMetadata
.
getMeta
(
FIELD_LOGIN_PREFIX
)));
map
.
put
(
FIELD_DOC_ID_PC
,
StringUtils
.
toString
(
docIdPc
,
eiMetadata
.
getMeta
(
FIELD_DOC_ID_PC
)));
map
.
put
(
FIELD_DOC_ID_APP
,
StringUtils
.
toString
(
docIdApp
,
eiMetadata
.
getMeta
(
FIELD_DOC_ID_APP
)));
map
.
put
(
FIELD_REMARK
,
StringUtils
.
toString
(
remark
,
eiMetadata
.
getMeta
(
FIELD_REMARK
)));
map
.
put
(
FIELD_REMARK
,
StringUtils
.
toString
(
remark
,
eiMetadata
.
getMeta
(
FIELD_REMARK
)));
map
.
put
(
FIELD_CREATED_BY
,
StringUtils
.
toString
(
createdBy
,
eiMetadata
.
getMeta
(
FIELD_CREATED_BY
)));
map
.
put
(
FIELD_CREATED_BY
,
StringUtils
.
toString
(
createdBy
,
eiMetadata
.
getMeta
(
FIELD_CREATED_BY
)));
map
.
put
(
FIELD_CREATED_NAME
,
StringUtils
.
toString
(
createdName
,
eiMetadata
.
getMeta
(
FIELD_CREATED_NAME
)));
map
.
put
(
FIELD_CREATED_NAME
,
StringUtils
.
toString
(
createdName
,
eiMetadata
.
getMeta
(
FIELD_CREATED_NAME
)));
...
...
src/main/java/com/baosight/hpjx/hp/pz/service/ServiceHPPZ009.java
View file @
993afb3e
...
@@ -3,12 +3,15 @@ package com.baosight.hpjx.hp.pz.service;
...
@@ -3,12 +3,15 @@ package com.baosight.hpjx.hp.pz.service;
import
com.baosight.hpjx.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hpjx.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hpjx.core.constant.CommonConstant
;
import
com.baosight.hpjx.core.constant.CommonConstant
;
import
com.baosight.hpjx.core.dao.DaoUtils
;
import
com.baosight.hpjx.core.dao.DaoUtils
;
import
com.baosight.hpjx.core.security.UserSessionUtils
;
import
com.baosight.hpjx.hp.constant.HPConstant
;
import
com.baosight.hpjx.hp.constant.HPConstant
;
import
com.baosight.hpjx.hp.pz.domain.HPPZ009
;
import
com.baosight.hpjx.hp.pz.domain.HPPZ009
;
import
com.baosight.hpjx.hp.xs.tools.HPXSTools
;
import
com.baosight.hpjx.hp.xs.tools.HPXSTools
;
import
com.baosight.hpjx.util.AssertUtils
;
import
com.baosight.hpjx.util.AssertUtils
;
import
com.baosight.hpjx.util.DateUtils
;
import
com.baosight.hpjx.util.DateUtils
;
import
com.baosight.hpjx.util.LogUtils
;
import
com.baosight.hpjx.util.LogUtils
;
import
com.baosight.hpjx.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ProjectInfo
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.core.exception.PlatException
;
...
@@ -57,6 +60,8 @@ public class ServiceHPPZ009 extends ServiceBase {
...
@@ -57,6 +60,8 @@ public class ServiceHPPZ009 extends ServiceBase {
public
EiInfo
query
(
EiInfo
inInfo
)
{
public
EiInfo
query
(
EiInfo
inInfo
)
{
try
{
try
{
inInfo
=
super
.
query
(
inInfo
,
"HPPZ009.query"
,
new
HPPZ009
());
inInfo
=
super
.
query
(
inInfo
,
"HPPZ009.query"
,
new
HPPZ009
());
String
projectEnv
=
ProjectInfo
.
getProjectEnv
();
inInfo
.
setCell
(
EiConstant
.
resultBlock
,
ACConstants
.
ROW_CODE_0
,
"projectEnv"
,
projectEnv
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
}
}
...
...
src/main/java/com/baosight/hpjx/hp/pz/sql/HPPZ009.xml
View file @
993afb3e
...
@@ -8,6 +8,8 @@
...
@@ -8,6 +8,8 @@
COMPANY_NAME as "companyName",
<!-- 企业名称 -->
COMPANY_NAME as "companyName",
<!-- 企业名称 -->
VALID_FLAG as "validFlag",
<!-- 是否启用:1.启用,0.停用 -->
VALID_FLAG as "validFlag",
<!-- 是否启用:1.启用,0.停用 -->
LOGIN_PREFIX as "loginPrefix",
<!-- 登录前缀 -->
LOGIN_PREFIX as "loginPrefix",
<!-- 登录前缀 -->
DOC_ID_PC as "docIdPc",
DOC_ID_APP as "docIdApp",
REMARK as "remark",
<!-- 备注 -->
REMARK as "remark",
<!-- 备注 -->
CREATED_BY as "createdBy",
<!-- 创建人 -->
CREATED_BY as "createdBy",
<!-- 创建人 -->
CREATED_NAME as "createdName",
<!-- 创建人名称 -->
CREATED_NAME as "createdName",
<!-- 创建人名称 -->
...
@@ -78,12 +80,14 @@
...
@@ -78,12 +80,14 @@
COMPANY_NAME,
<!-- 企业名称 -->
COMPANY_NAME,
<!-- 企业名称 -->
VALID_FLAG,
<!-- 是否启用:1.启用,0.停用 -->
VALID_FLAG,
<!-- 是否启用:1.启用,0.停用 -->
LOGIN_PREFIX,
<!-- 登录前缀 -->
LOGIN_PREFIX,
<!-- 登录前缀 -->
DOC_ID_PC,
DOC_ID_APP,
REMARK,
<!-- 备注 -->
REMARK,
<!-- 备注 -->
CREATED_BY,
<!-- 创建人 -->
CREATED_BY,
<!-- 创建人 -->
CREATED_NAME,
<!-- 创建人名称 -->
CREATED_NAME,
<!-- 创建人名称 -->
CREATED_TIME
<!-- 创建时间 -->
CREATED_TIME
<!-- 创建时间 -->
) VALUES (
) VALUES (
#companyCode#, #companyName#, #validFlag#, #loginPrefix#, #remark#, #createdBy#,
#companyCode#, #companyName#, #validFlag#, #loginPrefix#, #
docIdPc#, #docIdApp#, #
remark#, #createdBy#,
#createdName#, #createdTime#
#createdName#, #createdTime#
)
)
</insert>
</insert>
...
@@ -93,6 +97,8 @@
...
@@ -93,6 +97,8 @@
UPDATE ${hpjxSchema}.T_HPPZ009
UPDATE ${hpjxSchema}.T_HPPZ009
SET
SET
COMPANY_NAME = #companyName#,
COMPANY_NAME = #companyName#,
DOC_ID_PC = #docIdPc#,
DOC_ID_APP = #docIdApp#,
VALID_FLAG = #validFlag#,
VALID_FLAG = #validFlag#,
REMARK = #remark#,
REMARK = #remark#,
<include
refid=
"updateRevise"
/>
<include
refid=
"updateRevise"
/>
...
...
src/main/resources/META-INF/resources/iPlatV7-index.js
View file @
993afb3e
...
@@ -2443,18 +2443,21 @@ $(function () {
...
@@ -2443,18 +2443,21 @@ $(function () {
}
}
});
});
}
}
if
(
loginName
!==
"admin"
){
/*var info = new EiInfo()
var
info
=
new
EiInfo
()
EiCommunicator.send("HPXS003", "queryMaxLog", info, {
info
.
set
(
"inqu_status-0-companyCode"
,
loginName
)
EiCommunicator
.
send
(
"HPPZ009"
,
"query"
,
info
,
{
onSuccess
:
function
(
ei
)
{
//返回结果集
onSuccess
:
function
(
ei
)
{
//返回结果集
if
(
ei
.
blocks
.
result
!==
undefined
){
let
results
=
ei
.
getBlock
(
"result"
).
getMappedRows
()
let
results
=
ei
.
getBlock
(
"result"
).
getMappedRows
()
if (results.length>0){
$("#sidebar img").attr("src",downloadHref(results[0].docId
),results[0].projectEnv);
$
(
"#sidebar img"
).
attr
(
"src"
,
downloadHref
(
results
[
0
].
docIdPc
),
results
[
0
].
projectEnv
);
}
}
},
onFail
:
function
(
ei
)
{
},
onFail
:
function
(
ei
)
{
}
}
}, {async: false});*/
},
{
async
:
false
});
}
})
})
function
timedisplay
()
{
function
timedisplay
()
{
...
...
src/main/webapp/HP/PZ/HPPZ009.js
View file @
993afb3e
...
@@ -5,20 +5,56 @@ $(function () {
...
@@ -5,20 +5,56 @@ $(function () {
pageSizes
:
[
10
,
20
,
50
,
70
,
100
],
pageSizes
:
[
10
,
20
,
50
,
70
,
100
],
},
},
onSuccess
:
function
(
e
)
{
onSuccess
:
function
(
e
)
{
if
(
e
.
eiInfo
.
extAttr
.
methodName
==
'save'
if
(
e
.
eiInfo
.
extAttr
.
methodName
==
'save'
||
e
.
eiInfo
.
extAttr
.
methodName
==
'delete'
){
||
e
.
eiInfo
.
extAttr
.
methodName
==
'delete'
){
query
();
query
();
}
}
},
},
onAdd
:
function
(
e
)
{
e
.
preventDefault
()
$
(
"#type"
).
val
(
"update"
)
$
(
"#companyName"
).
val
();
$
(
"#loginPrefix"
).
val
();
$
(
"#validFlag"
).
val
();
$
(
"#PCfileDocId"
).
val
();
$
(
"#APPfileDocId"
).
val
();
$
(
"#remark"
).
val
();
$
(
"#id"
).
val
();
$
(
"#companyCode"
).
val
();
addCompany
(
$
(
"#insertGroup"
))
},
onSave
:
function
(
e
)
{
onSave
:
function
(
e
)
{
// 阻止后台保存请求,使用自定义保存
// 阻止后台保存请求,使用自定义保存
e
.
preventDefault
();
e
.
preventDefault
();
save
();
//
save();
},
},
onDelete
:
function
(
e
)
{
onDelete
:
function
(
e
)
{
// 阻止后台删除请求,使用自定义删除
// 阻止后台删除请求,使用自定义删除
e
.
preventDefault
();
e
.
preventDefault
();
deleteFunc
();
deleteFunc
();
},
/**
*
* @param e
* e.sender kendoGridresultGrid
* e.model kendo.data.Model
* e.row
* e.tr tr, jquery
*/
onRowClick
:
function
(
e
)
{
$
(
"#type"
).
val
(
"update"
);
$
(
"#companyCode"
).
val
(
e
.
model
.
companyCode
);
$
(
"#companyName"
).
val
(
e
.
model
.
companyName
);
$
(
"#loginPrefix"
).
val
(
e
.
model
.
loginPrefix
);
$
(
"#validFlag"
).
val
(
e
.
model
.
validFlag
);
$
(
"#PCfileDocId"
).
val
(
e
.
model
.
docIdPc
);
$
(
"#APPfileDocId"
).
val
(
e
.
model
.
docIdApp
);
$
(
"#remark"
).
val
(
e
.
model
.
remark
);
$
(
"#id"
).
val
(
e
.
model
.
id
);
addCompany
(
$
(
"#insertGroup"
))
/*WindowUtil({
"title": "",
"content": "<div class='kendo-del-message'>" + e.row + "</div>"
})*/
}
}
}
}
...
@@ -26,10 +62,65 @@ $(function () {
...
@@ -26,10 +62,65 @@ $(function () {
$
(
"#QUERY"
).
on
(
"click"
,
query
);
$
(
"#QUERY"
).
on
(
"click"
,
query
);
// 保存
// 保存
$
(
"#BTN_SAVE"
).
on
(
"click"
,
save
);
//
$("#BTN_SAVE").on("click", save);
// 删除
// 删除
$
(
"#BTN_DELETE"
).
on
(
"click"
,
deleteFunc
);
$
(
"#BTN_DELETE"
).
on
(
"click"
,
deleteFunc
);
IPLATUI
.
EFUpload
=
{
docIdApp
:
{
showFileList
:
false
,
validation
:
{
allowedExtensions
:
[
".jpg"
,
".png"
,
".gif"
],
//
maxFileSize
:
900000
,
minFileSize
:
300
},
// 不支持格式提示信息
localization
:
{
invalidFileExtension
:
"文件格式不支持, 上传失败"
},
success
:
function
(
e
)
{
let
docId
=
e
.
response
.
docId
;
if
(
isBlank
(
docId
))
{
return
;
}
$
(
"#APPfileDocId"
).
val
(
docId
);
NotificationUtil
(
"附件上传成功"
);
//console.log($("#fileDocId").val())
//saveTemp(e);
/*try {
parent.JSColorbox.setValueCallback(e);
} catch (e){
}*/
},
},
docIdPc
:
{
showFileList
:
false
,
validation
:
{
allowedExtensions
:
[
".jpg"
,
".png"
,
".gif"
],
//
maxFileSize
:
900000
,
minFileSize
:
300
},
// 不支持格式提示信息
localization
:
{
invalidFileExtension
:
"文件格式不支持, 上传失败"
},
success
:
function
(
e
)
{
let
docId
=
e
.
response
.
docId
;
if
(
isBlank
(
docId
))
{
return
;
}
$
(
"#PCfileDocId"
).
val
(
docId
);
NotificationUtil
(
"附件上传成功"
);
//console.log($("#fileDocId").val())
//saveTemp(e);
/*try {
parent.JSColorbox.setValueCallback(e);
} catch (e){
}*/
},
}
};
});
});
/**
/**
...
@@ -45,23 +136,83 @@ $(window).load(function () {
...
@@ -45,23 +136,83 @@ $(window).load(function () {
*/
*/
let
query
=
function
()
{
let
query
=
function
()
{
resultGrid
.
dataSource
.
page
(
1
);
resultGrid
.
dataSource
.
page
(
1
);
}
};
let
save
=
function
(){
var
btnNode
=
$
(
this
);
btnNode
.
attr
(
"disabled"
,
true
);
var
ei
=
new
EiInfo
();
let
type
=
$
(
"#type"
).
val
();
if
(
type
===
"update"
){
ei
.
set
(
"result-0-companyCode"
,
$
(
"#companyCode"
).
val
());
}
ei
.
set
(
"result-0-companyName"
,
$
(
"#companyName"
).
val
());
ei
.
set
(
"result-0-loginPrefix"
,
$
(
"#loginPrefix"
).
val
());
ei
.
set
(
"result-0-validFlag"
,
$
(
"#validFlag"
).
val
());
ei
.
set
(
"result-0-docIdPc"
,
$
(
"#PCfileDocId"
).
val
());
ei
.
set
(
"result-0-docIdApp"
,
$
(
"#APPfileDocId"
).
val
());
ei
.
set
(
"result-0-remark"
,
$
(
"#remark"
).
val
());
ei
.
set
(
"result-0-id"
,
$
(
"#id"
).
val
());
// 调用请求 onSuccess 成功回掉函数
EiCommunicator
.
send
(
"HPPZ009"
,
"save"
,
ei
,
{
onSuccess
:
function
(
ei
)
{
btnNode
.
attr
(
"disabled"
,
false
);
$
(
"#insertGroup"
).
data
(
"kendoWindow"
).
close
();
resultGrid
.
dataSource
.
page
(
1
);
// onFail 表示失败回掉函数
},
onFail
:
function
(
ei
)
{
// 发生异常
btnNode
.
attr
(
"disabled"
,
false
);
NotificationUtil
(
ei
);
}
});
};
/**
/**
* 保存
* 保存
*/
*/
let
save
=
function
()
{
/*
let save = function () {
let rows = resultGrid.getCheckedRows();
let rows = resultGrid.getCheckedRows();
if
(
rows
.
length
<
1
)
{
if (rows.length = 1) {
message
(
"请选择数据"
);
$("#type").val("update")
return
;
}
let result = new EiInfo();
let docId = e.response.docId;
let docName = e.response.docName;
let docSize = e.response.docSize;
let docTag = e.response.docTag;
let docUrl = e.response.docUrl;
result.set("result-0-docId",docId);
result.set("result-0-docName",docName);
result.set("result-0-docSize",docSize);
result.set("result-0-docTag",docTag);
result.set("result-0-realPath",docUrl);
EiCommunicator.send("HPXS003", "insert", result, {
onSuccess: function (ei) {
if (ei.getStatus() >= 0) {
if (ei.getStatus() == 0) {
NotificationUtil(ei, 'warning');
} else {
NotificationUtil(ei);
}
} else {
NotificationUtil(ei, "error");
}
}
JSUtils
.
confirm
(
"确定对勾选中的["
+
rows
.
length
+
"]条数据做
\"
保存
\"
操作? "
,
{
resultGrid.dataSource.page(1);
},
onFail: function (ei) {
// 发生异常
NotificationUtil("执行失败,原因[" + ei + "]", "error");
}
}, {
async: false
});
/!*JSUtils.confirm("确定对勾选中的[" + rows.length + "]条数据做\"保存\"操作? ", {
ok: function () {
ok: function () {
JSUtils.submitGridsData("result", "HPPZ009", "save", true);
JSUtils.submitGridsData("result", "HPPZ009", "save", true);
}
}
});
});
*!/
}
}
*/
/**
/**
* 删除
* 删除
...
@@ -78,3 +229,76 @@ let deleteFunc = function () {
...
@@ -78,3 +229,76 @@ let deleteFunc = function () {
}
}
});
});
}
}
/**
* 点击添加
*
* @param id
*/
function
addCompany
(
id
)
{
let
rows
=
resultGrid
.
getCheckedRows
();
//打开弹窗
id
.
data
(
"kendoWindow"
).
open
().
center
();
}
$
(
"#update"
).
click
(
function
()
{
var
btnNode
=
$
(
this
);
btnNode
.
attr
(
"disabled"
,
true
);
// 创建 EiInfo
var
ei
=
new
EiInfo
();
ei
.
setByNodeObject
(
document
.
body
);
// 获取 数据
// 调用请求 onSuccess 成功回掉函数
EiCommunicator
.
send
(
"HPPZ009"
,
"update"
,
ei
,
{
onSuccess
:
function
(
ei
)
{
btnNode
.
attr
(
"disabled"
,
false
);
resultGrid
.
dataSource
.
page
(
1
);
// onFail 表示失败回掉函数
},
onFail
:
function
(
ei
)
{
// 发生异常
btnNode
.
attr
(
"disabled"
,
false
);
NotificationUtil
(
ei
);
}
});
});
/**
* 附件上传回调
*
* @param e
*/
function
addCompanyCallback
(
e
)
{
resultGrid
.
dataSource
.
page
(
1
);
/*let result = new EiInfo();
let docId = e.response.docId;
let docName = e.response.docName;
let docSize = e.response.docSize;
let docTag = e.response.docTag;
let docUrl = e.response.docUrl;
result.set("result-0-docId",docId);
result.set("result-0-docName",docName);
result.set("result-0-docSize",docSize);
result.set("result-0-docTag",docTag);
result.set("result-0-realPath",docUrl);
EiCommunicator.send("HPXS003", "insert", result, {
onSuccess: function (ei) {
if (ei.getStatus() >= 0) {
if (ei.getStatus() == 0) {
NotificationUtil(ei, 'warning');
} else {
NotificationUtil(ei);
}
} else {
NotificationUtil(ei, "error");
}
resultGrid.dataSource.page(1);
},
onFail: function (ei) {
// 发生异常
NotificationUtil("执行失败,原因[" + ei + "]", "error");
}
}, {
async: false
});*/
}
src/main/webapp/HP/PZ/HPPZ009.jsp
View file @
993afb3e
...
@@ -4,8 +4,7 @@
...
@@ -4,8 +4,7 @@
<
%@
taglib
prefix=
"EF"
tagdir=
"/WEB-INF/tags/EF"
%
>
<
%@
taglib
prefix=
"EF"
tagdir=
"/WEB-INF/tags/EF"
%
>
<c:set
var=
"ctx"
value=
"${pageContext.request.contextPath}"
/>
<c:set
var=
"ctx"
value=
"${pageContext.request.contextPath}"
/>
<EF:EFPage
title=
"企业管理"
>
<EF:EFPage
title=
"企业管理"
>
<EF:EFRegion
id=
"inqu"
title=
"查询条件"
>
<EF:EFRegion
id=
"inqu"
title=
"查询条件"
>
<div
class=
"row"
>
<div
class=
"row"
>
<EF:EFInput
cname=
"企业编码:"
ename=
"companyCode"
blockId=
"inqu_status"
row=
"0"
/>
<EF:EFInput
cname=
"企业编码:"
ename=
"companyCode"
blockId=
"inqu_status"
row=
"0"
/>
...
@@ -16,6 +15,8 @@
...
@@ -16,6 +15,8 @@
<EF:EFRegion
id=
"result"
title=
"记录集"
>
<EF:EFRegion
id=
"result"
title=
"记录集"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
checkMode=
"row"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
checkMode=
"row"
>
<EF:EFColumn
ename=
"id"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"docIdPc"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"docIdApp"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
cname=
"企业编码"
ename=
"companyCode"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFColumn
cname=
"企业编码"
ename=
"companyCode"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFColumn
cname=
"企业名称"
ename=
"companyName"
width=
"140"
required=
"true"
/>
<EF:EFColumn
cname=
"企业名称"
ename=
"companyName"
width=
"140"
required=
"true"
/>
<EF:EFColumn
cname=
"登录前缀"
ename=
"loginPrefix"
width=
"100"
align=
"center"
readonly=
"true"
/>
<EF:EFColumn
cname=
"登录前缀"
ename=
"loginPrefix"
width=
"100"
align=
"center"
readonly=
"true"
/>
...
@@ -33,4 +34,76 @@
...
@@ -33,4 +34,76 @@
<br/>
<br/>
<span
style=
'color: red;font-size: 13px;'
>
说明:新增企业时会同步新增企业管理员账户,账号和密码与企业编码相同
</span>
<span
style=
'color: red;font-size: 13px;'
>
说明:新增企业时会同步新增企业管理员账户,账号和密码与企业编码相同
</span>
</EF:EFRegion>
</EF:EFRegion>
</EF:EFPage>
<EF:EFWindow
id=
"insertGroup"
top=
"100px"
left=
"280px"
width=
"38%"
height=
"70%"
>
<form>
<div
class=
"form-group row"
>
<label
for=
"companyName"
class=
"col-sm-2 col-form-label col-form-label-sm"
>
企业名称
</label>
<div
class=
"col-sm-6"
>
<input
type=
"text"
class=
"form-control"
id=
"companyName"
required=
"required"
>
</div>
</div>
<div
class=
"form-group row"
>
<label
for=
"loginPrefix"
class=
"col-sm-2 col-form-label col-form-label-sm"
>
登录前缀
</label>
<div
class=
"col-sm-6"
>
<input
type=
"text"
class=
"form-control"
id=
"loginPrefix"
>
</div>
</div>
<div
class=
"form-group row"
>
<label
for=
"validFlag"
class=
"col-sm-2 col-form-label col-form-label-sm"
>
是否启动
</label>
<div
class=
"col-sm-6"
>
<select
class=
"form-control"
id=
"validFlag"
>
<option
value=
"1"
>
是
</option>
<option
value=
"0"
>
否
</option>
</select>
</div>
</div>
<div
class=
"form-group row"
>
<label
for=
"docIdPc"
class=
"col-sm-2 col-form-label"
>
PClog上传
</label>
<div
class=
"col-sm-6"
>
<EF:EFUpload
ename=
"docIdPc"
cname=
"PC上传"
docTag=
"hk_filePc"
path=
"A"
/>
<
%
--
<
input
type=
"file"
class=
"form-control"
id=
"docIdPc"
>
--%>
</div>
<input
type=
"hidden"
id=
"PCfileDocId"
value=
""
>
</div>
<div
class=
"form-group row"
>
<label
for=
"docIdApp"
class=
"col-sm-2 col-form-label"
>
APPlog上传
</label>
<div
class=
"col-sm-6"
>
<EF:EFUpload
ename=
"docIdApp"
cname=
"APP上传"
docTag=
"hk_fileApp"
path=
"A"
/>
<
%
--
<
input
type=
"file"
class=
"form-control"
accept=
"image/*"
id=
"docIdApp"
>
--%>
</div>
<input
type=
"hidden"
id=
"APPfileDocId"
value=
""
>
</div>
<div
class=
"form-group row"
>
<label
for=
"remark"
class=
"col-sm-2 col-form-label col-form-label-sm"
>
备注
</label>
<div
class=
"col-sm-6"
>
<input
type=
"text"
class=
"form-control"
id=
"remark"
>
</div>
</div>
<input
type=
"hidden"
id=
"type"
value=
"insert"
>
<input
type=
"hidden"
id=
"id"
value=
""
>
<input
type=
"hidden"
id=
"companyCode"
value=
""
>
<div
class=
"form-group col-md-6 col-sm-6 col-sm-offset-9"
>
<button
type=
"button"
onclick=
"save()"
class=
"btn btn-info"
>
确认
</button>
</div>
</form>
</EF:EFWindow>
<EF:EFWindow
id=
"updateGroup"
top=
"100px"
left=
"280px"
width=
"58%"
height=
"80%"
>
<EF:EFRegion
id=
"updateResult"
>
<EF:EFInput
ename=
"companyName"
colWidth=
"6"
cname=
"企业名称"
/>
<EF:EFInput
ename=
"loginPrefix"
colWidth=
"6"
cname=
"登录前缀"
/>
<EF:EFSelect
ename=
"validFlag"
cname=
"是否启动"
template=
"#=valueField#-#=textField#"
valueTemplate=
"#=valueField#-#=textField#"
required=
"true"
defaultValue=
"China"
>
<
%
--enable=
"false"
:
不可下拉
--
%
>
<EF:EFOptions
blockId=
"made_country_block_id"
textField=
"country_ch_name"
valueField=
"country"
/>
</EF:EFSelect>
<EF:EFUpload
ename=
"uploadFilePc"
cname=
"PC上传"
docTag=
"hk_filePc"
path=
"A"
/>
<EF:EFUpload
ename=
"uploadFileApp"
cname=
"APP上传"
docTag=
"hk_fileApp"
path=
"A"
/>
<EF:EFInput
ename=
"remark"
colWidth=
"6"
cname=
"备注"
/>
<EF:EFInput
ename=
"PCfileDocId"
cname=
""
hidden=
"true"
/>
<EF:EFInput
ename=
"APPfileDocId"
cname=
""
hidden=
"true"
/>
<EF:EFButton
ename=
"update"
cname=
"确认"
layout=
"1"
class=
"k-button"
/>
</EF:EFRegion>
</EF:EFWindow>
</EF:EFPage>
src/main/webapp/HP/XS/HPXS003.jsp
View file @
993afb3e
...
@@ -16,10 +16,6 @@
...
@@ -16,10 +16,6 @@
<EF:EFRegion id="inqu" title="查询条件">
<EF:EFRegion id="inqu" title="查询条件">
<div class="row">
<div class="row">
<EF:EFInput cname="文件名称" blockId="inqu_status" ename="docName" row="0" colWidth="3"/>
<EF:EFInput cname="文件名称" blockId="inqu_status" ename="docName" row="0" colWidth="3"/>
<EF:EFDateSpan startCname="上传日期" endCname="至" blockId="inqu_status"
startName="createdDateFrom" endName="createdDateTo" row="0" role="date"
format="yyyy-MM-dd" satrtRatio="4:8" endRatio="4:8">
</EF:EFDateSpan>
</div>
</div>
</EF:EFRegion>
</EF:EFRegion>
...
...
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