Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
ElectricitySheep
Project
Project
Details
Activity
Releases
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
黄媛媛
ElectricitySheep
Commits
f6e3cd02
Commit
f6e3cd02
authored
May 13, 2020
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
8efaa50d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
116 additions
and
57 deletions
+116
-57
templateEdit.vue
src/components/sallCenter/templateEdit.vue
+37
-4
templateManage.vue
src/components/sallCenter/templateManage.vue
+79
-53
No files found.
src/components/sallCenter/templateEdit.vue
View file @
f6e3cd02
...
...
@@ -171,7 +171,7 @@
<div
class=
"all-components"
>
<el-form
label-width=
"80px"
>
<el-form-item
label=
"模板名称"
>
<el-input
type=
"text"
size=
"small"
></el-input>
<el-input
type=
"text"
size=
"small"
v-model=
"addMsg.TemplateName"
></el-input>
</el-form-item>
<el-form-item
label=
"背景设置"
>
<el-button
size=
"small"
>
设置
</el-button>
...
...
@@ -269,7 +269,7 @@
</div>
</div>
<div
class=
"tpEdit_btmMenu"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"
getAll
Data()"
>
保存
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"
Save
Data()"
>
保存
</el-button>
</div>
</div>
</
template
>
...
...
@@ -306,6 +306,13 @@
export
default
{
data
()
{
return
{
addMsg
:
{
Id
:
0
,
//编号
TemplateName
:
''
,
//模板名称
TemplateData
:
''
,
ComponentDataList
:[],
},
allComponents
:
[],
dataList
:
[],
//是否为空
...
...
@@ -1081,11 +1088,37 @@
item
.
isCked
=
true
;
},
//点击保存
getAllData
()
{
console
.
log
(
this
.
dataList
,
'dataListtt'
);
SaveData
()
{
this
.
addMsg
.
ComponentDataList
=
this
.
dataList
;
console
.
log
(
"addMsg"
,
this
.
addMsg
);
this
.
apipost
(
"/api/Template/SetMiniTemplate"
,
this
.
addMsg
,
res
=>
{
console
.
log
(
res
.
data
)
if
(
res
.
data
.
resultCode
==
1
)
{
}
else
{
this
.
Info
(
res
.
data
.
message
);
}
})
},
GetData
()
{
this
.
apipost
(
"/api/Template/SetMiniTemplate"
,
{
Id
:
this
.
addMsg
.
Id
},
res
=>
{
console
.
log
(
res
.
data
)
if
(
res
.
data
.
resultCode
==
1
)
{}
else
{
this
.
Info
(
res
.
data
.
message
);
}
})
}
},
mounted
()
{
if
(
this
.
$route
.
query
.
Id
)
{
this
.
addMsg
.
Id
=
this
.
$route
.
query
.
Id
;
}
if
(
this
.
addMsg
.
Id
>
0
)
{
this
.
GetData
();
}
this
.
GetPlugInList
();
}
};
...
...
src/components/sallCenter/templateManage.vue
View file @
f6e3cd02
<
style
>
.templateManage
.template_comheader
{
padding
:
13px
20px
;
border-bottom
:
1px
solid
#EBEEF5
;
-webkit-box-sizing
:
border-box
;
box-sizing
:
border-box
;
background
:
#fff
;
}
.templateManage
.template_comheader
>
div
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
flex-direction
:
row
;
}
.templateManage
.temp_content
{
margin-top
:
10px
;
background
:
#fff
;
padding
:
20px
;
}
.templateManage
.temp_imgStyle
{
display
:
inline-block
;
margin-right
:
10px
;
}
.templateManage
.template_comheader
{
padding
:
13px
20px
;
border-bottom
:
1px
solid
#EBEEF5
;
-webkit-box-sizing
:
border-box
;
box-sizing
:
border-box
;
background
:
#fff
;
}
.templateManage
.template_comheader
>
div
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
flex-direction
:
row
;
}
.templateManage
.temp_content
{
margin-top
:
10px
;
background
:
#fff
;
padding
:
20px
;
}
.templateManage
.temp_imgStyle
{
display
:
inline-block
;
margin-right
:
10px
;
}
</
style
>
<
template
>
<div
class=
"templateManage"
>
<div
class=
"template_comheader"
>
<div>
<span>
模板管理
</span>
<el-button
type=
"primary"
size=
"small"
@
click=
"CommonJump('templateEdit')"
>
添加模板
</el-button>
</div>
</div>
<div
class=
"temp_content"
>
<el-table
:data=
"tableData"
border
style=
"width: 100%"
>
<el-table-column
prop=
"ID"
label=
"ID"
></el-table-column>
<el-table-column
prop=
"name"
label=
"模板名称"
></el-table-column>
<el-table-column
prop=
"date"
label=
"创建时间"
></el-table-column>
<el-table-column
label=
"操作"
>
<template
slot-scope=
"scope"
>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"编辑"
placement=
"top"
>
<img
src=
"../../assets/img/setup/edit.png"
alt=
""
class=
"temp_imgStyle"
@
click=
"edit(scope.row)"
>
</el-tooltip>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"删除"
placement=
"top"
>
<img
src=
"../../assets/img/setup/del.png"
alt=
""
class=
"temp_imgStyle"
@
click=
"delRow(scope.row)"
>
</el-tooltip>
</
template
>
</el-table-column>
</el-table>
</div>
<div
class=
"templateManage"
>
<div
class=
"template_comheader"
>
<div>
<span>
模板管理
</span>
<el-button
type=
"primary"
size=
"small"
@
click=
"CommonJump('templateEdit',
{Id:0})">添加模板
</el-button>
</div>
</div>
<div
class=
"temp_content"
>
<el-table
:data=
"dataList"
border
style=
"width: 100%"
>
<el-table-column
prop=
"Id"
label=
"编号"
></el-table-column>
<el-table-column
prop=
"TemplateName"
label=
"模板名称"
></el-table-column>
<el-table-column
prop=
"CreateDateStr"
label=
"创建时间"
></el-table-column>
<el-table-column
label=
"操作"
>
<template
slot-scope=
"scope"
>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"编辑"
placement=
"top"
>
<img
src=
"../../assets/img/setup/edit.png"
alt=
""
class=
"temp_imgStyle"
@
click=
"EditeTemplate(scope.row)"
>
</el-tooltip>
<el-tooltip
class=
"item"
effect=
"dark"
content=
"删除"
placement=
"top"
>
<img
src=
"../../assets/img/setup/del.png"
alt=
""
class=
"temp_imgStyle"
@
click=
"DeleteTemplate(scope.row)"
>
</el-tooltip>
</
template
>
</el-table-column>
</el-table>
</div>
</div>
</template>
<
script
>
export
default
{
data
()
{
return
{
tableData
:
[{
ID
:
'3542'
,
name
:
'微途测试'
,
date
:
'2020-04-27 19:20:08'
,
}]
dataList
:
[],
qMsg
:
{
pageIndex
:
1
,
pageSize
:
20
,
},
total
:
0
};
},
created
()
{
},
methods
:
{
getList
()
{
this
.
apipost
(
"/api/Template/GetMiniTemplatePageList"
,
this
.
qMsg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
dataList
=
res
.
data
.
data
.
pageData
;
this
.
total
=
res
.
data
.
data
.
count
;
console
.
log
(
this
.
dataList
,
'datalist'
);
}
else
{
this
.
Info
(
res
.
data
.
message
);
}
})
},
//修改模板
EditeTemplate
(
item
)
{
this
.
CommonJump
(
'templateEdit'
,
{
Id
:
item
.
Id
});
},
//删除模板
DeleteTemplate
(
item
)
{
}
},
mounted
()
{
this
.
getList
();
}
};
...
...
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