Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
C
chinafrica
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
zhengfg
chinafrica
Commits
ffe92945
提交
ffe92945
authored
6月 04, 2020
作者:
潘鹏
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
添加商品copy功能
上级
1b000ef2
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
86 行增加
和
18 行删除
+86
-18
tbcfstationitem.html
...min/src/main/webapp/WEB-INF/page/sys/tbcfstationitem.html
+30
-5
tbcfstationitem.js
platform-admin/src/main/webapp/js/sys/tbcfstationitem.js
+56
-13
没有找到文件。
platform-admin/src/main/webapp/WEB-INF/page/sys/tbcfstationitem.html
浏览文件 @
ffe92945
...
...
@@ -537,14 +537,19 @@
</div>
<Card
v-show=
"!showList"
>
<div
class=
"flot-button"
>
<i-button
class=
"fixed-submit preview"
v-show=
"tbCfStationItem.itemId"
@
click=
"preview(tbCfStationItem.itemId,'pc')"
type=
"primary"
>
PC预览
<i-button
class=
"fixed-submit preview"
@
click=
"copy()"
type=
"success"
>
复制
</i-button>
<i-button
class=
"fixed-submit preview"
v-show=
"show_paste_btn"
@
click=
"paste()"
>
粘贴
</i-button>
<i-button
class=
"fixed-submit preview"
v-show=
"tbCfStationItem.itemId"
@
click=
"preview(tbCfStationItem.itemId,'
m')"
type=
"primary"
>
Mobile
预览
@
click=
"preview(tbCfStationItem.itemId,'
pc')"
type=
"primary"
>
预览
</i-button>
<i-button
class=
"fixed-submit"
type=
"primary"
@
click=
"handleSubmit('formValidate')"
>
提交
</i-button>
<i-button
class=
"fixed-back"
type=
"
primary
"
@
click=
"back()"
/>
<i-button
class=
"fixed-back"
type=
"
warning
"
@
click=
"back()"
/>
返回
</i-button>
</div>
<p
slot=
"title"
>
{{title}}
</p>
...
...
@@ -935,7 +940,21 @@
@
on-ok=
"delAttr"
>
<p>
确认删除此属性
</p>
</Modal>
<!-- 粘贴提示-->
<Modal
v-model=
"paste_modal"
title=
"确认粘贴?"
@
on-ok=
"comfirmPaste()"
>
<h4>
粘贴内容如下:
</h4>
<br/>
<p>
1.搜索关键词。
</p>
<p>
2.标签。
</p>
<p>
3.供应商。
</p>
<p>
4.商品分类。
</p>
<p>
5.商品参数。
</p>
<i>
PS:如需增加可粘贴内容请与开发团队联系。
</i>
</Modal>
<br/>
<br/>
...
...
@@ -950,6 +969,12 @@
<i-button
type=
"ghost"
@
click=
"handleReset('formValidate')"
style=
"margin-left: 8px"
>
重置
</i-button>
</Form-item>
</i-form>
<!-- 退出警告 -->
<Modal
v-model=
"showQuitHint"
@
on-ok=
"quit"
>
<p>
还未保存,是否退出?
</p>
</Modal>
</Card>
<script
src=
"${rc.contextPath}/js/plugins/Sortable.min.js"
></script>
<script
src=
"${rc.contextPath}/statics/libs/iview.js"
></script>
...
...
platform-admin/src/main/webapp/js/sys/tbcfstationitem.js
浏览文件 @
ffe92945
...
...
@@ -94,7 +94,10 @@ let vm = new Vue({
batchCount
:
0
,
//2020年5月20日 商品参数
paramster
:
[]
paramster
:
[],
show_paste_btn
:
false
,
// 粘贴按钮
paste_modal
:
false
,
showQuitHint
:
false
,
},
methods
:
{
//预览
...
...
@@ -239,7 +242,7 @@ let vm = new Vue({
this
.
showAttributeImg
=
Bool
;
},
//获取二级分类
changeGoodstype
()
{
changeGoodstype
(
e
)
{
let
url
=
"../tbcfstationitem/queryByItemType?typeId="
+
this
.
tbCfStationItem
.
itemCategory
;
// console.log('url',url)
let
that
=
this
;
...
...
@@ -250,6 +253,7 @@ let vm = new Vue({
successCallback
:
function
(
r
)
{
if
(
r
.
code
===
0
)
{
that
.
Goodstype2
=
r
.
list
e
?
setTimeout
(()
=>
{
that
.
changeGoodstype2
()},
0
):
void
(
0
);
if
(
r
.
list
.
length
===
0
)
{
that
.
tbCfStationItem
.
itemCategorytwo
=
null
}
...
...
@@ -278,6 +282,7 @@ let vm = new Vue({
vm
.
reload
();
},
add
:
function
()
{
window
.
sessionStorage
.
getItem
(
'_copy_product_info'
)
?
this
.
show_paste_btn
=
true
:
void
(
0
);
this
.
AttributeImgArr
.
length
=
0
;
this
.
paramster
.
length
=
0
;
this
.
paramster
.
push
(
...
...
@@ -304,6 +309,7 @@ let vm = new Vue({
UE
.
getEditor
(
'itemDesc'
).
setContent
(
""
);
},
update
:
function
(
event
)
{
window
.
sessionStorage
.
getItem
(
'_copy_product_info'
)
?
this
.
show_paste_btn
=
true
:
void
(
0
);
this
.
disabledChangeAttribute
=
true
;
this
.
prevItem
=
[];
let
itemId
=
getSelectedRow
(
"#jqGrid"
);
...
...
@@ -502,16 +508,7 @@ let vm = new Vue({
},
back
()
{
//清除未保存商品的图片
if
(
!
vm
.
tbCfStationItem
.
itemId
)
{
this
.
AttributeImgArr
.
map
((
item
,
index
)
=>
{
this
.
delAttributeImg
(
item
.
img_path
,
true
);
})
setTimeout
(()
=>
{
this
.
AttributeImgArr
=
[];
},
0
)
}
this
.
reload
();
this
.
showQuitHint
=
true
;
},
reload
:
function
(
event
)
{
this
.
prevItem
=
[]
...
...
@@ -659,7 +656,6 @@ let vm = new Vue({
/* 添加属性 */
addAttr
()
{
console
.
log
(
999
)
if
(
this
.
attrItem
.
length
>
2
)
{
this
.
$Message
.
info
(
'最多添加三种属性'
);
}
else
{
...
...
@@ -858,6 +854,53 @@ let vm = new Vue({
}
})
this
.
paramster
=
arr
;
},
//复制
copy
(){
window
.
sessionStorage
.
setItem
(
'_copy_product_info'
,
JSON
.
stringify
({
search_keyword
:
this
.
tbCfStationItem
.
itemTags
,
tags
:
this
.
isSelectedArr
,
spe
:
this
.
tbCfStationItem
.
supplier
,
catagory
:{
level_one
:
this
.
tbCfStationItem
.
itemCategory
,
level_two
:
this
.
tbCfStationItem
.
itemCategorytwo
,
level_three
:
this
.
tbCfStationItem
.
itemDescritionId
,
},
product_paramster
:
this
.
paramster
})
)
this
.
$Message
.
success
(
'复制成功 0.0'
);
},
paste
(){
this
.
paste_modal
=
true
;
},
comfirmPaste
(){
this
.
paste_modal
=
false
;
this
.
$Message
.
success
(
'粘贴成功 0.0'
);
let
_paste_data
=
null
;
_paste_data
=
JSON
.
parse
(
window
.
sessionStorage
.
getItem
(
'_copy_product_info'
));
this
.
tbCfStationItem
.
itemTags
=
_paste_data
.
search_keyword
;
this
.
isSelectedAr
=
_paste_data
.
tags
;
this
.
tbCfStationItem
.
supplier
=
_paste_data
.
spe
;
this
.
tbCfStationItem
.
itemCategory
=
_paste_data
.
catagory
.
level_one
||
null
;
this
.
changeGoodstype
(
true
);
this
.
tbCfStationItem
.
itemCategorytwo
=
_paste_data
.
catagory
.
level_two
||
null
;
this
.
tbCfStationItem
.
itemDescritionId
=
_paste_data
.
catagory
.
level_three
||
null
;
this
.
paramster
=
_paste_data
.
product_paramster
;
},
quit
(){
//清除未保存商品的图片
if
(
!
vm
.
tbCfStationItem
.
itemId
)
{
this
.
AttributeImgArr
.
map
((
item
,
index
)
=>
{
this
.
delAttributeImg
(
item
.
img_path
,
true
);
})
setTimeout
(()
=>
{
this
.
AttributeImgArr
=
[];
},
0
)
}
this
.
reload
();
}
},
created
()
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论