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
59fe56f2
Commit
59fe56f2
authored
Oct 19, 2024
by
宋祥
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://129.211.46.84:8800/platform/hg-smart
into master-dc
parents
66e23f95
76db465b
Show whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
276 additions
and
147 deletions
+276
-147
DaoUtils.java
src/main/java/com/baosight/hggp/core/dao/DaoUtils.java
+13
-16
ServiceHGSC101.java
.../java/com/baosight/hggp/hg/sc/service/ServiceHGSC101.java
+6
-1
ServiceHGWD001.java
.../java/com/baosight/hggp/hg/wd/service/ServiceHGWD001.java
+2
-34
ServiceHGWD001C.java
...java/com/baosight/hggp/hg/wd/service/ServiceHGWD001C.java
+54
-3
ServiceHGWD005.java
.../java/com/baosight/hggp/hg/wd/service/ServiceHGWD005.java
+7
-1
HGYX005.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX005.xml
+1
-0
HGYX005A.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX005A.xml
+1
-0
HGYX006.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX006.xml
+1
-0
HGYX007.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX007.xml
+1
-0
HGYX008.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX008.xml
+1
-0
HGYX009.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX009.xml
+1
-0
HGYX010.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX010.xml
+1
-0
HGYX011.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX011.xml
+1
-0
HGYX012.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX012.xml
+1
-0
HGYX013.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX013.xml
+1
-0
HGYX014.xml
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX014.xml
+1
-0
sqlmap-config.xml
src/main/resources/resources/ibatis/sqlmap-config.xml
+11
-0
HGSC010.js
src/main/webapp/HG/SC/HGSC010.js
+30
-6
HGSC010.jsp
src/main/webapp/HG/SC/HGSC010.jsp
+0
-7
HGWD001.js
src/main/webapp/HG/WD/HGWD001.js
+1
-1
HGWD002.js
src/main/webapp/HG/WD/HGWD002.js
+63
-42
HGWD002.jsp
src/main/webapp/HG/WD/HGWD002.jsp
+1
-28
HGWD002A.jsp
src/main/webapp/HG/WD/HGWD002A.jsp
+4
-4
HGWD002A1.css
src/main/webapp/HG/WD/HGWD002A1.css
+0
-0
HGWD002A1.js
src/main/webapp/HG/WD/HGWD002A1.js
+19
-1
HGWD002A1.jsp
src/main/webapp/HG/WD/HGWD002A1.jsp
+34
-0
common.js
src/main/webapp/common/js/common.js
+20
-3
No files found.
src/main/java/com/baosight/hggp/core/dao/DaoUtils.java
View file @
59fe56f2
...
@@ -179,24 +179,23 @@ public class DaoUtils {
...
@@ -179,24 +179,23 @@ public class DaoUtils {
log
.
warn
(
"写入创建人姓名失败"
,
e
);
log
.
warn
(
"写入创建人姓名失败"
,
e
);
}
}
// 创建人企业编码
// 创建人企业编码
try
{
String
accountCode
=
UserSessionUtils
.
getAccountCode
();
String
accountCode
=
BeanUtils
.
getProperty
(
bean
,
"accountCode"
);
if
(!
"admin"
.
equals
(
userId
))
{
if
(
StringUtils
.
isBlank
(
accountCode
))
{
accountCode
=
UserSessionUtils
.
getAccountCode
();
AssertUtils
.
isEmpty
(
accountCode
,
"当前用户未绑定公司,无法操作数据,请联系管理员!"
);
AssertUtils
.
isEmpty
(
accountCode
,
"当前用户未绑定公司,无法操作数据,请联系管理员!"
);
}
}
try
{
BeanUtils
.
setProperty
(
bean
,
"accountCode"
,
accountCode
);
BeanUtils
.
setProperty
(
bean
,
"accountCode"
,
accountCode
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
warn
(
"写入创建人企业编码失败"
,
e
);
log
.
warn
(
"写入创建人企业编码失败"
,
e
);
}
}
// 创建人组织机构
// 创建人组织机构
try
{
String
depCode
=
BeanUtils
.
getProperty
(
bean
,
"depCode"
);
if
(
StringUtils
.
isBlank
(
depCode
)
&&
!
"admin"
.
equals
(
userId
))
{
List
<
String
>
orgIds
=
UserSessionUtils
.
getOrgId
();
List
<
String
>
orgIds
=
UserSessionUtils
.
getOrgId
();
if
(!
"admin"
.
equals
(
userId
))
{
AssertUtils
.
isEmpty
(
orgIds
,
"当前用户未绑定部门,无法操作数据,请联系管理员!"
);
AssertUtils
.
isEmpty
(
orgIds
,
"当前用户未绑定部门,无法操作数据,请联系管理员!"
);
depCode
=
orgIds
.
get
(
0
);
}
}
try
{
// 此处应该不支持自定义部门,否则写入的部门信息不准确
String
depCode
=
CollectionUtils
.
isEmpty
(
orgIds
)
?
""
:
orgIds
.
get
(
0
);
BeanUtils
.
setProperty
(
bean
,
"depCode"
,
depCode
);
BeanUtils
.
setProperty
(
bean
,
"depCode"
,
depCode
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
warn
(
"写入创建人部门编码失败"
,
e
);
log
.
warn
(
"写入创建人部门编码失败"
,
e
);
...
@@ -247,24 +246,22 @@ public class DaoUtils {
...
@@ -247,24 +246,22 @@ public class DaoUtils {
map
.
put
(
"createdName"
,
userName
);
map
.
put
(
"createdName"
,
userName
);
map
.
put
(
"updatedName"
,
""
);
map
.
put
(
"updatedName"
,
""
);
// 创建人企业编码
// 创建人企业编码
try
{
String
accountCode
=
UserSessionUtils
.
getAccountCode
();
String
accountCode
=
MapUtils
.
getString
(
map
,
"accountCode"
);
if
(!
"admin"
.
equals
(
userId
))
{
if
(
ObjectUtils
.
isNullBlank
(
accountCode
))
{
accountCode
=
UserSessionUtils
.
getAccountCode
();
AssertUtils
.
isEmpty
(
accountCode
,
"当前用户未绑定公司,无法操作数据,请联系管理员!"
);
AssertUtils
.
isEmpty
(
accountCode
,
"当前用户未绑定公司,无法操作数据,请联系管理员!"
);
}
}
try
{
map
.
put
(
"accountCode"
,
accountCode
);
map
.
put
(
"accountCode"
,
accountCode
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
warn
(
"写入创建人企业编码失败"
,
e
);
log
.
warn
(
"写入创建人企业编码失败"
,
e
);
}
}
// 创建人部门编码
// 创建人部门编码
try
{
String
depCode
=
MapUtils
.
getString
(
map
,
"depCode"
);
if
(
ObjectUtils
.
isNullBlank
(
depCode
)
&&
!
"admin"
.
equals
(
userId
))
{
List
<
String
>
orgIds
=
UserSessionUtils
.
getOrgId
();
List
<
String
>
orgIds
=
UserSessionUtils
.
getOrgId
();
if
(!
"admin"
.
equals
(
userId
))
{
AssertUtils
.
isEmpty
(
orgIds
,
"当前用户未绑定部门,无法操作数据,请联系管理员!"
);
AssertUtils
.
isEmpty
(
orgIds
,
"当前用户未绑定部门,无法操作数据,请联系管理员!"
);
depCode
=
orgIds
.
get
(
0
);
}
}
try
{
String
depCode
=
CollectionUtils
.
isEmpty
(
orgIds
)
?
""
:
orgIds
.
get
(
0
);
map
.
put
(
"depCode"
,
depCode
);
map
.
put
(
"depCode"
,
depCode
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
warn
(
"写入创建人企业编码失败"
,
e
);
log
.
warn
(
"写入创建人企业编码失败"
,
e
);
...
...
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC101.java
View file @
59fe56f2
package
com
.
baosight
.
hggp
.
hg
.
sc
.
service
;
package
com
.
baosight
.
hggp
.
hg
.
sc
.
service
;
import
com.baosight.hggp.core.dao.DaoBase
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.extapp.decheng.api.DcOpenApi
;
import
com.baosight.hggp.core.extapp.decheng.api.DcOpenApi
;
import
com.baosight.hggp.core.extapp.decheng.model.DcContract
;
import
com.baosight.hggp.core.extapp.decheng.model.DcContract
;
...
@@ -207,7 +208,11 @@ public class ServiceHGSC101 extends ServiceEPBase {
...
@@ -207,7 +208,11 @@ public class ServiceHGSC101 extends ServiceEPBase {
// 设计来源
// 设计来源
dbSc001
.
setProjectSource
(
getProjectSource
(
dcContract
.
getDesignSource
()));
dbSc001
.
setProjectSource
(
getProjectSource
(
dcContract
.
getDesignSource
()));
dbSc001
.
setContractNo
(
dcContract
.
getHtid
());
dbSc001
.
setContractNo
(
dcContract
.
getHtid
());
DaoUtils
.
insert
(
HGSC001
.
INSERT
,
dbSc001
);
dbSc001
.
setRecCreator
(
"System"
);
dbSc001
.
setRecCreateTime
(
DateUtils
.
shortDateTime
());
dbSc001
.
setRecRevisor
(
"System"
);
dbSc001
.
setRecReviseTime
(
DateUtils
.
shortDateTime
());
DaoBase
.
getInstance
().
insert
(
HGSC001
.
INSERT
,
dbSc001
);
}
}
/**
/**
...
...
src/main/java/com/baosight/hggp/hg/wd/service/ServiceHGWD001.java
View file @
59fe56f2
...
@@ -5,6 +5,7 @@ import com.baosight.hggp.common.ChangeTypeEnum;
...
@@ -5,6 +5,7 @@ import com.baosight.hggp.common.ChangeTypeEnum;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.common.DdynamicEnum
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.core.enums.OrgTypeEnum
;
import
com.baosight.hggp.core.enums.OrgTypeEnum
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.core.tools.FileTools
;
import
com.baosight.hggp.core.tools.FileTools
;
...
@@ -16,6 +17,7 @@ import com.baosight.hggp.hg.wd.constant.HgWdConstant;
...
@@ -16,6 +17,7 @@ import com.baosight.hggp.hg.wd.constant.HgWdConstant;
import
com.baosight.hggp.hg.wd.constant.HgWdSqlConstant
;
import
com.baosight.hggp.hg.wd.constant.HgWdSqlConstant
;
import
com.baosight.hggp.hg.wd.domain.HGWD001
;
import
com.baosight.hggp.hg.wd.domain.HGWD001
;
import
com.baosight.hggp.hg.wd.domain.HGWD001A
;
import
com.baosight.hggp.hg.wd.domain.HGWD001A
;
import
com.baosight.hggp.hg.wd.domain.HGWD001C
;
import
com.baosight.hggp.hg.wd.domain.HGWD003
;
import
com.baosight.hggp.hg.wd.domain.HGWD003
;
import
com.baosight.hggp.hg.wd.domain.HGWD099
;
import
com.baosight.hggp.hg.wd.domain.HGWD099
;
import
com.baosight.hggp.hg.wd.tools.HGWDTools
;
import
com.baosight.hggp.hg.wd.tools.HGWDTools
;
...
@@ -586,38 +588,4 @@ public class ServiceHGWD001 extends ServiceEPBase {
...
@@ -586,38 +588,4 @@ public class ServiceHGWD001 extends ServiceEPBase {
return
inInfo
;
return
inInfo
;
}
}
/**
* 批量下载
*
* @param inInfo
* @return
*/
public
EiInfo
batchDownload
(
EiInfo
inInfo
)
{
try
{
Map
queryMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
);
String
fileName
=
MapUtils
.
getString
(
queryMap
,
HGWD001
.
FIELD_FILE_NAME
);
String
zipName
=
fileName
+
"_"
+
DateUtils
.
shortDateTime
();
List
<
String
>
docIds
=
ObjectUtils
.
listKey
(
inInfo
,
HGWD099
.
FIELD_DOC_ID
);
inInfo
.
set
(
"downloadUrl"
,
Iplat4jUtils
.
compressFile
(
docIds
,
zipName
));
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"批量下载失败"
);
}
return
inInfo
;
}
/**
* 清理下载的文件
*
* @param inInfo
* @return
*/
public
EiInfo
clearDownload
(
EiInfo
inInfo
)
{
try
{
FileTools
.
clearZip
();
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"清理下载的文件失败"
);
}
return
inInfo
;
}
}
}
src/main/java/com/baosight/hggp/hg/wd/service/ServiceHGWD001C.java
View file @
59fe56f2
...
@@ -3,14 +3,20 @@ package com.baosight.hggp.hg.wd.service;
...
@@ -3,14 +3,20 @@ package com.baosight.hggp.hg.wd.service;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.core.tools.FileTools
;
import
com.baosight.hggp.core.utils.Iplat4jUtils
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.cw.tools.HGCWTools
;
import
com.baosight.hggp.hg.wd.domain.HGWD001
;
import
com.baosight.hggp.hg.wd.domain.HGWD001C
;
import
com.baosight.hggp.hg.wd.domain.HGWD001C
;
import
com.baosight.hggp.hg.wd.domain.HGWD002
;
import
com.baosight.hggp.hg.wd.domain.HGWD002
;
import
com.baosight.hggp.hg.wd.domain.HGWD099
;
import
com.baosight.hggp.hg.wd.tools.HGWDTools
;
import
com.baosight.hggp.hg.wd.tools.HGWDTools
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.DateUtils
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.MapUtils
;
import
com.baosight.hggp.util.MapUtils
;
import
com.baosight.hggp.util.ObjectUtils
;
import
com.baosight.hggp.util.StringUtils
;
import
com.baosight.hggp.util.StringUtils
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
...
@@ -91,6 +97,42 @@ public class ServiceHGWD001C extends ServiceBase {
...
@@ -91,6 +97,42 @@ public class ServiceHGWD001C extends ServiceBase {
*/
*/
public
EiInfo
add
(
EiInfo
inInfo
)
{
public
EiInfo
add
(
EiInfo
inInfo
)
{
try
{
try
{
// 写入下载记录
this
.
saveData
(
inInfo
);
inInfo
.
setMsg
(
"操作成功"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"操作失败"
);
}
return
inInfo
;
}
/**
* 批量下载
*
* @param inInfo
* @return
*/
public
EiInfo
batchDownload
(
EiInfo
inInfo
)
{
try
{
Map
queryMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
);
String
fileName
=
MapUtils
.
getString
(
queryMap
,
HGWD001
.
FIELD_FILE_NAME
);
String
zipName
=
fileName
+
"_"
+
DateUtils
.
shortDateTime
();
List
<
String
>
docIds
=
ObjectUtils
.
listKey
(
inInfo
,
HGWD099
.
FIELD_DOC_ID
);
inInfo
.
set
(
"downloadUrl"
,
Iplat4jUtils
.
compressFile
(
docIds
,
zipName
));
// 写入下载记录
this
.
saveData
(
inInfo
);
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"批量下载失败"
);
}
return
inInfo
;
}
/**
* 保存数据
*
* @param inInfo
*/
private
void
saveData
(
EiInfo
inInfo
)
{
List
<
HGWD001C
>
fWd001cs
=
MapUtils
.
toDaoEPBases
(
inInfo
,
HGWD001C
.
class
);
List
<
HGWD001C
>
fWd001cs
=
MapUtils
.
toDaoEPBases
(
inInfo
,
HGWD001C
.
class
);
for
(
HGWD001C
fWd001c
:
fWd001cs
)
{
for
(
HGWD001C
fWd001c
:
fWd001cs
)
{
AssertUtils
.
isEmpty
(
fWd001c
.
getFileId
(),
"文件ID不能为空"
);
AssertUtils
.
isEmpty
(
fWd001c
.
getFileId
(),
"文件ID不能为空"
);
...
@@ -100,10 +142,19 @@ public class ServiceHGWD001C extends ServiceBase {
...
@@ -100,10 +142,19 @@ public class ServiceHGWD001C extends ServiceBase {
fWd001c
.
setDeleteFlag
(
DeleteFlagEnum
.
UN_REMOVE
.
getCode
());
fWd001c
.
setDeleteFlag
(
DeleteFlagEnum
.
UN_REMOVE
.
getCode
());
DaoUtils
.
insert
(
HGWD001C
.
INSERT
,
fWd001c
);
DaoUtils
.
insert
(
HGWD001C
.
INSERT
,
fWd001c
);
}
}
inInfo
.
setStatus
(
EiConstant
.
STATUS_SUCCESS
);
}
inInfo
.
setMsg
(
"操作成功"
);
/**
* 清理下载的文件
*
* @param inInfo
* @return
*/
public
EiInfo
clearDownload
(
EiInfo
inInfo
)
{
try
{
FileTools
.
clearZip
();
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
LogUtils
.
set
DetailMsg
(
inInfo
,
e
,
"操作
失败"
);
LogUtils
.
set
Msg
(
inInfo
,
e
,
"清理下载的文件
失败"
);
}
}
return
inInfo
;
return
inInfo
;
}
}
...
...
src/main/java/com/baosight/hggp/hg/wd/service/ServiceHGWD005.java
View file @
59fe56f2
package
com
.
baosight
.
hggp
.
hg
.
wd
.
service
;
package
com
.
baosight
.
hggp
.
hg
.
wd
.
service
;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.core.dao.DaoBase
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.core.enums.DeleteFlagEnum
;
import
com.baosight.hggp.core.extapp.decheng.api.DcOpenApi
;
import
com.baosight.hggp.core.extapp.decheng.api.DcOpenApi
;
...
@@ -16,6 +17,7 @@ import com.baosight.hggp.hg.sc.tools.HGSCTools;
...
@@ -16,6 +17,7 @@ import com.baosight.hggp.hg.sc.tools.HGSCTools;
import
com.baosight.hggp.hg.wd.domain.HGWD005
;
import
com.baosight.hggp.hg.wd.domain.HGWD005
;
import
com.baosight.hggp.hg.wd.tools.HGWDTools
;
import
com.baosight.hggp.hg.wd.tools.HGWDTools
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.DateUtils
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.MapUtils
;
import
com.baosight.hggp.util.MapUtils
;
...
@@ -143,7 +145,11 @@ public class ServiceHGWD005 extends ServiceEPBase {
...
@@ -143,7 +145,11 @@ public class ServiceHGWD005 extends ServiceEPBase {
dbWd005
.
setUnit
(
dcProductList
.
getUnit
());
dbWd005
.
setUnit
(
dcProductList
.
getUnit
());
dbWd005
.
setClassify
(
dcProductList
.
getFenlei
());
dbWd005
.
setClassify
(
dcProductList
.
getFenlei
());
dbWd005
.
setDeleteFlag
(
DeleteFlagEnum
.
UN_REMOVE
.
getCode
());
dbWd005
.
setDeleteFlag
(
DeleteFlagEnum
.
UN_REMOVE
.
getCode
());
DaoUtils
.
insert
(
HGWD005
.
INSERT
,
dbWd005
);
dbWd005
.
setRecCreator
(
"System"
);
dbWd005
.
setRecCreateTime
(
DateUtils
.
shortDateTime
());
dbWd005
.
setRecRevisor
(
"System"
);
dbWd005
.
setRecReviseTime
(
DateUtils
.
shortDateTime
());
DaoBase
.
getInstance
().
insert
(
HGWD005
.
INSERT
,
dbWd005
);
}
else
{
}
else
{
Map
updateMap
=
new
HashMap
();
Map
updateMap
=
new
HashMap
();
updateMap
.
put
(
HGWD005
.
FIELD_ID
,
dbWd005
.
getId
());
updateMap
.
put
(
HGWD005
.
FIELD_ID
,
dbWd005
.
getId
());
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX005.xml
View file @
59fe56f2
...
@@ -26,6 +26,7 @@
...
@@ -26,6 +26,7 @@
<sqlMap
namespace=
"HGYX005"
>
<sqlMap
namespace=
"HGYX005"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX005A.xml
View file @
59fe56f2
...
@@ -24,6 +24,7 @@
...
@@ -24,6 +24,7 @@
<sqlMap
namespace=
"HGYX005A"
>
<sqlMap
namespace=
"HGYX005A"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX006.xml
View file @
59fe56f2
...
@@ -26,6 +26,7 @@
...
@@ -26,6 +26,7 @@
<sqlMap
namespace=
"HGYX006"
>
<sqlMap
namespace=
"HGYX006"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX007.xml
View file @
59fe56f2
...
@@ -23,6 +23,7 @@
...
@@ -23,6 +23,7 @@
<sqlMap
namespace=
"HGYX007"
>
<sqlMap
namespace=
"HGYX007"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX008.xml
View file @
59fe56f2
...
@@ -25,6 +25,7 @@
...
@@ -25,6 +25,7 @@
<sqlMap
namespace=
"HGYX008"
>
<sqlMap
namespace=
"HGYX008"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX009.xml
View file @
59fe56f2
...
@@ -22,6 +22,7 @@
...
@@ -22,6 +22,7 @@
<sqlMap
namespace=
"HGYX009"
>
<sqlMap
namespace=
"HGYX009"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX010.xml
View file @
59fe56f2
...
@@ -28,6 +28,7 @@
...
@@ -28,6 +28,7 @@
<sqlMap
namespace=
"HGYX010"
>
<sqlMap
namespace=
"HGYX010"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX011.xml
View file @
59fe56f2
...
@@ -26,6 +26,7 @@
...
@@ -26,6 +26,7 @@
<sqlMap
namespace=
"HGYX011"
>
<sqlMap
namespace=
"HGYX011"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX012.xml
View file @
59fe56f2
...
@@ -25,6 +25,7 @@
...
@@ -25,6 +25,7 @@
<sqlMap
namespace=
"HGYX012"
>
<sqlMap
namespace=
"HGYX012"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX013.xml
View file @
59fe56f2
...
@@ -25,6 +25,7 @@
...
@@ -25,6 +25,7 @@
<sqlMap
namespace=
"HGYX013"
>
<sqlMap
namespace=
"HGYX013"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/yx/sql/HGYX014.xml
View file @
59fe56f2
...
@@ -25,6 +25,7 @@
...
@@ -25,6 +25,7 @@
<sqlMap
namespace=
"HGYX014"
>
<sqlMap
namespace=
"HGYX014"
>
<sql
id=
"condition"
>
<sql
id=
"condition"
>
<include
refid=
"HGXSDataAuth.authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
<isNotEmpty
prepend=
" AND "
property=
"id"
>
ID = #id#
ID = #id#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/resources/resources/ibatis/sqlmap-config.xml
View file @
59fe56f2
...
@@ -126,6 +126,17 @@
...
@@ -126,6 +126,17 @@
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX001C.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX001C.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX002.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX002.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX002A.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX002A.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX005.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX005A.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX006.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX007.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX008.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX009.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX010.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX011.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX012.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX013.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/yx/sql/HGYX014.xml"
/>
<!-- 文档库 -->
<!-- 文档库 -->
<sqlMap
resource=
"com/baosight/hggp/hg/wd/sql/HGWD001.xml"
/>
<sqlMap
resource=
"com/baosight/hggp/hg/wd/sql/HGWD001.xml"
/>
...
...
src/main/webapp/HG/SC/HGSC010.js
View file @
59fe56f2
...
@@ -6,21 +6,23 @@ $(function () {
...
@@ -6,21 +6,23 @@ $(function () {
resultGrid
.
dataSource
.
page
(
1
);
resultGrid
.
dataSource
.
page
(
1
);
});
});
IPLATUI
.
EFGrid
.
result
=
{
IPLATUI
.
EFGrid
.
result
=
{
pageable
:
{
pageable
:
{
pageSize
:
20
,
pageSize
:
20
,
pageSizes
:
[
10
,
20
,
50
,
70
,
100
],
pageSizes
:
[
10
,
20
,
50
,
70
,
100
],
},
},
columns
:
[
columns
:
[{
{
field
:
"operator"
,
field
:
"operator"
,
template
:
function
(
item
)
{
template
:
function
(
item
)
{
let
params
=
"'"
+
item
.
companyCode
+
"', '"
+
item
.
companyName
+
"', '"
+
item
.
id
+
"', '"
+
item
.
contractCode
+
"'"
;
let
template
=
''
;
let
template
=
''
;
if
(
item
.
companyCode
)
{
if
(
item
.
companyCode
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showFunc(
\'
'
+
item
.
companyCode
+
'
\'
,
\'
'
+
item
.
companyName
+
'
\'
,
\'
'
+
item
.
id
+
'
\'
,
\'
'
+
item
.
contractCode
+
'
\
'
)" >详情</a>'
;
+
'onclick="showFunc('
+
params
+
')" >详情</a>'
;
}
}
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDoc('
+
params
+
')" >附件</a>'
;
return
template
;
return
template
;
}
}
},
{
},
{
...
@@ -31,8 +33,7 @@ $(function () {
...
@@ -31,8 +33,7 @@ $(function () {
defaultValue
:
function
()
{
defaultValue
:
function
()
{
return
currShortDate
();
return
currShortDate
();
}
}
},
}],
],
beforeEdit
:
function
(
e
)
{
beforeEdit
:
function
(
e
)
{
let
item
=
e
.
model
;
let
item
=
e
.
model
;
if
(
item
.
subStatus
==
'1'
){
if
(
item
.
subStatus
==
'1'
){
...
@@ -177,4 +178,27 @@ function updateStatus() {
...
@@ -177,4 +178,27 @@ function updateStatus() {
}
}
}
}
/**
* 展示附件
*
* @param contractCode
* @param companyName
* @param parentId
* @param contractCode
*/
let
showDoc
=
function
(
companyCode
,
companyName
,
parentId
,
contractCode
){
let
params
=
{
"inqu_status-0-companyCode"
:
companyCode
,
"inqu_status-0-companyName"
:
companyName
,
"inqu_status-0-parentId"
:
parentId
,
"inqu_status-0-contractCode"
:
contractCode
}
JSColorbox
.
open
({
href
:
"HGWD002"
,
title
:
"<div style='text-align: center;'>文档管理</div>"
,
width
:
"100%"
,
height
:
"100%"
,
params
:
params
});
}
src/main/webapp/HG/SC/HGSC010.jsp
View file @
59fe56f2
<%--
Created by IntelliJ IDEA.
User: 1
Date: 2024/9/29
Time: 15:49
To change this template use File | Settings | File Templates.
--%>
<!DOCTYPE html>
<!DOCTYPE html>
<
%@
page
import=
"com.baosight.iplat4j.core.web.threadlocal.UserSession"
%
>
<
%@
page
import=
"com.baosight.iplat4j.core.web.threadlocal.UserSession"
%
>
<
%@
page
contentType=
"text/html;charset=UTF-8"
language=
"java"
%
>
<
%@
page
contentType=
"text/html;charset=UTF-8"
language=
"java"
%
>
...
...
src/main/webapp/HG/WD/HGWD001.js
View file @
59fe56f2
...
@@ -1066,7 +1066,7 @@ let batchDownload = function () {
...
@@ -1066,7 +1066,7 @@ let batchDownload = function () {
message
(
"请先勾选要下载的数据!"
);
message
(
"请先勾选要下载的数据!"
);
return
;
return
;
}
}
JSUtils
.
submitGridsData
(
"result"
,
"HGWD001"
,
"batchDownload"
,
false
,
JSUtils
.
submitGridsData
(
"result"
,
"HGWD001
C
"
,
"batchDownload"
,
false
,
function
(
res
)
{
function
(
res
)
{
if
(
res
.
status
>
-
1
)
{
if
(
res
.
status
>
-
1
)
{
window
.
open
(
res
.
extAttr
.
downloadUrl
,
'_blank'
);
window
.
open
(
res
.
extAttr
.
downloadUrl
,
'_blank'
);
...
...
src/main/webapp/HG/WD/HGWD002.js
View file @
59fe56f2
...
@@ -31,7 +31,7 @@ $(function () {
...
@@ -31,7 +31,7 @@ $(function () {
if
(
document
.
getElementById
(
"splitter"
).
getElementsByClassName
(
"k-splitbar"
).
length
!==
1
)
{
if
(
document
.
getElementById
(
"splitter"
).
getElementsByClassName
(
"k-splitbar"
).
length
!==
1
)
{
$
(
"#splitter"
).
kendoSplitter
({
$
(
"#splitter"
).
kendoSplitter
({
panes
:
[
panes
:
[
{
size
:
"
30%"
,
min
:
"25%"
,
max
:
"75
%"
,
collapsible
:
true
},
{
size
:
"
25%"
,
min
:
"20%"
,
max
:
"80
%"
,
collapsible
:
true
},
{},
{},
{
collapsible
:
true
}
{
collapsible
:
true
}
]
]
...
@@ -251,40 +251,6 @@ let showDownloadRecord = function (fileId, docId) {
...
@@ -251,40 +251,6 @@ let showDownloadRecord = function (fileId, docId) {
}
}
/**
/**
* 预览
*/
let
preview
=
function
()
{
let
url
=
"HGWD002A?inqu_status-0-fileId="
+
$
(
"#inqu_status-0-fileId"
).
val
();
window
.
open
(
url
,
'_blank'
);
}
/**
* 下载
*/
let
download
=
function
()
{
let
rows
=
resultGrid
.
getCheckedRows
();
if
(
rows
.
length
<
1
)
{
message
(
"请选择数据"
);
return
;
}
JSUtils
.
confirm
(
"确定对勾选中的["
+
rows
.
length
+
"]条数据做
\"
下载
\"
操作? "
,
{
ok
:
function
()
{
JSUtils
.
submitGridsData
(
"result"
,
"HGWD001C"
,
"add"
,
false
,
function
(
res
)
{
if
(
res
.
status
>
-
1
)
{
for
(
let
i
=
0
;
i
<
rows
.
length
;
i
++
)
{
window
.
open
(
downloadHref
(
rows
[
i
][
'docId'
]),
'_blank'
);
}
}
else
{
message
(
res
.
msg
);
}
}
);
}
});
}
/**
* 设置树节点的值
* 设置树节点的值
*
*
* @param nodeData
* @param nodeData
...
@@ -307,15 +273,23 @@ let showAuthButton = function () {
...
@@ -307,15 +273,23 @@ let showAuthButton = function () {
// C:目录
// C:目录
if
(
leafType
&&
leafType
>
0
)
{
if
(
leafType
&&
leafType
>
0
)
{
$
(
"#PREVIEW"
).
attr
(
"disabled"
,
false
);
$
(
"#PREVIEW"
).
attr
(
"disabled"
,
false
);
//
$("#DOWNLOAD").attr("disabled", false);
$
(
"#DOWNLOAD"
).
attr
(
"disabled"
,
false
);
}
else
{
}
else
{
$
(
"#PREVIEW"
).
attr
(
"disabled"
,
true
);
$
(
"#PREVIEW"
).
attr
(
"disabled"
,
true
);
//
$("#DOWNLOAD").attr("disabled", true);
$
(
"#DOWNLOAD"
).
attr
(
"disabled"
,
true
);
}
}
}
}
/**
/**
* 预览
* 预览
*/
let
preview
=
function
()
{
let
url
=
"HGWD002A?inqu_status-0-fileId="
+
$
(
"#inqu_status-0-fileId"
).
val
();
window
.
open
(
url
,
'_blank'
);
}
/**
* 预览
*
*
* @param fileId
* @param fileId
* @param docId
* @param docId
...
@@ -323,11 +297,57 @@ let showAuthButton = function () {
...
@@ -323,11 +297,57 @@ let showAuthButton = function () {
* @param docName
* @param docName
*/
*/
let
showPreview
=
function
(
fileId
,
docId
,
docType
,
docName
)
{
let
showPreview
=
function
(
fileId
,
docId
,
docType
,
docName
)
{
if
(
isBlank
(
docId
))
{
addRecordWindow
(
fileId
,
docId
,
docType
,
docName
);
message
(
"附件类型或ID不能为空"
);
}
/**
* 下载
*/
let
download
=
function
()
{
let
rows
=
resultGrid
.
getCheckedRows
();
if
(
rows
.
length
==
0
)
{
message
(
"请先勾选要下载的数据!"
);
return
;
return
;
}
}
$
(
"#previewFile"
).
data
(
"kendoWindow"
).
center
();
if
(
rows
.
length
==
1
)
{
$
(
"#previewFile"
).
data
(
"kendoWindow"
).
open
();
singleDownload
(
rows
[
0
]);
addRecord
(
fileId
,
docId
,
docType
,
docName
);
}
else
{
batchDownload
();
}
}
/**
* 单个下载
*
* @param row
*/
let
singleDownload
=
function
(
row
)
{
let
inInfo
=
new
EiInfo
();
inInfo
.
set
(
"result-0-fileId"
,
row
[
'fileId'
]);
inInfo
.
set
(
"result-0-docId"
,
row
[
'docId'
]);
EiCommunicator
.
send
(
"HGWD001C"
,
"add"
,
inInfo
,
{
onSuccess
(
res
)
{
if
(
res
.
status
>
-
1
)
{
window
.
open
(
CommonUtils
.
downloadFile
(
row
[
'docId'
],
false
),
'_blank'
);
}
else
{
message
(
res
.
msg
);
}
}
},
{
async
:
false
})
}
/**
* 批量下载
*
* @param fileId
* @param docId
*/
let
batchDownload
=
function
()
{
JSUtils
.
submitGridsData
(
"result"
,
"HGWD001C"
,
"batchDownload"
,
false
,
function
(
res
)
{
if
(
res
.
status
>
-
1
)
{
window
.
open
(
res
.
extAttr
.
downloadUrl
,
'_blank'
);
}
}
);
}
}
\ No newline at end of file
src/main/webapp/HG/WD/HGWD002.jsp
View file @
59fe56f2
...
@@ -5,12 +5,6 @@
...
@@ -5,12 +5,6 @@
<c:set
var=
"ctx"
value=
"${pageContext.request.contextPath}"
/>
<c:set
var=
"ctx"
value=
"${pageContext.request.contextPath}"
/>
<script
src=
"${ctx}/common/docxjs/jszip.min.js"
></script>
<script
src=
"${ctx}/common/docxjs/docx-preview.js"
></script>
<script
src=
"${ctx}/common/js/xlsx.full.min.js"
></script>
<script
src=
"${ctx}/HG/WD/HGWD002A1.js"
></script>
<link
rel=
"stylesheet"
href=
"${ctx}/HG/WD/HGWD002A.css"
>
<EF:EFPage
title=
"文档浏览"
>
<EF:EFPage
title=
"文档浏览"
>
<div
id=
"splitter"
class=
"i-fit-height"
>
<div
id=
"splitter"
class=
"i-fit-height"
>
<div
id=
"left-pane"
class=
"i-fit-height"
>
<div
id=
"left-pane"
class=
"i-fit-height"
>
...
@@ -72,25 +66,4 @@
...
@@ -72,25 +66,4 @@
</EF:EFPage>
</EF:EFPage>
<
%
--
预览文件
--
%
>
<jsp:include
page=
"HGWD002A1.jsp"
/>
<EF:EFWindow
id=
"previewFile"
title=
"附件预览"
height=
"100%"
width=
"100%"
>
<div
id=
"descDiv"
class=
"center-flex"
>
<span
id=
"descSpan"
style=
"font-weight: bold;font-size: 18px"
>
附件预览区域...
</span>
</div>
<
%
--
文本预览
--
%
>
<div
id=
"textContainer"
class=
"left-flex"
style=
"display: none;"
>
<pre
id=
"textSpan"
class=
"textSpan"
></pre>
</div>
<
%
--
docx
文件预览
--
%
>
<div
id=
"docxContainer"
style=
"display: none;"
></div>
<
%
--
IMAGE
文件预览
--
%
>
<div
id=
"imageContainer"
class=
"left-flex"
style=
"display: none;"
>
<img
id=
"image"
src=
""
style=
"border: 1px solid gray;width: 100%;height: 100%;"
/>
</div>
<
%
--
other
--
%
>
<iframe
id=
"previewFrame"
src=
""
style=
"display: none;"
></iframe>
</EF:EFWindow>
<
%
--
图片放大区域
--
%
>
<div
id=
"imageOuterDiv"
class=
"imageOuterDiv"
>
<img
id=
"bigImage"
src=
""
/>
</div>
src/main/webapp/HG/WD/HGWD002A.jsp
View file @
59fe56f2
...
@@ -9,12 +9,12 @@
...
@@ -9,12 +9,12 @@
<script
src=
"${ctx}/common/docxjs/docx-preview.js"
></script>
<script
src=
"${ctx}/common/docxjs/docx-preview.js"
></script>
<script
src=
"${ctx}/common/js/xlsx.full.min.js"
></script>
<script
src=
"${ctx}/common/js/xlsx.full.min.js"
></script>
<script
src=
"${ctx}/HG/WD/HGWD002A1.js"
></script>
<script
src=
"${ctx}/HG/WD/HGWD002A1.js"
></script>
<link
rel=
"stylesheet"
href=
"${ctx}/HG/WD/HGWD002A.css"
>
<link
rel=
"stylesheet"
href=
"${ctx}/HG/WD/HGWD002A
1
.css"
>
<EF:EFPage
title=
"
附件
预览"
>
<EF:EFPage
title=
"
文档
预览"
>
<div
class=
"row"
style=
"margin: 0 -10px;"
>
<div
class=
"row"
style=
"margin: 0 -10px;"
>
<div
class=
"col-md-3"
>
<div
class=
"col-md-3"
>
<EF:EFRegion
title=
"文
件
目录树"
id=
"tree"
fitHeight=
"true"
>
<EF:EFRegion
title=
"文
档
目录树"
id=
"tree"
fitHeight=
"true"
>
<EF:EFInput
ename=
"fileId"
cname=
"
文件
ID"
blockId=
"inqu_status"
row=
"0"
type=
"hidden"
/>
<EF:EFInput
ename=
"fileId"
cname=
"
目录
ID"
blockId=
"inqu_status"
row=
"0"
type=
"hidden"
/>
<EF:EFInput
ename=
"source"
cname=
"来源"
blockId=
"inqu_status"
row=
"0"
type=
"hidden"
/>
<EF:EFInput
ename=
"source"
cname=
"来源"
blockId=
"inqu_status"
row=
"0"
type=
"hidden"
/>
<div
id=
"menu"
style=
"margin-top: 12px; margin-bottom: 8px"
>
<div
id=
"menu"
style=
"margin-top: 12px; margin-bottom: 8px"
>
<EF:EFTree
bindId=
"docTree"
ename=
"node"
textField=
"text"
valueField=
"label"
hasChildren=
"leaf"
<EF:EFTree
bindId=
"docTree"
ename=
"node"
textField=
"text"
valueField=
"label"
hasChildren=
"leaf"
...
...
src/main/webapp/HG/WD/HGWD002A.css
→
src/main/webapp/HG/WD/HGWD002A
1
.css
View file @
59fe56f2
File moved
src/main/webapp/HG/WD/HGWD002A1.js
View file @
59fe56f2
/**
/**
* 弹窗预览
*
* @param fileId
* @param docId
* @param docType
* @param docName
*/
function
addRecordWindow
(
fileId
,
docId
,
docType
,
docName
)
{
$
(
"#previewFile"
).
data
(
"kendoWindow"
).
center
();
$
(
"#previewFile"
).
data
(
"kendoWindow"
).
open
();
addRecord
(
fileId
,
docId
,
docType
,
docName
);
}
/**
* 新增预览记录
* 新增预览记录
*
*
* @param fileId
* @param fileId
* @param docId
* @param docId
* @param docType
* @param docType
*/
*/
function
addRecord
(
fileId
,
docId
,
docType
,
docName
){
function
addRecord
(
fileId
,
docId
,
docType
,
docName
)
{
if
(
isBlank
(
docId
))
{
message
(
"附件类型或ID不能为空"
);
return
;
}
// 隐藏预览区域
// 隐藏预览区域
hideHtml
();
hideHtml
();
IPLAT
.
progress
(
$
(
"body"
),
true
);
IPLAT
.
progress
(
$
(
"body"
),
true
);
...
...
src/main/webapp/HG/WD/HGWD002A1.jsp
0 → 100644
View file @
59fe56f2
<!DOCTYPE html>
<
%@
page
contentType=
"text/html; charset=UTF-8"
%
>
<
%@
taglib
uri=
"http://java.sun.com/jsp/jstl/core"
prefix=
"c"
%
>
<
%@
taglib
prefix=
"EF"
tagdir=
"/WEB-INF/tags/EF"
%
>
<script
src=
"${ctx}/common/docxjs/jszip.min.js"
></script>
<script
src=
"${ctx}/common/docxjs/docx-preview.js"
></script>
<script
src=
"${ctx}/common/js/xlsx.full.min.js"
></script>
<script
src=
"${ctx}/HG/WD/HGWD002A1.js"
></script>
<link
rel=
"stylesheet"
href=
"${ctx}/HG/WD/HGWD002A1.css"
>
<
%
--
预览文件
--
%
>
<EF:EFWindow
id=
"previewFile"
title=
"附件预览"
height=
"100%"
width=
"100%"
>
<div
id=
"descDiv"
class=
"center-flex"
>
<span
id=
"descSpan"
style=
"font-weight: bold;font-size: 18px"
>
附件预览区域...
</span>
</div>
<
%
--
文本预览
--
%
>
<div
id=
"textContainer"
class=
"left-flex"
style=
"display: none;"
>
<pre
id=
"textSpan"
class=
"textSpan"
></pre>
</div>
<
%
--
docx
文件预览
--
%
>
<div
id=
"docxContainer"
style=
"display: none;"
></div>
<
%
--
IMAGE
文件预览
--
%
>
<div
id=
"imageContainer"
class=
"left-flex"
style=
"display: none;"
>
<img
id=
"image"
src=
""
style=
"border: 1px solid gray;width: 100%;height: 100%;"
/>
</div>
<
%
--
other
--
%
>
<iframe
id=
"previewFrame"
src=
""
style=
"display: none;"
></iframe>
</EF:EFWindow>
<
%
--
图片放大区域
--
%
>
<div
id=
"imageOuterDiv"
class=
"imageOuterDiv"
>
<img
id=
"bigImage"
src=
""
/>
</div>
\ No newline at end of file
src/main/webapp/common/js/common.js
View file @
59fe56f2
...
@@ -628,7 +628,7 @@ function loadChange(grid,e,field) {
...
@@ -628,7 +628,7 @@ function loadChange(grid,e,field) {
*
*
* @param bizType
* @param bizType
* @param bizId
* @param bizId
* @param
* @param
callback
*/
*/
let
uploadFile
=
function
(
bizType
,
bizId
,
callback
)
{
let
uploadFile
=
function
(
bizType
,
bizId
,
callback
)
{
let
params
=
{
let
params
=
{
...
@@ -650,14 +650,30 @@ function loadChange(grid,e,field) {
...
@@ -650,14 +650,30 @@ function loadChange(grid,e,field) {
}
}
/**
/**
* 文件下载路径
*
* @param docId
* @param isPreview 是否预览,true:预览
* @returns {string}
*/
let
downloadFile
=
function
(
docId
,
isPreview
)
{
if
(
isPreview
)
{
return
IPLATUI
.
CONTEXT_PATH
+
'/file/download/preview/'
+
docId
;
}
else
{
// S3地址必须支持公网
return
IPLATUI
.
CONTEXT_PATH
+
'/file/download/'
+
docId
;
}
}
/**
* 预览
* 预览
*
*
* @param docId 文件ID
* @param docId 文件ID
* @param docName 文件名称必须带后缀
* @param docName 文件名称必须带后缀
*/
*/
function
previewFile
(
docId
,
docName
)
{
let
previewFile
=
function
(
docId
,
docName
)
{
let
hostname
=
window
.
location
.
hostname
;
let
hostname
=
window
.
location
.
hostname
;
let
domain
=
hostname
===
"localhost"
?
"http://129.211.46.84:8085"
:
window
.
location
.
origin
;
let
domain
=
hostname
===
"localhost"
?
"http://129.211.46.84:8085"
:
window
.
location
.
origin
;
let
url
=
domain
+
IPLATUI
.
CONTEXT_PATH
+
'/file/download/preview/'
+
docId
let
url
=
domain
+
IPLATUI
.
CONTEXT_PATH
+
'/file/download/preview/'
+
docId
+
"?fullfilename="
;
+
"?fullfilename="
;
// Base64转码
// Base64转码
...
@@ -684,6 +700,7 @@ function loadChange(grid,e,field) {
...
@@ -684,6 +700,7 @@ function loadChange(grid,e,field) {
$
.
extend
(
window
,
{
$
.
extend
(
window
,
{
CommonUtils
:
{
CommonUtils
:
{
uploadFile
:
uploadFile
,
uploadFile
:
uploadFile
,
downloadFile
:
downloadFile
,
previewFile
:
previewFile
,
previewFile
:
previewFile
,
}
}
});
});
...
...
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