Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
C
chinafrica
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
zhengfg
chinafrica
Commits
35afd3b8
提交
35afd3b8
authored
3月 16, 2021
作者:
吴德鹏
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
新增是否强制更新
上级
84b45a2e
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
214 行增加
和
147 行删除
+214
-147
TbCfVersionEntity.java
.../src/main/java/com/platform/entity/TbCfVersionEntity.java
+16
-0
TbCfVersionDao.xml
...in/src/main/resources/com/platform/dao/TbCfVersionDao.xml
+56
-50
platform.properties
platform-admin/src/main/resources/dev/platform.properties
+1
-1
platform.properties
platform-admin/src/main/resources/prod/platform.properties
+1
-1
tbcfversion.html
...m-admin/src/main/webapp/WEB-INF/page/sys/tbcfversion.html
+41
-19
tbcfversion.js
platform-admin/src/main/webapp/js/sys/tbcfversion.js
+99
-76
没有找到文件。
platform-admin/src/main/java/com/platform/entity/TbCfVersionEntity.java
浏览文件 @
35afd3b8
...
@@ -33,6 +33,10 @@ public class TbCfVersionEntity implements Serializable {
...
@@ -33,6 +33,10 @@ public class TbCfVersionEntity implements Serializable {
* 版本分类(0安卓,1苹果)
* 版本分类(0安卓,1苹果)
*/
*/
private
Integer
versionSort
;
private
Integer
versionSort
;
private
Integer
status
;
/**
/**
* 设置:版本号Id
* 设置:版本号Id
*/
*/
...
@@ -46,6 +50,7 @@ public class TbCfVersionEntity implements Serializable {
...
@@ -46,6 +50,7 @@ public class TbCfVersionEntity implements Serializable {
public
String
getVersionId
()
{
public
String
getVersionId
()
{
return
versionId
;
return
versionId
;
}
}
/**
/**
* 设置:版本code
* 设置:版本code
*/
*/
...
@@ -59,6 +64,7 @@ public class TbCfVersionEntity implements Serializable {
...
@@ -59,6 +64,7 @@ public class TbCfVersionEntity implements Serializable {
public
String
getVersionCode
()
{
public
String
getVersionCode
()
{
return
versionCode
;
return
versionCode
;
}
}
/**
/**
* 设置:版本更新链接
* 设置:版本更新链接
*/
*/
...
@@ -72,6 +78,7 @@ public class TbCfVersionEntity implements Serializable {
...
@@ -72,6 +78,7 @@ public class TbCfVersionEntity implements Serializable {
public
String
getVersionLike
()
{
public
String
getVersionLike
()
{
return
versionLike
;
return
versionLike
;
}
}
/**
/**
* 设置:版本更新内容
* 设置:版本更新内容
*/
*/
...
@@ -92,10 +99,19 @@ public class TbCfVersionEntity implements Serializable {
...
@@ -92,10 +99,19 @@ public class TbCfVersionEntity implements Serializable {
public
Integer
getVersionSort
()
{
public
Integer
getVersionSort
()
{
return
versionSort
;
return
versionSort
;
}
}
/**
/**
* 设置: 版本分类(0安卓,1苹果)
* 设置: 版本分类(0安卓,1苹果)
*/
*/
public
void
setVersionSort
(
Integer
versionSort
)
{
public
void
setVersionSort
(
Integer
versionSort
)
{
this
.
versionSort
=
versionSort
;
this
.
versionSort
=
versionSort
;
}
}
public
Integer
getStatus
()
{
return
status
;
}
public
void
setStatus
(
Integer
status
)
{
this
.
status
=
status
;
}
}
}
platform-admin/src/main/resources/com/platform/dao/TbCfVersionDao.xml
浏览文件 @
35afd3b8
...
@@ -8,88 +8,94 @@
...
@@ -8,88 +8,94 @@
<result
property=
"versionCode"
column=
"version_code"
/>
<result
property=
"versionCode"
column=
"version_code"
/>
<result
property=
"versionLike"
column=
"version_like"
/>
<result
property=
"versionLike"
column=
"version_like"
/>
<result
property=
"versionDetail"
column=
"version_detail"
/>
<result
property=
"versionDetail"
column=
"version_detail"
/>
<result
property=
"versionSort"
column=
"version_sort"
/>
<result
property=
"versionSort"
column=
"version_sort"
/>
<result
property=
"status"
column=
"status"
/>
</resultMap>
</resultMap>
<select
id=
"queryObject"
resultType=
"com.platform.entity.TbCfVersionEntity"
>
<select
id=
"queryObject"
resultType=
"com.platform.entity.TbCfVersionEntity"
>
select
select
`version_id`,
`version_id`,
`version_code`,
`version_code`,
`version_like`,
`version_like`,
`version_detail`,
`version_detail`,
`version_sort`
`version_sort`,
status
from tb_cf_version
from tb_cf_version
where version_id = #{id}
where version_id = #{id}
</select>
</select>
<select
id=
"queryList"
resultType=
"com.platform.entity.TbCfVersionEntity"
>
<select
id=
"queryList"
resultType=
"com.platform.entity.TbCfVersionEntity"
>
select
select
`version_id`,
`version_id`,
`version_code`,
`version_code`,
`version_like`,
`version_like`,
`version_detail`,
`version_detail`,
`version_sort`
`version_sort`,
from tb_cf_version
status
WHERE 1=1
from tb_cf_version
<if
test=
"name != null and name.trim() != ''"
>
WHERE 1=1
AND name LIKE concat('%',#{name},'%')
<if
test=
"name != null and name.trim() != ''"
>
</if>
AND name LIKE concat('%',#{name},'%')
</if>
<choose>
<choose>
<when
test=
"sidx != null and sidx.trim() != ''"
>
<when
test=
"sidx != null and sidx.trim() != ''"
>
order by ${sidx} ${order}
order by ${sidx} ${order}
</when>
</when>
<otherwise>
<otherwise>
order by version_id desc
order by version_id desc
</otherwise>
</otherwise>
</choose>
</choose>
<if
test=
"offset != null and limit != null"
>
<if
test=
"offset != null and limit != null"
>
limit #{offset}, #{limit}
limit #{offset}, #{limit}
</if>
</if>
</select>
</select>
<select
id=
"queryTotal"
resultType=
"int"
>
<select
id=
"queryTotal"
resultType=
"int"
>
select count(*) from tb_cf_version
select count(*) from tb_cf_version
WHERE 1=1
WHERE 1=1
<if
test=
"name != null and name.trim() != ''"
>
<if
test=
"name != null and name.trim() != ''"
>
AND name LIKE concat('%',#{name},'%')
AND name LIKE concat('%',#{name},'%')
</if>
</if>
</select>
</select>
<insert
id=
"save"
parameterType=
"com.platform.entity.TbCfVersionEntity"
>
<insert
id=
"save"
parameterType=
"com.platform.entity.TbCfVersionEntity"
>
insert into tb_cf_version(
insert into tb_cf_version(
`version_id`,
`version_id`,
`version_code`,
`version_code`,
`version_like`,
`version_like`,
`version_detail`,
`version_detail`,
`version_sort`)
`version_sort`,
status)
values(
values(
#{versionId},
#{versionId},
#{versionCode},
#{versionCode},
#{versionLike},
#{versionLike},
#{versionDetail},
#{versionDetail},
#{versionSort})
#{versionSort},
#{status})
</insert>
</insert>
<update
id=
"update"
parameterType=
"com.platform.entity.TbCfVersionEntity"
>
<update
id=
"update"
parameterType=
"com.platform.entity.TbCfVersionEntity"
>
update tb_cf_version
update tb_cf_version
<set>
<set>
<if
test=
"versionCode != null"
>
`version_code` = #{versionCode},
</if>
<if
test=
"versionCode != null"
>
`version_code` = #{versionCode},
</if>
<if
test=
"versionSort != null"
>
`version_sort` = #{versionSort},
</if>
<if
test=
"versionSort != null"
>
`version_sort` = #{versionSort},
</if>
<if
test=
"versionLike != null"
>
`version_like` = #{versionLike},
</if>
<if
test=
"versionLike != null"
>
`version_like` = #{versionLike},
</if>
<if
test=
"versionDetail != null"
>
`version_detail` = #{versionDetail}
</if>
<if
test=
"versionDetail != null"
>
`version_detail` = #{versionDetail},
</if>
<if
test=
"status != null"
>
`status` = #{status}
</if>
</set>
</set>
where version_id = #{versionId}
where version_id = #{versionId}
</update>
</update>
<delete
id=
"delete"
>
<delete
id=
"delete"
>
delete from tb_cf_version where version_id = #{value}
delete from tb_cf_version where version_id = #{value}
</delete>
</delete>
<delete
id=
"deleteBatch"
>
delete from tb_cf_version where version_id in
<foreach
item=
"versionId"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{versionId}
</foreach>
</delete>
</mapper>
<delete
id=
"deleteBatch"
>
\ No newline at end of file
delete from tb_cf_version where version_id in
<foreach
item=
"versionId"
collection=
"array"
open=
"("
separator=
","
close=
")"
>
#{versionId}
</foreach>
</delete>
</mapper>
platform-admin/src/main/resources/dev/platform.properties
浏览文件 @
35afd3b8
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
#jdbc.password=diaoyun666
#jdbc.password=diaoyun666
jdbc.url
:
jdbc:mysql://159.138.48.71:3306/
chinafrica
?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
jdbc.url
:
jdbc:mysql://159.138.48.71:3306/
test
?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
jdbc.username
:
root
jdbc.username
:
root
jdbc.password
:
Diaoyunnuli.8
jdbc.password
:
Diaoyunnuli.8
...
...
platform-admin/src/main/resources/prod/platform.properties
浏览文件 @
35afd3b8
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
#jdbc.password=diaoyun666
#jdbc.password=diaoyun666
jdbc.url
:
jdbc:mysql://159.138.48.71:3306/
chinafrica
?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
jdbc.url
:
jdbc:mysql://159.138.48.71:3306/
test
?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
jdbc.username
:
root
jdbc.username
:
root
jdbc.password
:
Diaoyunnuli.8
jdbc.password
:
Diaoyunnuli.8
...
...
platform-admin/src/main/webapp/WEB-INF/page/sys/tbcfversion.html
浏览文件 @
35afd3b8
...
@@ -4,9 +4,10 @@
...
@@ -4,9 +4,10 @@
<title></title>
<title></title>
#parse("sys/header.html")
#parse("sys/header.html")
<style>
<style>
.ui-jqgrid
.ui-jqgrid-bdiv
{
.ui-jqgrid
.ui-jqgrid-bdiv
{
height
:
auto
!important
;
height
:
auto
!important
;
}
}
.table
>
thead
>
tr
>
th
,
.table
>
tbody
>
tr
>
th
,
.table
>
tfoot
>
tr
>
th
,
.table
>
thead
>
tr
>
td
,
.table
>
tbody
>
tr
>
td
,
.table
>
tfoot
>
tr
>
td
{
.table
>
thead
>
tr
>
th
,
.table
>
tbody
>
tr
>
th
,
.table
>
tfoot
>
tr
>
th
,
.table
>
thead
>
tr
>
td
,
.table
>
tbody
>
tr
>
td
,
.table
>
tfoot
>
tr
>
td
{
border-top
:
2px
solid
#e7eaec
;
border-top
:
2px
solid
#e7eaec
;
line-height
:
1.38857
;
line-height
:
1.38857
;
...
@@ -17,7 +18,7 @@
...
@@ -17,7 +18,7 @@
</head>
</head>
<body>
<body>
<div
id=
"rrapp"
v-cloak
style=
"height: calc(100% - 15px);"
>
<div
id=
"rrapp"
v-cloak
style=
"height: calc(100% - 15px);"
>
<div
v-show=
"showList"
style=
"height: 100%;"
>
<div
v-show=
"showList"
style=
"height: 100%;"
>
<Row
:gutter=
"16"
>
<Row
:gutter=
"16"
>
<div
class=
"search-group"
>
<div
class=
"search-group"
>
<i-col
span=
"4"
>
<i-col
span=
"4"
>
...
@@ -39,49 +40,70 @@
...
@@ -39,49 +40,70 @@
</div>
</div>
</Row>
</Row>
<div
id=
"speedp"
></div>
<div
id=
"speedp"
></div>
<table
id=
"jqGrid"
></table>
<table
id=
"jqGrid"
></table>
</div>
</div>
<Card
v-show=
"!showList"
>
<Card
v-show=
"!showList"
>
<p
slot=
"title"
>
{{title}}
</p>
<p
slot=
"title"
>
{{title}}
</p>
<i-form
ref=
"formValidate"
:model=
"tbCfVersion"
:rules=
"ruleValidate"
:label-width=
"80"
>
<i-form
ref=
"formValidate"
:model=
"tbCfVersion"
:rules=
"ruleValidate"
:label-width=
"80"
>
<Form-item
label=
"版本code"
prop=
"versionCode"
>
<Form-item
label=
"版本code"
prop=
"versionCode"
style=
"width:800px"
>
<i-input
v-model=
"tbCfVersion.versionCode"
placeholder=
"版本code"
/>
<i-input
v-model=
"tbCfVersion.versionCode"
placeholder=
"版本code"
/>
</Form-item>
</Form-item>
<Form-item
label=
"版本分类"
prop=
"versionSort"
>
<!-- <Form-item label="版本分类" prop="versionSort" style="width:800px">
<i-select
placeholder=
"版本分类"
v-model=
"tbCfVersion.versionSort"
>
<i-select placeholder="版本分类" v-model="tbCfVersion.versionSort">
<i-option
value=
"0"
>
安卓
</i-option>
<i-option value="0">安卓</i-option>
<i-option
value=
"1"
>
苹果
</i-option>
<i-option value="1">苹果</i-option>
</i-select>
</Form-item>
<Form-item label="是否强制更新" prop="status" style="width:800px">
<i-select placeholder="是否强制更新" v-model="tbCfVersion.status">
<i-option value="1">是</i-option>
<i-option value="0">否</i-option>
</i-select>
</Form-item>-->
<Form-item
label=
"版本分类"
prop=
"versionSort"
style=
"width:800px"
>
<i-select
placeholder=
"请选择"
v-model=
"tbCfVersion.versionSort"
>
<i-option
v-for=
" e in versionList"
:value=
"e.value"
>
{{e.label}}
</i-option>
</i-select>
</Form-item>
<Form-item
label=
"是否强制更新"
prop=
"status"
style=
"width:800px"
>
<i-select
placeholder=
"请选择"
v-model=
"tbCfVersion.status"
>
<i-option
v-for=
" e in statusList"
:value=
"e.value"
>
{{e.label}}
</i-option>
</i-select>
</i-select>
</Form-item>
</Form-item>
<Form-item
label=
"版本更新链接"
prop=
"versionLike"
>
<Form-item
label=
"版本更新链接"
prop=
"versionLike"
style=
"width:800px"
>
<i-input
v-model=
"tbCfVersion.versionLike"
placeholder=
"版本更新链接"
/>
<i-input
v-model=
"tbCfVersion.versionLike"
placeholder=
"版本更新链接"
/>
</Form-item>
</Form-item>
<Form-item
label=
"版本更新内容"
prop=
"versionDetail"
>
<Form-item
label=
"版本更新内容"
prop=
"versionDetail"
style=
"width:800px"
>
<!-- <script id="Detail" name="tbCfVersion.versionDetail"type="text/plain">${pd.COLLSORT_DETAILS}</script>-->
<!-- <script id="Detail" name="tbCfVersion.versionDetail"type="text/plain">${pd.COLLSORT_DETAILS}</script>-->
<textarea
id=
"Detail"
style=
"width: 800px;height: 600px;"
></textarea>
<textarea
id=
"Detail"
style=
"width: 800px;height: 600px;"
></textarea>
</Form-item>
</Form-item>
<Form-item>
<Form-item>
<i-button
type=
"primary"
@
click=
"handleSubmit('formValidate')"
>
提交
</i-button>
<i-button
type=
"primary"
@
click=
"handleSubmit('formValidate')"
>
提交
</i-button>
<i-button
type=
"warning"
@
click=
"reload"
style=
"margin-left: 8px"
/>
返回
</i-button>
<i-button
type=
"warning"
@
click=
"reload"
style=
"margin-left: 8px"
/>
返回
</i-button>
<i-button
type=
"ghost"
@
click=
"handleReset('formValidate')"
style=
"margin-left: 8px"
>
重置
</i-button>
<i-button
type=
"ghost"
@
click=
"handleReset('formValidate')"
style=
"margin-left: 8px"
>
重置
</i-button>
</Form-item>
</Form-item>
</i-form>
</i-form>
</Card>
</Card>
</div>
</div>
<script
src=
"${rc.contextPath}/js/sys/tbcfversion.js?_${date.systemTime}"
></script>
<script
src=
"${rc.contextPath}/js/sys/tbcfversion.js?_${date.systemTime}"
></script>
<script
type=
"text/javascript"
>
<script
type=
"text/javascript"
>
var
content
=
UE
.
getEditor
(
'Detail'
);
var
content
=
UE
.
getEditor
(
'Detail'
);
UE
.
Editor
.
prototype
.
_bkGetActionUrl
=
UE
.
Editor
.
prototype
.
getActionUrl
;
UE
.
Editor
.
prototype
.
_bkGetActionUrl
=
UE
.
Editor
.
prototype
.
getActionUrl
;
UE
.
Editor
.
prototype
.
getActionUrl
=
function
(
action
)
{
UE
.
Editor
.
prototype
.
getActionUrl
=
function
(
action
)
{
if
(
action
==
'uploadimage'
||
action
==
'uploadscrawl'
||
action
==
'uploadimage'
)
{
if
(
action
==
'uploadimage'
||
action
==
'uploadscrawl'
||
action
==
'uploadimage'
)
{
return
'${rc.contextPath}/api/osstest/uploaditemimage'
;
return
'${rc.contextPath}/api/osstest/uploaditemimage'
;
}
else
{
}
else
{
return
this
.
_bkGetActionUrl
.
call
(
this
,
action
);
return
this
.
_bkGetActionUrl
.
call
(
this
,
action
);
}
}
};
};
</script>
</script>
</body>
</body>
</html>
</html>
\ No newline at end of file
platform-admin/src/main/webapp/js/sys/tbcfversion.js
浏览文件 @
35afd3b8
...
@@ -2,119 +2,142 @@ $(function () {
...
@@ -2,119 +2,142 @@ $(function () {
$
(
"#jqGrid"
).
Grid
({
$
(
"#jqGrid"
).
Grid
({
url
:
'../tbcfversion/list'
,
url
:
'../tbcfversion/list'
,
colModel
:
[
colModel
:
[
{
label
:
'versionId'
,
name
:
'versionId'
,
index
:
'version_id'
,
key
:
true
,
hidden
:
true
},
{
label
:
'versionId'
,
name
:
'versionId'
,
index
:
'version_id'
,
key
:
true
,
hidden
:
true
},
{
label
:
'版本code'
,
name
:
'versionCode'
,
index
:
'version_code'
,
width
:
80
},
{
label
:
'版本code'
,
name
:
'versionCode'
,
index
:
'version_code'
,
width
:
80
},
{
label
:
'版本更新链接'
,
name
:
'versionLike'
,
index
:
'version_like'
,
width
:
80
},
{
label
:
'版本更新链接'
,
name
:
'versionLike'
,
index
:
'version_like'
,
width
:
80
},
{
label
:
'版本更新内容'
,
name
:
'versionDetail'
,
index
:
'version_detail'
,
width
:
80
},
{
label
:
'版本更新内容'
,
name
:
'versionDetail'
,
index
:
'version_detail'
,
width
:
80
},
{
label
:
'版本分类'
,
name
:
'versionSort'
,
index
:
'version_sort'
,
width
:
80
,
formatter
:
sortFormat
}],
{
label
:
'版本分类'
,
name
:
'versionSort'
,
index
:
'version_sort'
,
width
:
80
,
formatter
:
sortFormat
},
shrinkToFit
:
true
,
{
label
:
'是否强制更新'
,
name
:
'status'
,
index
:
'status'
,
width
:
80
,
formatter
:
yesOrNoFormat
},],
datatype
:
"json"
,
shrinkToFit
:
true
,
rowNum
:
15
,
datatype
:
"json"
,
rowList
:[
15
,
30
,
45
],
rowNum
:
15
,
mtype
:
"POST"
,
rowList
:
[
15
,
30
,
45
],
rownumbers
:
true
,
mtype
:
"POST"
,
rownumWidth
:
40
,
rownumbers
:
true
,
gridview
:
true
,
rownumWidth
:
40
,
pager
:
'#speedp'
,
gridview
:
true
,
sortname
:
'version_code'
,
pager
:
'#speedp'
,
viewrecords
:
true
,
sortname
:
'version_code'
,
sortorder
:
"desc"
viewrecords
:
true
,
sortorder
:
"desc"
});
});
});
});
let
vm
=
new
Vue
({
let
vm
=
new
Vue
({
el
:
'#rrapp'
,
el
:
'#rrapp'
,
data
:
{
data
:
{
showList
:
true
,
showList
:
true
,
title
:
null
,
title
:
null
,
tbCfVersion
:
{},
statusList
:
[
ruleValidate
:
{
{
name
:
[
value
:
1
,
{
required
:
true
,
message
:
'名称不能为空'
,
trigger
:
'blur'
}
label
:
'是'
]
},
},
{
q
:
{
value
:
0
,
name
:
''
label
:
'否'
}
}
},
],
methods
:
{
versionList
:
[
query
:
function
()
{
{
vm
.
reload
();
value
:
1
,
},
label
:
'ios'
add
:
function
()
{
},
vm
.
showList
=
false
;
{
vm
.
title
=
"新增"
;
value
:
0
,
vm
.
tbCfVersion
=
{};
label
:
'android'
UE
.
getEditor
(
'Detail'
).
setContent
(
""
);
// 富文本赋值
}
},
],
update
:
function
(
event
)
{
tbCfVersion
:
{},
let
versionId
=
getSelectedRow
(
"#jqGrid"
);
ruleValidate
:
{
if
(
versionId
==
null
)
{
name
:
[
return
;
{
required
:
true
,
message
:
'名称不能为空'
,
trigger
:
'blur'
}
}
]
vm
.
showList
=
false
;
},
q
:
{
name
:
''
}
},
methods
:
{
query
:
function
()
{
vm
.
reload
();
},
add
:
function
()
{
vm
.
showList
=
false
;
vm
.
title
=
"新增"
;
vm
.
tbCfVersion
=
{};
UE
.
getEditor
(
'Detail'
).
setContent
(
""
);
// 富文本赋值
},
update
:
function
(
event
)
{
let
versionId
=
getSelectedRow
(
"#jqGrid"
);
if
(
versionId
==
null
)
{
return
;
}
vm
.
showList
=
false
;
vm
.
title
=
"修改"
;
vm
.
title
=
"修改"
;
vm
.
getInfo
(
versionId
);
vm
.
getInfo
(
versionId
);
},
},
saveOrUpdate
:
function
(
event
)
{
saveOrUpdate
:
function
(
event
)
{
vm
.
tbCfVersion
.
versionDetail
=
encodeURI
(
UE
.
getEditor
(
'Detail'
).
getContent
());
// 富文本取值
vm
.
tbCfVersion
.
versionDetail
=
encodeURI
(
UE
.
getEditor
(
'Detail'
).
getContent
());
// 富文本取值
vm
.
tbCfVersion
.
versionDetail
=
vm
.
tbCfVersion
.
versionDetail
.
replace
(
/ /g
,
" "
);
vm
.
tbCfVersion
.
versionDetail
=
vm
.
tbCfVersion
.
versionDetail
.
replace
(
/ /g
,
" "
);
let
url
=
vm
.
tbCfVersion
.
versionId
==
null
?
"../tbcfversion/save"
:
"../tbcfversion/update"
;
let
url
=
vm
.
tbCfVersion
.
versionId
==
null
?
"../tbcfversion/save"
:
"../tbcfversion/update"
;
Ajax
.
request
({
Ajax
.
request
({
url
:
url
,
url
:
url
,
params
:
JSON
.
stringify
(
vm
.
tbCfVersion
),
params
:
JSON
.
stringify
(
vm
.
tbCfVersion
),
type
:
"POST"
,
type
:
"POST"
,
contentType
:
"application/json"
,
contentType
:
"application/json"
,
successCallback
:
function
(
r
)
{
successCallback
:
function
(
r
)
{
alert
(
'操作成功'
,
function
(
index
)
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
vm
.
reload
();
});
});
}
}
});
});
},
},
del
:
function
(
event
)
{
del
:
function
(
event
)
{
let
versionIds
=
getSelectedRows
(
"#jqGrid"
);
let
versionIds
=
getSelectedRows
(
"#jqGrid"
);
if
(
versionIds
==
null
)
{
if
(
versionIds
==
null
)
{
return
;
return
;
}
}
confirm
(
'确定要删除选中的记录?'
,
function
()
{
confirm
(
'确定要删除选中的记录?'
,
function
()
{
Ajax
.
request
({
Ajax
.
request
({
url
:
"../tbcfversion/delete"
,
url
:
"../tbcfversion/delete"
,
params
:
JSON
.
stringify
(
versionIds
),
params
:
JSON
.
stringify
(
versionIds
),
type
:
"POST"
,
type
:
"POST"
,
contentType
:
"application/json"
,
contentType
:
"application/json"
,
successCallback
:
function
()
{
successCallback
:
function
()
{
alert
(
'操作成功'
,
function
(
index
)
{
alert
(
'操作成功'
,
function
(
index
)
{
vm
.
reload
();
vm
.
reload
();
});
});
}
}
});
});
});
});
},
},
getInfo
:
function
(
versionId
)
{
getInfo
:
function
(
versionId
)
{
Ajax
.
request
({
Ajax
.
request
({
url
:
"../tbcfversion/info/"
+
versionId
,
url
:
"../tbcfversion/info/"
+
versionId
,
async
:
false
,
async
:
false
,
successCallback
:
function
(
r
)
{
successCallback
:
function
(
r
)
{
vm
.
tbCfVersion
=
r
.
tbCfVersion
;
vm
.
tbCfVersion
=
r
.
tbCfVersion
;
UE
.
getEditor
(
'Detail'
).
setContent
(
vm
.
tbCfVersion
.
versionDetail
);
// 富文本赋值
UE
.
getEditor
(
'Detail'
).
setContent
(
vm
.
tbCfVersion
.
versionDetail
);
// 富文本赋值
console
.
log
(
vm
.
tbCfVersion
);
console
.
log
(
vm
.
tbCfVersion
);
}
}
});
});
},
},
reload
:
function
(
event
)
{
reload
:
function
(
event
)
{
vm
.
showList
=
true
;
vm
.
showList
=
true
;
let
page
=
$
(
"#jqGrid"
).
jqGrid
(
'getGridParam'
,
'page'
);
let
page
=
$
(
"#jqGrid"
).
jqGrid
(
'getGridParam'
,
'page'
);
$
(
"#jqGrid"
).
jqGrid
(
'setGridParam'
,
{
$
(
"#jqGrid"
).
jqGrid
(
'setGridParam'
,
{
postData
:
{
'name'
:
vm
.
q
.
name
},
postData
:
{
'name'
:
vm
.
q
.
name
},
page
:
page
page
:
page
}).
trigger
(
"reloadGrid"
);
}).
trigger
(
"reloadGrid"
);
vm
.
handleReset
(
'formValidate'
);
vm
.
handleReset
(
'formValidate'
);
},
},
reloadSearch
:
function
()
{
reloadSearch
:
function
()
{
vm
.
q
=
{
vm
.
q
=
{
name
:
''
name
:
''
};
};
...
@@ -128,5 +151,5 @@ let vm = new Vue({
...
@@ -128,5 +151,5 @@ let vm = new Vue({
handleReset
:
function
(
name
)
{
handleReset
:
function
(
name
)
{
handleResetForm
(
this
,
name
);
handleResetForm
(
this
,
name
);
}
}
}
}
});
});
\ No newline at end of file
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论