Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doc-transform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
doc-transform
Commits
8ab87b69
Commit
8ab87b69
authored
Sep 22, 2022
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改控件初始值
parent
6cf22947
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
17 additions
and
20 deletions
+17
-20
doc-transform-manage-ui/admin/src/router.js
doc-transform-manage-ui/admin/src/router.js
+1
-1
doc-transform-manage-ui/admin/src/views/doc/form/show.vue
doc-transform-manage-ui/admin/src/views/doc/form/show.vue
+1
-2
doc-transform-manager/src/main/java/com/mortals/xhx/common/formdesign/component/DesignCheckboxComponent.java
.../common/formdesign/component/DesignCheckboxComponent.java
+3
-7
doc-transform-manager/src/main/java/com/mortals/xhx/common/formdesign/component/DesignRadioComponent.java
...xhx/common/formdesign/component/DesignRadioComponent.java
+3
-7
doc-transform-manager/src/main/java/com/mortals/xhx/common/formdesign/component/DesignSelectComponent.java
...hx/common/formdesign/component/DesignSelectComponent.java
+3
-3
doc-transform-manager/src/main/java/com/mortals/xhx/module/doc/baseinfo/web/DocBaseinfoController.java
...ls/xhx/module/doc/baseinfo/web/DocBaseinfoController.java
+4
-0
doc-transform-manager/src/main/java/com/mortals/xhx/module/doc/template/service/impl/DocTemplateServiceImpl.java
...ule/doc/template/service/impl/DocTemplateServiceImpl.java
+2
-0
No files found.
doc-transform-manage-ui/admin/src/router.js
View file @
8ab87b69
...
...
@@ -33,7 +33,7 @@ const router = new Router({
// builder('/template/form', 'tool/build/docIndex'),//模板表单配置
builder
(
'
/
template
/form/view
'
,
'
doc/form/show
'
),
//模板表单配置
builder
(
'
/
doc
/form/view
'
,
'
doc/form/show
'
),
//模板表单配置
...
restBuilder
(
'
platform
'
,
'
platform
'
),
// 系统管理-区域管理
...
...
doc-transform-manage-ui/admin/src/views/doc/form/show.vue
View file @
8ab87b69
<
template
>
<div
class=
"page"
>
<form-designer
ref=
"formDesigner"
:value=
tmp
v-model=
"form1.fdForm"
></form-designer>
<form-designer
ref=
"formDesigner"
:value=
"tmp"
v-model=
"form1.fdForm"
></form-designer>
</div>
</
template
>
...
...
@@ -18,7 +18,6 @@
},
methods
:
{
beforeRender
(
data
)
{
this
.
tmp
=
data
.
entity
.
formContent
this
.
$refs
.
formDesigner
.
refresh
(
this
.
tmp
);
...
...
doc-transform-manager/src/main/java/com/mortals/xhx/common/formdesign/component/DesignCheckboxComponent.java
View file @
8ab87b69
...
...
@@ -71,20 +71,16 @@ public class DesignCheckboxComponent extends DesignComponent {
* @param columnsItem
*/
private
void
initDefaultCheckBoxValue
(
ComponentCons
cons
,
ListItem
columnsItem
)
{
if
(
cons
.
getVal
().
indexOf
(
"
v
"
)
!=
-
1
)
{
String
cks
=
StringUtils
.
substringBetween
(
cons
.
getVal
(),
"
v"
,
"v
"
);
if
(
cons
.
getVal
().
indexOf
(
"
<
"
)
!=
-
1
)
{
String
cks
=
StringUtils
.
substringBetween
(
cons
.
getVal
(),
"
<"
,
">
"
);
if
(
ObjectUtils
.
isEmpty
(
cks
))
return
;
List
<
OptionsItem
>
optionsItemList
=
StrUtil
.
splitTrim
(
cks
,
"
_
"
,
-
1
).
stream
().
map
(
option
->
{
List
<
OptionsItem
>
optionsItemList
=
StrUtil
.
splitTrim
(
cks
,
"
-
"
,
-
1
).
stream
().
map
(
option
->
{
OptionsItem
options
=
new
OptionsItem
();
options
.
setLabel
(
option
);
options
.
setValue
(
option
);
return
options
;
}).
collect
(
Collectors
.
toList
());
columnsItem
.
setOptions
(
optionsItemList
);
// cons.setVal(cons.getVal().substring(0, cons.getVal().indexOf("[")));
// cons.setLabel(cons.getLabel().substring(0, cons.getLabel().indexOf("[")));
}
}
...
...
doc-transform-manager/src/main/java/com/mortals/xhx/common/formdesign/component/DesignRadioComponent.java
View file @
8ab87b69
...
...
@@ -63,20 +63,16 @@ public class DesignRadioComponent extends DesignComponent {
}
private
void
initDefaultRadioValue
(
ComponentCons
cons
,
ListItem
columnsItem
)
{
if
(
cons
.
getVal
().
indexOf
(
"
v
"
)
!=
-
1
)
{
String
cks
=
StringUtils
.
substringBetween
(
cons
.
getVal
(),
"
v"
,
"v
"
);
if
(
cons
.
getVal
().
indexOf
(
"
<
"
)
!=
-
1
)
{
String
cks
=
StringUtils
.
substringBetween
(
cons
.
getVal
(),
"
<"
,
">
"
);
if
(
ObjectUtils
.
isEmpty
(
cks
))
return
;
List
<
OptionsItem
>
optionsItemList
=
StrUtil
.
splitTrim
(
cks
,
"
_
"
,
-
1
).
stream
().
map
(
option
->
{
List
<
OptionsItem
>
optionsItemList
=
StrUtil
.
splitTrim
(
cks
,
"
-
"
,
-
1
).
stream
().
map
(
option
->
{
OptionsItem
options
=
new
OptionsItem
();
options
.
setLabel
(
option
);
options
.
setValue
(
option
);
return
options
;
}).
collect
(
Collectors
.
toList
());
columnsItem
.
setOptions
(
optionsItemList
);
// cons.setVal(cons.getVal().substring(0, cons.getVal().indexOf("[")));
// cons.setLabel(cons.getLabel().substring(0, cons.getLabel().indexOf("[")));
}
}
...
...
doc-transform-manager/src/main/java/com/mortals/xhx/common/formdesign/component/DesignSelectComponent.java
View file @
8ab87b69
...
...
@@ -76,10 +76,10 @@ public class DesignSelectComponent extends DesignComponent {
columnsItem
.
setOptions
(
optionsItems
);
}
if
(
cons
.
getVal
().
indexOf
(
"
v
"
)
!=
-
1
)
{
String
cks
=
StringUtils
.
substringBetween
(
cons
.
getVal
(),
"
v"
,
"v
"
);
if
(
cons
.
getVal
().
indexOf
(
"
<
"
)
!=
-
1
)
{
String
cks
=
StringUtils
.
substringBetween
(
cons
.
getVal
(),
"
<"
,
">
"
);
if
(
ObjectUtils
.
isEmpty
(
cks
))
return
;
List
<
OptionsItem
>
optionsItemList
=
StrUtil
.
splitTrim
(
cks
,
"
_
"
,
-
1
).
stream
().
map
(
option
->
{
List
<
OptionsItem
>
optionsItemList
=
StrUtil
.
splitTrim
(
cks
,
"
-
"
,
-
1
).
stream
().
map
(
option
->
{
OptionsItem
options
=
new
OptionsItem
();
options
.
setLabel
(
option
);
options
.
setValue
(
option
);
...
...
doc-transform-manager/src/main/java/com/mortals/xhx/module/doc/baseinfo/web/DocBaseinfoController.java
View file @
8ab87b69
...
...
@@ -7,6 +7,7 @@ import com.mortals.xhx.base.system.param.service.ParamService;
import
com.mortals.xhx.module.doc.baseinfo.model.DocBaseinfoEntity
;
import
com.mortals.xhx.module.doc.form.model.DocFormEntity
;
import
com.mortals.xhx.module.doc.form.model.vo.DocFormVo
;
import
com.mortals.xhx.module.doc.form.service.DocFormService
;
import
com.mortals.xhx.module.doc.template.model.vo.DocTemplateVo
;
import
com.mortals.xhx.module.platform.model.PlatformQuery
;
import
com.mortals.xhx.module.platform.service.PlatformService
;
...
...
@@ -39,6 +40,8 @@ public class DocBaseinfoController extends BaseCRUDJsonBodyMappingController<Doc
@Autowired
private
PlatformService
platformService
;
@Autowired
private
DocFormService
docFormService
;
public
DocBaseinfoController
()
{
super
.
setFormClass
(
DocBaseinfoForm
.
class
);
...
...
@@ -91,6 +94,7 @@ public class DocBaseinfoController extends BaseCRUDJsonBodyMappingController<Doc
jsonObject
.
put
(
"mergeDoc"
,
vals
[
0
]);
jsonObject
.
put
(
"preview"
,
vals
[
1
]);
// jsonObject.put("redirectUrl", redirectUrl);
docFormService
.
save
(
docFormVo
,
getContext
());
}
catch
(
Exception
e
)
{
log
.
error
(
"合成表单异常"
,
e
);
...
...
doc-transform-manager/src/main/java/com/mortals/xhx/module/doc/template/service/impl/DocTemplateServiceImpl.java
View file @
8ab87b69
...
...
@@ -9,6 +9,7 @@ import com.deepoove.poi.XWPFTemplate;
import
com.deepoove.poi.config.Configure
;
import
com.deepoove.poi.config.ConfigureBuilder
;
import
com.deepoove.poi.template.MetaTemplate
;
import
com.deepoove.poi.util.RegexUtils
;
import
com.mortals.framework.exception.AppException
;
import
com.mortals.framework.model.Context
;
import
com.mortals.framework.service.impl.AbstractCRUDServiceImpl
;
...
...
@@ -218,6 +219,7 @@ public class DocTemplateServiceImpl extends AbstractCRUDServiceImpl<DocTemplateD
builder
.
setValidErrorHandler
(
new
Configure
.
DiscardHandler
());
builder
.
useDefaultEL
(
false
);
builder
.
buildGrammerRegex
(
RegexUtils
.
createGeneral
(
"{{"
,
"}}"
));
//builder.buildGramer("[","]");
XWPFTemplate
template
=
XWPFTemplate
.
compile
(
filepath
,
builder
.
build
());
FormDesignRoot
root
=
new
FormDesignRoot
();
...
...
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