图标替换

yanzili 3 years ago
parent e2657e7bea
commit e068f409b6

@ -2,8 +2,9 @@
<html> <html>
<head> <head>
<meta charset="utf-8"/> <meta charset="utf-8"/>
<title>IconFont Demo</title> <title>iconfont Demo</title>
<link rel="shortcut icon" href="https://img.alicdn.com/tps/i4/TB1_oz6GVXXXXaFXpXXJDFnIXXX-64-64.ico" type="image/x-icon"/> <link rel="shortcut icon" href="//img.alicdn.com/imgextra/i2/O1CN01ZyAlrn1MwaMhqz36G_!!6000000001499-73-tps-64-64.ico" type="image/x-icon"/>
<link rel="icon" type="image/svg+xml" href="//img.alicdn.com/imgextra/i4/O1CN01EYTRnJ297D6vehehJ_!!6000000008020-55-tps-64-64.svg"/>
<link rel="stylesheet" href="https://g.alicdn.com/thx/cube/1.3.2/cube.min.css"> <link rel="stylesheet" href="https://g.alicdn.com/thx/cube/1.3.2/cube.min.css">
<link rel="stylesheet" href="demo.css"> <link rel="stylesheet" href="demo.css">
<link rel="stylesheet" href="iconfont.css"> <link rel="stylesheet" href="iconfont.css">
@ -12,10 +13,33 @@
<script src="https://a1.alicdn.com/oss/uploads/2018/12/26/7bfddb60-08e8-11e9-9b04-53e73bb6408b.js"></script> <script src="https://a1.alicdn.com/oss/uploads/2018/12/26/7bfddb60-08e8-11e9-9b04-53e73bb6408b.js"></script>
<!-- 代码高亮 --> <!-- 代码高亮 -->
<script src="https://a1.alicdn.com/oss/uploads/2018/12/26/a3f714d0-08e6-11e9-8a15-ebf944d7534c.js"></script> <script src="https://a1.alicdn.com/oss/uploads/2018/12/26/a3f714d0-08e6-11e9-8a15-ebf944d7534c.js"></script>
<style>
.main .logo {
margin-top: 0;
height: auto;
}
.main .logo a {
display: flex;
align-items: center;
}
.main .logo .sub-title {
margin-left: 0.5em;
font-size: 22px;
color: #fff;
background: linear-gradient(-45deg, #3967FF, #B500FE);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
</style>
</head> </head>
<body> <body>
<div class="main"> <div class="main">
<h1 class="logo"><a href="https://www.iconfont.cn/" title="iconfont 首页" target="_blank">&#xe86b;</a></h1> <h1 class="logo"><a href="https://www.iconfont.cn/" title="iconfont 首页" target="_blank">
<img width="200" src="https://img.alicdn.com/imgextra/i3/O1CN01Mn65HV1FfSEzR6DKv_!!6000000000514-55-tps-228-59.svg">
</a></h1>
<div class="nav-tabs"> <div class="nav-tabs">
<ul id="tabs" class="dib-box"> <ul id="tabs" class="dib-box">
<li class="dib active"><span>Unicode</span></li> <li class="dib active"><span>Unicode</span></li>
@ -30,6 +54,138 @@
<div class="content unicode" style="display: block;"> <div class="content unicode" style="display: block;">
<ul class="icon_lists dib-box"> <ul class="icon_lists dib-box">
<li class="dib">
<span class="icon iconfont">&#xe650;</span>
<div class="name">excel</div>
<div class="code-name">&amp;#xe650;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe737;</span>
<div class="name">保存</div>
<div class="code-name">&amp;#xe737;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe6c5;</span>
<div class="name">关 闭</div>
<div class="code-name">&amp;#xe6c5;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe614;</span>
<div class="name">pdf</div>
<div class="code-name">&amp;#xe614;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe61e;</span>
<div class="name">复制</div>
<div class="code-name">&amp;#xe61e;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe78c;</span>
<div class="name">020空心饼图</div>
<div class="code-name">&amp;#xe78c;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe662;</span>
<div class="name">时间</div>
<div class="code-name">&amp;#xe662;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe6f6;</span>
<div class="name">保存</div>
<div class="code-name">&amp;#xe6f6;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe612;</span>
<div class="name">图片</div>
<div class="code-name">&amp;#xe612;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe691;</span>
<div class="name">柱状图</div>
<div class="code-name">&amp;#xe691;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe65f;</span>
<div class="name">超链接</div>
<div class="code-name">&amp;#xe65f;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe605;</span>
<div class="name">文本</div>
<div class="code-name">&amp;#xe605;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xecc1;</span>
<div class="name">视频</div>
<div class="code-name">&amp;#xecc1;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe66a;</span>
<div class="name">框架</div>
<div class="code-name">&amp;#xe66a;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe728;</span>
<div class="name">预览</div>
<div class="code-name">&amp;#xe728;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe601;</span>
<div class="name">横向文字</div>
<div class="code-name">&amp;#xe601;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe602;</span>
<div class="name">图表 _饼图</div>
<div class="code-name">&amp;#xe602;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe6d5;</span>
<div class="name">漏斗图</div>
<div class="code-name">&amp;#xe6d5;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe630;</span>
<div class="name">图表 折线图</div>
<div class="code-name">&amp;#xe630;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe607;</span>
<div class="name">柱线图</div>
<div class="code-name">&amp;#xe607;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe81d;</span>
<div class="name">图片</div>
<div class="code-name">&amp;#xe81d;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe706;</span>
<div class="name">仪表盘</div>
<div class="code-name">&amp;#xe706;</div>
</li>
<li class="dib"> <li class="dib">
<span class="icon iconfont">&#xe63b;</span> <span class="icon iconfont">&#xe63b;</span>
<div class="name">返回</div> <div class="name">返回</div>
@ -493,24 +649,20 @@
<p>Unicode 是字体在网页端最原始的应用方式,特点是:</p> <p>Unicode 是字体在网页端最原始的应用方式,特点是:</p>
<ul> <ul>
<li>兼容性最好,支持 IE6+,及所有现代浏览器。</li>
<li>支持按字体的方式去动态调整图标大小,颜色等等。</li> <li>支持按字体的方式去动态调整图标大小,颜色等等。</li>
<li>但是因为是字体,所以不支持多色。只能使用平台里单色的图标,就算项目里有多色图标也会自动去色。</li> <li>默认情况下不支持多色,直接添加多色图标会自动去色。</li>
</ul> </ul>
<blockquote> <blockquote>
<p>注意:新版 iconfont 支持多色图标,这些多色图标在 Unicode 模式下将不能使用如果有需求建议使用symbol 的引用方式</p> <p>注意:新版 iconfont 支持两种方式引用多色图标SVG symbol 引用方式和彩色字体图标模式。(使用彩色字体图标需要在「编辑项目」中开启「彩色」选项后并重新生成。)</p>
</blockquote> </blockquote>
<p>Unicode 使用步骤如下:</p> <p>Unicode 使用步骤如下:</p>
<h3 id="-font-face">第一步:拷贝项目下面生成的 <code>@font-face</code></h3> <h3 id="-font-face">第一步:拷贝项目下面生成的 <code>@font-face</code></h3>
<pre><code class="language-css" <pre><code class="language-css"
>@font-face { >@font-face {
font-family: 'iconfont'; font-family: 'iconfont';
src: url('iconfont.eot'); src: url('iconfont.woff2?t=1624608582557') format('woff2'),
src: url('iconfont.eot?#iefix') format('embedded-opentype'), url('iconfont.woff?t=1624608582557') format('woff'),
url('iconfont.woff2') format('woff2'), url('iconfont.ttf?t=1624608582557') format('truetype');
url('iconfont.woff') format('woff'),
url('iconfont.ttf') format('truetype'),
url('iconfont.svg#iconfont') format('svg');
} }
</code></pre> </code></pre>
<h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3> <h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3>
@ -536,6 +688,204 @@
<div class="content font-class"> <div class="content font-class">
<ul class="icon_lists dib-box"> <ul class="icon_lists dib-box">
<li class="dib">
<span class="icon iconfont iconexcel"></span>
<div class="name">
excel
</div>
<div class="code-name">.iconexcel
</div>
</li>
<li class="dib">
<span class="icon iconfont iconbaocun"></span>
<div class="name">
保存
</div>
<div class="code-name">.iconbaocun
</div>
</li>
<li class="dib">
<span class="icon iconfont iconguanbi"></span>
<div class="name">
关 闭
</div>
<div class="code-name">.iconguanbi
</div>
</li>
<li class="dib">
<span class="icon iconfont iconpdf"></span>
<div class="name">
pdf
</div>
<div class="code-name">.iconpdf
</div>
</li>
<li class="dib">
<span class="icon iconfont iconfuzhi"></span>
<div class="name">
复制
</div>
<div class="code-name">.iconfuzhi
</div>
</li>
<li class="dib">
<span class="icon iconfont icon020kongxinbingtu"></span>
<div class="name">
020空心饼图
</div>
<div class="code-name">.icon020kongxinbingtu
</div>
</li>
<li class="dib">
<span class="icon iconfont iconshijian"></span>
<div class="name">
时间
</div>
<div class="code-name">.iconshijian
</div>
</li>
<li class="dib">
<span class="icon iconfont iconsave"></span>
<div class="name">
保存
</div>
<div class="code-name">.iconsave
</div>
</li>
<li class="dib">
<span class="icon iconfont icontupian"></span>
<div class="name">
图片
</div>
<div class="code-name">.icontupian
</div>
</li>
<li class="dib">
<span class="icon iconfont iconzhuzhuangtu"></span>
<div class="name">
柱状图
</div>
<div class="code-name">.iconzhuzhuangtu
</div>
</li>
<li class="dib">
<span class="icon iconfont iconchaolianjie"></span>
<div class="name">
超链接
</div>
<div class="code-name">.iconchaolianjie
</div>
</li>
<li class="dib">
<span class="icon iconfont iconziyuan"></span>
<div class="name">
文本
</div>
<div class="code-name">.iconziyuan
</div>
</li>
<li class="dib">
<span class="icon iconfont iconshipin"></span>
<div class="name">
视频
</div>
<div class="code-name">.iconshipin
</div>
</li>
<li class="dib">
<span class="icon iconfont iconkuangjia"></span>
<div class="name">
框架
</div>
<div class="code-name">.iconkuangjia
</div>
</li>
<li class="dib">
<span class="icon iconfont iconyulan"></span>
<div class="name">
预览
</div>
<div class="code-name">.iconyulan
</div>
</li>
<li class="dib">
<span class="icon iconfont iconhengxiangwenzi"></span>
<div class="name">
横向文字
</div>
<div class="code-name">.iconhengxiangwenzi
</div>
</li>
<li class="dib">
<span class="icon iconfont iconicon_tubiao_bingtu"></span>
<div class="name">
图表 _饼图
</div>
<div class="code-name">.iconicon_tubiao_bingtu
</div>
</li>
<li class="dib">
<span class="icon iconfont iconloudoutu"></span>
<div class="name">
漏斗图
</div>
<div class="code-name">.iconloudoutu
</div>
</li>
<li class="dib">
<span class="icon iconfont icontubiaozhexiantu"></span>
<div class="name">
图表 折线图
</div>
<div class="code-name">.icontubiaozhexiantu
</div>
</li>
<li class="dib">
<span class="icon iconfont iconzhuxiantu"></span>
<div class="name">
柱线图
</div>
<div class="code-name">.iconzhuxiantu
</div>
</li>
<li class="dib">
<span class="icon iconfont icontupian1"></span>
<div class="name">
图片
</div>
<div class="code-name">.icontupian1
</div>
</li>
<li class="dib">
<span class="icon iconfont iconyibiaopan"></span>
<div class="name">
仪表盘
</div>
<div class="code-name">.iconyibiaopan
</div>
</li>
<li class="dib"> <li class="dib">
<span class="icon iconfont icon1"></span> <span class="icon iconfont icon1"></span>
<div class="name"> <div class="name">
@ -1228,10 +1578,8 @@
<p>font-class 是 Unicode 使用方式的一种变种,主要是解决 Unicode 书写不直观,语意不明确的问题。</p> <p>font-class 是 Unicode 使用方式的一种变种,主要是解决 Unicode 书写不直观,语意不明确的问题。</p>
<p>与 Unicode 使用方式相比,具有如下特点:</p> <p>与 Unicode 使用方式相比,具有如下特点:</p>
<ul> <ul>
<li>兼容性良好,支持 IE8+,及所有现代浏览器。</li>
<li>相比于 Unicode 语意明确,书写更直观。可以很容易分辨这个 icon 是什么。</li> <li>相比于 Unicode 语意明确,书写更直观。可以很容易分辨这个 icon 是什么。</li>
<li>因为使用 class 来定义图标,所以当要替换图标时,只需要修改 class 里面的 Unicode 引用。</li> <li>因为使用 class 来定义图标,所以当要替换图标时,只需要修改 class 里面的 Unicode 引用。</li>
<li>不过因为本质上还是使用的字体,所以多色图标还是不支持的。</li>
</ul> </ul>
<p>使用步骤如下:</p> <p>使用步骤如下:</p>
<h3 id="-fontclass-">第一步:引入项目下面生成的 fontclass 代码:</h3> <h3 id="-fontclass-">第一步:引入项目下面生成的 fontclass 代码:</h3>
@ -1249,6 +1597,182 @@
<div class="content symbol"> <div class="content symbol">
<ul class="icon_lists dib-box"> <ul class="icon_lists dib-box">
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconexcel"></use>
</svg>
<div class="name">excel</div>
<div class="code-name">#iconexcel</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconbaocun"></use>
</svg>
<div class="name">保存</div>
<div class="code-name">#iconbaocun</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconguanbi"></use>
</svg>
<div class="name">关 闭</div>
<div class="code-name">#iconguanbi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconpdf"></use>
</svg>
<div class="name">pdf</div>
<div class="code-name">#iconpdf</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconfuzhi"></use>
</svg>
<div class="name">复制</div>
<div class="code-name">#iconfuzhi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon020kongxinbingtu"></use>
</svg>
<div class="name">020空心饼图</div>
<div class="code-name">#icon020kongxinbingtu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconshijian"></use>
</svg>
<div class="name">时间</div>
<div class="code-name">#iconshijian</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconsave"></use>
</svg>
<div class="name">保存</div>
<div class="code-name">#iconsave</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icontupian"></use>
</svg>
<div class="name">图片</div>
<div class="code-name">#icontupian</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconzhuzhuangtu"></use>
</svg>
<div class="name">柱状图</div>
<div class="code-name">#iconzhuzhuangtu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconchaolianjie"></use>
</svg>
<div class="name">超链接</div>
<div class="code-name">#iconchaolianjie</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconziyuan"></use>
</svg>
<div class="name">文本</div>
<div class="code-name">#iconziyuan</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconshipin"></use>
</svg>
<div class="name">视频</div>
<div class="code-name">#iconshipin</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconkuangjia"></use>
</svg>
<div class="name">框架</div>
<div class="code-name">#iconkuangjia</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconyulan"></use>
</svg>
<div class="name">预览</div>
<div class="code-name">#iconyulan</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconhengxiangwenzi"></use>
</svg>
<div class="name">横向文字</div>
<div class="code-name">#iconhengxiangwenzi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconicon_tubiao_bingtu"></use>
</svg>
<div class="name">图表 _饼图</div>
<div class="code-name">#iconicon_tubiao_bingtu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconloudoutu"></use>
</svg>
<div class="name">漏斗图</div>
<div class="code-name">#iconloudoutu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icontubiaozhexiantu"></use>
</svg>
<div class="name">图表 折线图</div>
<div class="code-name">#icontubiaozhexiantu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconzhuxiantu"></use>
</svg>
<div class="name">柱线图</div>
<div class="code-name">#iconzhuxiantu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icontupian1"></use>
</svg>
<div class="name">图片</div>
<div class="code-name">#icontupian1</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#iconyibiaopan"></use>
</svg>
<div class="name">仪表盘</div>
<div class="code-name">#iconyibiaopan</div>
</li>
<li class="dib"> <li class="dib">
<svg class="icon svg-icon" aria-hidden="true"> <svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon1"></use> <use xlink:href="#icon1"></use>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -5,6 +5,160 @@
"css_prefix_text": "icon", "css_prefix_text": "icon",
"description": "", "description": "",
"glyphs": [ "glyphs": [
{
"icon_id": "1990758",
"name": "excel",
"font_class": "excel",
"unicode": "e650",
"unicode_decimal": 58960
},
{
"icon_id": "9445573",
"name": "保存",
"font_class": "baocun",
"unicode": "e737",
"unicode_decimal": 59191
},
{
"icon_id": "11920154",
"name": "关 闭",
"font_class": "guanbi",
"unicode": "e6c5",
"unicode_decimal": 59077
},
{
"icon_id": "16968592",
"name": "pdf",
"font_class": "pdf",
"unicode": "e614",
"unicode_decimal": 58900
},
{
"icon_id": "21538118",
"name": "复制",
"font_class": "fuzhi",
"unicode": "e61e",
"unicode_decimal": 58910
},
{
"icon_id": "1066041",
"name": "020空心饼图",
"font_class": "020kongxinbingtu",
"unicode": "e78c",
"unicode_decimal": 59276
},
{
"icon_id": "2032219",
"name": "时间",
"font_class": "shijian",
"unicode": "e662",
"unicode_decimal": 58978
},
{
"icon_id": "2721664",
"name": "保存",
"font_class": "save",
"unicode": "e6f6",
"unicode_decimal": 59126
},
{
"icon_id": "4803230",
"name": "图片",
"font_class": "tupian",
"unicode": "e612",
"unicode_decimal": 58898
},
{
"icon_id": "5963559",
"name": "柱状图",
"font_class": "zhuzhuangtu",
"unicode": "e691",
"unicode_decimal": 59025
},
{
"icon_id": "6642296",
"name": "超链接",
"font_class": "chaolianjie",
"unicode": "e65f",
"unicode_decimal": 58975
},
{
"icon_id": "7732218",
"name": "文本",
"font_class": "ziyuan",
"unicode": "e605",
"unicode_decimal": 58885
},
{
"icon_id": "9592086",
"name": "视频",
"font_class": "shipin",
"unicode": "ecc1",
"unicode_decimal": 60609
},
{
"icon_id": "12252496",
"name": "框架",
"font_class": "kuangjia",
"unicode": "e66a",
"unicode_decimal": 58986
},
{
"icon_id": "14717060",
"name": "预览",
"font_class": "yulan",
"unicode": "e728",
"unicode_decimal": 59176
},
{
"icon_id": "14728974",
"name": "横向文字",
"font_class": "hengxiangwenzi",
"unicode": "e601",
"unicode_decimal": 58881
},
{
"icon_id": "15066193",
"name": "图表 _饼图",
"font_class": "icon_tubiao_bingtu",
"unicode": "e602",
"unicode_decimal": 58882
},
{
"icon_id": "17247792",
"name": "漏斗图",
"font_class": "loudoutu",
"unicode": "e6d5",
"unicode_decimal": 59093
},
{
"icon_id": "21925168",
"name": "图表 折线图",
"font_class": "tubiaozhexiantu",
"unicode": "e630",
"unicode_decimal": 58928
},
{
"icon_id": "22117888",
"name": "柱线图",
"font_class": "zhuxiantu",
"unicode": "e607",
"unicode_decimal": 58887
},
{
"icon_id": "22300259",
"name": "图片",
"font_class": "tupian1",
"unicode": "e81d",
"unicode_decimal": 59421
},
{
"icon_id": "22398839",
"name": "仪表盘",
"font_class": "yibiaopan",
"unicode": "e706",
"unicode_decimal": 59142
},
{ {
"icon_id": "18774317", "icon_id": "18774317",
"name": "返回", "name": "返回",

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 859 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 940 B

@ -190,3 +190,94 @@ a:hover {
.el-input-group__append, .el-input-group__prepend{ .el-input-group__append, .el-input-group__prepend{
color: #333; color: #333;
} }
//avue
.preview-form{
height: auto!important;
overflow-y: auto!important;
}
.x-spreadsheet-toolbar-btns{
margin-left: 30px !important;
}
.ml10{
margin-left: 10px;
}
.Customized .CodeMirror {
font-family: monospace;
height: 190px !important;
color: black;
direction: ltr;
}
.jsoneditor-vue{
height: 100%;
}
.printSet {
background-image: url('../images/bianzu.png') !important;
background-size: 19px;
background-position: left top;
background-repeat: no-repeat;
position: absolute;
opacity: 1!important;
}
.qrCodes {
background-image: url('../images/qrcode.png') !important;
background-size: 19px;
background-position: left top;
background-repeat: no-repeat;
position: absolute;
opacity: 1!important;
}
.barCodes {
background-image: url('../images/tiaoxingma.png') !important;
background-size: 19px;
background-position: left top;
background-repeat: no-repeat;
position: absolute;
opacity: 1!important;
}
.collapse-input-style {
.el-input__inner ,.el-textarea__inner{
background: #263445 !important;
border: 1px solid #3f5673;
color:#a8e3ff
}
.el-slider__runway{
height: 2px;
background-color:#5e6b82
}
.el-slider__bar{
height: 2px;
}
.el-slider__button-wrapper{
top: -17px;
}
.el-slider__button{
width: 14px;
height: 14px;
}
.el-switch__core{
background-color:#5e6b82;
border: 1px solid #3f5673;
}
.el-input-group__append, .el-input-group__prepend{
background: #5e6b82 !important;
border: 1px solid #3f5673;
color:#a8e3ff
}
.el-input-number__increase, .el-input-number__decrease{
background: #5e6b82 !important;
border: 1px solid #3f5673;
color:#a8e3ff
}
.el-input-number.is-controls-right .el-input-number__increase{
border-bottom: 1px solid #3f5673;
}
.el-input-number.is-controls-right .el-input-number__decrease{
border-left: 1px solid #3f5673;
}
.el-form-item__label {
font-size: 12px;
color: #bfcbd9!important;
font-weight: normal !important;
}
}

@ -5,9 +5,14 @@
* @Last Modified time: 2021-4-8 11:04:24 * @Last Modified time: 2021-4-8 11:04:24
!--> !-->
<template> <template>
<el-popover placement="right" trigger="click"> <el-popover placement="right"
<Chrome v-model="colors" @input="updateValue" /> trigger="click">
<el-input slot="reference" v-model="colors.hex" placeholder="颜色选择器"> <Chrome v-model="colors"
@input="updateValue" />
<el-input slot="reference"
v-model="colors.hex"
size="mini"
placeholder="颜色选择器">
<template #append><i class="iconfont iconcolorSelector" /></template> <template #append><i class="iconfont iconcolorSelector" /></template>
</el-input> </el-input>
</el-popover> </el-popover>
@ -30,7 +35,7 @@ export default {
default: '', default: '',
}, },
}, },
data() { data () {
return { return {
colors: { colors: {
hex: '', hex: '',
@ -41,15 +46,15 @@ export default {
} }
}, },
watch: { watch: {
value(val) { value (val) {
this.colors.hex = val this.colors.hex = val
} }
}, },
mounted() { mounted () {
this.colors.hex = this.value this.colors.hex = this.value
}, },
methods: { methods: {
updateValue(value) { updateValue (value) {
// this.colors = value // this.colors = value
this.$emit('input', value.hex) this.$emit('input', value.hex)
this.$emit('change', value.hex) this.$emit('change', value.hex)

@ -1,6 +1,11 @@
<template> <template>
<div v-show="visible" class="contentmenu" :style="styleObj"> <div v-show="visible"
<div class="contentmenu__item" @click="deleteLayer"><svg-icon icon-class="guanbi" /> 删除图层</div> class="contentmenu"
:style="styleObj">
<div class="contentmenu__item"
@click="deleteLayer">
<i class="iconfont iconguanbi"></i> 删除图层
</div>
</div> </div>
</template> </template>
<script> <script>
@ -9,11 +14,11 @@ export default {
styleObj: Object, styleObj: Object,
visible: Boolean, visible: Boolean,
}, },
data() { data () {
return {} return {}
}, },
watch: { watch: {
visible(value) { visible (value) {
if (value) { if (value) {
document.body.addEventListener('click', this.closeMenu) document.body.addEventListener('click', this.closeMenu)
} else { } else {
@ -22,10 +27,10 @@ export default {
}, },
}, },
methods: { methods: {
closeMenu() { closeMenu () {
this.$emit('update:visible', false) this.$emit('update:visible', false)
}, },
deleteLayer() { deleteLayer () {
this.$confirm('是否删除所选图层?', '提示', { this.$confirm('是否删除所选图层?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',

@ -1,61 +1,60 @@
<template> <template>
<div> <div>
<el-button type="primary" icon="el-icon-plus" plain @click="handleAddClick" <el-button type="primary"
>新增</el-button icon="el-icon-plus"
> plain
<el-table :data="formData" style="width: 100%"> @click="handleAddClick">新增</el-button>
<el-table-column prop="color" label="颜色" align="center"> <el-table :data="formData"
style="width: 100%">
<el-table-column prop="color"
label="颜色"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<span class="color-box" :style="{ background: scope.row.color }" /> <span class="color-box"
:style="{ background: scope.row.color }" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="位置" align="center"> <el-table-column label="位置"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<span <span class="editor"
class="editor" @click="handleEditorClick(scope.$index, scope.row)">
@click="handleEditorClick(scope.$index, scope.row)"
>
<i class="el-icon-edit" /> 编辑 <i class="el-icon-edit" /> 编辑
</span> </span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center"> <el-table-column label="操作"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<span <span class="editor"
class="editor" @click="handleDeleteClick(scope.$index, scope.row)">
@click="handleDeleteClick(scope.$index, scope.row)"
>
<i class="el-icon-delete" /> 删除 <i class="el-icon-delete" /> 删除
</span> </span>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-dialog <el-dialog title="新增"
title="新增"
:visible.sync="dialogVisible" :visible.sync="dialogVisible"
width="30%" width="30%"
:before-close="handleClose" :before-close="handleClose">
>
<el-form> <el-form>
<el-form-item label="颜色"> <el-form-item label="颜色">
<el-input <el-input v-model="colorValue"
v-model="colorValue"
style="width: 200px" style="width: 200px"
placeholder="请输入颜色" placeholder="请输入颜色">
>
<template slot="append"> <template slot="append">
<el-color-picker <el-color-picker v-model="colorValue"
v-model="colorValue" :predefine="predefineColors" />
:predefine="predefineColors"
/>
</template> </template>
</el-input> </el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
<span slot="footer" class="dialog-footer"> <span slot="footer"
class="dialog-footer">
<el-button @click="dialogVisible = false"> </el-button> <el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="handleSaveClick"> </el-button> <el-button type="primary"
@click="handleSaveClick"> </el-button>
</span> </span>
</el-dialog> </el-dialog>
</div> </div>
@ -70,7 +69,7 @@ export default {
props: { props: {
formData: Array formData: Array
}, },
data() { data () {
return { return {
predefineColors: [ predefineColors: [
"#ff4500", "#ff4500",
@ -87,21 +86,21 @@ export default {
indexEditor: -1 // indexEditor: -1 //
}; };
}, },
mounted() {}, mounted () { },
methods: { methods: {
// //
handleClose() { handleClose () {
this.dialogVisible = false; this.dialogVisible = false;
this.colorValue = ""; this.colorValue = "";
}, },
// //
handleAddClick() { handleAddClick () {
this.colorValue = ""; this.colorValue = "";
this.flag = true; this.flag = true;
this.dialogVisible = true; this.dialogVisible = true;
}, },
// //
handleSaveClick() { handleSaveClick () {
if (this.flag) { if (this.flag) {
// //
const obj = { const obj = {
@ -117,14 +116,14 @@ export default {
this.$emit("input", this.formData); this.$emit("input", this.formData);
}, },
// //
handleEditorClick(index, row) { handleEditorClick (index, row) {
this.flag = false; this.flag = false;
this.colorValue = row.color; this.colorValue = row.color;
this.dialogVisible = true; this.dialogVisible = true;
this.indexEditor = index; this.indexEditor = index;
}, },
// //
handleDeleteClick(index) { handleDeleteClick (index) {
this.formData.splice(index, 1); this.formData.splice(index, 1);
} }
} }

@ -1,18 +1,34 @@
<template> <template>
<div> <div>
<el-form label-width="80px" label-position="left"> <el-form label-width="80px"
label-position="left">
<el-form-item label="数据集"> <el-form-item label="数据集">
<el-select v-model="dataSetValue" clearable placeholder="请选择" @change="selectDataSet"> <el-select v-model="dataSetValue"
<el-option v-for="item in dataSet" :key="item.code" :label="item.setName" :value="item.id" /> clearable
placeholder="请选择"
@change="selectDataSet">
<el-option v-for="item in dataSet"
:key="item.code"
:label="item.setName"
:value="item.id" />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item v-for="(item, index) in userNameList" :key="index" :label="item.paramName"> <el-form-item v-for="(item, index) in userNameList"
:key="index"
:label="item.paramName">
<el-input v-model="item.sampleItem" /> <el-input v-model="item.sampleItem" />
</el-form-item> </el-form-item>
<el-form-item v-for="item in setParamList" :key="item" :label="item"> <el-form-item v-for="item in setParamList"
<Dictionary v-model="params" :dict-key="'CHART_PROPERTIES'" @input="selectParams($event, item)" /> :key="item"
:label="item">
<Dictionary v-model="params"
:dict-key="'CHART_PROPERTIES'"
@input="selectParams($event, item)" />
</el-form-item> </el-form-item>
<el-button style="width: 100%" type="primary" plain @click="saveDataBtn"></el-button> <el-button style="width: 100%"
type="primary"
plain
@click="saveDataBtn">刷新</el-button>
</el-form> </el-form>
</div> </div>
</template> </template>
@ -33,7 +49,7 @@ export default {
chartType: String, chartType: String,
props: ['formData'], props: ['formData'],
}, },
data() { data () {
return { return {
dataSetValue: '', dataSetValue: '',
dataSet: [], // dataSet: [], //
@ -44,7 +60,7 @@ export default {
} }
}, },
computed: { computed: {
setCode() { setCode () {
let code = '' let code = ''
this.dataSet.forEach((el) => { this.dataSet.forEach((el) => {
if (el.id == this.dataSetValue) { if (el.id == this.dataSetValue) {
@ -54,22 +70,22 @@ export default {
return code return code
}, },
}, },
mounted() { mounted () {
this.loadDataSet() this.loadDataSet()
}, },
methods: { methods: {
async loadDataSet() { async loadDataSet () {
const { code, data } = await queryAllDataSet() const { code, data } = await queryAllDataSet()
this.dataSet = data this.dataSet = data
if (code != '200') return if (code != '200') return
}, },
async selectDataSet() { async selectDataSet () {
const { code, data } = await detailBysetId(this.dataSetValue) const { code, data } = await detailBysetId(this.dataSetValue)
this.userNameList = data.dataSetParamDtoList this.userNameList = data.dataSetParamDtoList
this.setParamList = data.setParamList this.setParamList = data.setParamList
if (code != '200') return if (code != '200') return
}, },
async saveDataBtn() { async saveDataBtn () {
const contextData = {} const contextData = {}
for (let i = 0; i < this.userNameList.length; i++) { for (let i = 0; i < this.userNameList.length; i++) {
contextData[this.userNameList[i].paramName] = this.userNameList[i].sampleItem contextData[this.userNameList[i].paramName] = this.userNameList[i].sampleItem
@ -86,11 +102,11 @@ export default {
this.$emit('input', analysisData) this.$emit('input', analysisData)
if (code != '200') return if (code != '200') return
}, },
selectParams(val, key) { selectParams (val, key) {
this.chartProperties[key] = val this.chartProperties[key] = val
}, },
// //
analysisChartsData(data) { analysisChartsData (data) {
// widget-barchart 线widget-linechart 线 widget-barlinechart 线widget-piechart widget-hollow-piechart // widget-barchart 线widget-linechart 线 widget-barlinechart 线widget-piechart widget-hollow-piechart
// widget-funnel widget-gauge // widget-funnel widget-gauge
const chartType = this.chartType const chartType = this.chartType
@ -104,7 +120,7 @@ export default {
} }
}, },
// 线 // 线
barOrLineChartFn(data) { barOrLineChartFn (data) {
const ananysicData = {} const ananysicData = {}
const xAxisList = [] const xAxisList = []
const series = [] const series = []
@ -134,7 +150,7 @@ export default {
}, },
// //
piechartFn(data) { piechartFn (data) {
const ananysicData = [] const ananysicData = []
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
const obj = {} const obj = {}
@ -151,7 +167,7 @@ export default {
// console.log(ananysicData, '') // console.log(ananysicData, '')
return ananysicData return ananysicData
}, },
gaugeFn(data) { gaugeFn (data) {
const ananysicData = [] const ananysicData = []
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
const obj = {} const obj = {}

@ -7,73 +7,182 @@
!--> !-->
<template> <template>
<div class="collapse-input-style"> <div class="collapse-input-style">
<el-form label-width="80px" label-position="left"> <el-form label-width="80px"
label-position="left">
<template v-for="(item, index) in options"> <template v-for="(item, index) in options">
<div v-if="isShowForm(item, '[object Object]')" :key="index"> <div v-if="isShowForm(item, '[object Object]')"
<el-form-item v-if="inputShow[item.name]" :label="item.label" :prop="item.name" :required="item.required"> :key="index">
<el-input-number v-if="item.type == 'el-input-number'" v-model="formData[item.name]" controls-position="right" :placeholder="item.placeholder" @change="changed($event, item.name)" /> <el-form-item v-if="inputShow[item.name]"
:label="item.label"
:prop="item.name"
:required="item.required">
<el-input-number v-if="item.type == 'el-input-number'"
size="mini"
style="width:100%"
v-model="formData[item.name]"
controls-position="right"
:placeholder="item.placeholder"
@change="changed($event, item.name)" />
<el-input v-if="item.type == 'el-input-text'" v-model.trim="formData[item.name]" type="text" placeholder="请输入内容" clearable @change="changed($event, item.name)" /> <el-input v-if="item.type == 'el-input-text'"
v-model.trim="formData[item.name]"
type="text"
size="mini"
placeholder="请输入内容"
clearable
@change="changed($event, item.name)" />
<el-input v-if="item.type == 'el-input-textarea'" v-model.trim="formData[item.name]" type="textarea" rows="2" placeholder="请输入内容" @change="changed($event, item.name)" /> <el-input v-if="item.type == 'el-input-textarea'"
v-model.trim="formData[item.name]"
type="textarea"
size="mini"
rows="2"
placeholder="请输入内容"
@change="changed($event, item.name)" />
<el-switch v-if="item.type == 'el-switch'" v-model="formData[item.name]" placeholder="请输入内容" @change="changed($event, item.name)" /> <el-switch v-if="item.type == 'el-switch'"
v-model="formData[item.name]"
size="mini"
placeholder="请输入内容"
@change="changed($event, item.name)" />
<ColorPicker v-if="item.type == 'vue-color'" v-model="formData[item.name]" @change="(val) => changed(val, item.name)" /> <ColorPicker v-if="item.type == 'vue-color'"
v-model="formData[item.name]"
@change="(val) => changed(val, item.name)" />
<el-upload v-if="item.type == 'el-upload-picture'" action="https://jsonplaceholder.typicode.com/posts/" list-type="picture-card" /> <el-upload v-if="item.type == 'el-upload-picture'"
size="mini"
action="https://jsonplaceholder.typicode.com/posts/"
list-type="picture-card" />
<el-radio-group v-if="item.type == 'el-radio-group'" v-model="formData[item.name]" @change="(val) => changed(val, item.name)"> <el-radio-group v-if="item.type == 'el-radio-group'"
<el-radio v-for="itemChild in item.selectOptions" :key="itemChild.code" :label="itemChild.code">{{ itemChild.name }}</el-radio> v-model="formData[item.name]"
@change="(val) => changed(val, item.name)">
<el-radio v-for="itemChild in item.selectOptions"
:key="itemChild.code"
:label="itemChild.code">{{ itemChild.name }}</el-radio>
</el-radio-group> </el-radio-group>
<el-select v-if="item.type == 'el-select'" v-model="formData[item.name]" clearable placeholder="请选择" @change="(val) => changed(val, item.name)"> <el-select v-if="item.type == 'el-select'"
<el-option v-for="itemChild in item.selectOptions" :key="itemChild.code" :label="itemChild.name" :value="itemChild.code" /> size="mini"
v-model="formData[item.name]"
clearable
placeholder="请选择"
@change="(val) => changed(val, item.name)">
<el-option v-for="itemChild in item.selectOptions"
:key="itemChild.code"
:label="itemChild.name"
:value="itemChild.code" />
</el-select> </el-select>
<el-slider v-if="item.type == 'el-slider'" v-model="formData[item.name]" @change="(val) => changed(val, item.name)" /> <el-slider v-if="item.type == 'el-slider'"
v-model="formData[item.name]"
@change="(val) => changed(val, item.name)" />
<el-button v-if="item.type == 'el-button'" type="primary" plain @click="addStaticData"></el-button> <el-button v-if="item.type == 'el-button'"
type="primary"
plain
@click="addStaticData">编辑</el-button>
<!-- 弹窗 --> <!-- 弹窗 -->
<el-dialog title="代码编辑" :visible.sync="dialogVisibleStaticData" width="50%" :before-close="handleClose"> <el-dialog title="代码编辑"
<codemirror v-model.trim="formData[item.name]" class="code-mirror" :options="optionsJavascript" style="height: 190px" /> :visible.sync="dialogVisibleStaticData"
<span slot="footer" class="dialog-footer"> width="50%"
:before-close="handleClose">
<codemirror v-model.trim="formData[item.name]"
class="code-mirror"
:options="optionsJavascript"
style="height: 190px" />
<span slot="footer"
class="dialog-footer">
<el-button @click="dialogVisibleStaticData = false"> </el-button> <el-button @click="dialogVisibleStaticData = false"> </el-button>
<el-button type="primary" @click="saveData"> </el-button> <el-button type="primary"
@click="saveData"> </el-button>
</span> </span>
</el-dialog> </el-dialog>
</el-form-item> </el-form-item>
<dynamicComponents v-if="item.type == 'dycustComponents' && inputShow[item.name]" v-model="formData[item.name]" :chart-type="item.chartType" /> <dynamicComponents v-if="item.type == 'dycustComponents' && inputShow[item.name]"
v-model="formData[item.name]"
:chart-type="item.chartType" />
</div> </div>
<div v-else-if="isShowForm(item, '[object Array]')" :key="'a-' + index"> <div v-else-if="isShowForm(item, '[object Array]')"
:key="'a-' + index">
<el-collapse accordion> <el-collapse accordion>
<el-collapse-item v-for="(itemChild, indexChild) in item" :key="indexChild" :title="itemChild.name" :name="indexChild"> <el-collapse-item v-for="(itemChild, indexChild) in item"
:key="indexChild"
:title="itemChild.name"
:name="indexChild">
<template v-for="(itemChildList, idx) in itemChild.list"> <template v-for="(itemChildList, idx) in itemChild.list">
<el-form-item :key="idx" :label="itemChildList.label" :prop="itemChildList.name" :required="itemChildList.required"> <el-form-item :key="idx"
<el-input-number v-if="itemChildList.type == 'el-input-number'" v-model="formData[itemChildList.name]" controls-position="right" :placeholder="itemChildList.placeholder" @change="changed($event, itemChildList.name)" /> :label="itemChildList.label"
:prop="itemChildList.name"
:required="itemChildList.required">
<el-input-number v-if="itemChildList.type == 'el-input-number'"
size="mini"
style="width:100%"
v-model="formData[itemChildList.name]"
controls-position="right"
:placeholder="itemChildList.placeholder"
@change="changed($event, itemChildList.name)" />
<el-input v-if="itemChildList.type == 'el-input-text'" v-model.trim="formData[itemChildList.name]" type="text" placeholder="请输入内容" clearable @change="changed($event, itemChildList.name)" /> <el-input v-if="itemChildList.type == 'el-input-text'"
v-model.trim="formData[itemChildList.name]"
type="text"
size="mini"
placeholder="请输入内容"
clearable
@change="changed($event, itemChildList.name)" />
<el-input v-if="itemChildList.type == 'el-input-textarea'" v-model.trim="formData[itemChildList.name]" type="textarea" rows="2" placeholder="请输入内容" @change="changed($event, itemChildList.name)" /> <el-input v-if="itemChildList.type == 'el-input-textarea'"
v-model.trim="formData[itemChildList.name]"
size="mini"
type="textarea"
rows="2"
placeholder="请输入内容"
@change="changed($event, itemChildList.name)" />
<el-switch v-if="itemChildList.type == 'el-switch'" v-model="formData[itemChildList.name]" placeholder="请输入内容" @change="changed($event, itemChildList.name)" /> <el-switch v-if="itemChildList.type == 'el-switch'"
v-model="formData[itemChildList.name]"
placeholder="请输入内容"
size="mini"
@change="changed($event, itemChildList.name)" />
<ColorPicker v-if="itemChildList.type == 'vue-color'" v-model="formData[itemChildList.name]" @change="(val) => changed(val, itemChildList.name)" /> <ColorPicker v-if="itemChildList.type == 'vue-color'"
v-model="formData[itemChildList.name]"
@change="(val) => changed(val, itemChildList.name)" />
<el-upload v-if="itemChildList.type == 'el-upload-picture'" action="https://jsonplaceholder.typicode.com/posts/" list-type="picture-card" /> <el-upload v-if="itemChildList.type == 'el-upload-picture'"
size="mini"
action="https://jsonplaceholder.typicode.com/posts/"
list-type="picture-card" />
<el-radio-group v-if="itemChildList.type == 'el-radio-group'" v-model="formData[itemChildList.name]" @change="(val) => changed(val, itemChildList.name)"> <el-radio-group v-if="itemChildList.type == 'el-radio-group'"
<el-radio v-for="it in itemChildList.selectOptions" :key="it.code" :label="it.code">{{ it.name }}</el-radio> v-model="formData[itemChildList.name]"
@change="(val) => changed(val, itemChildList.name)">
<el-radio v-for="it in itemChildList.selectOptions"
:key="it.code"
:label="it.code">{{ it.name }}</el-radio>
</el-radio-group> </el-radio-group>
<el-select v-if="itemChildList.type == 'el-select'" v-model="formData[itemChildList.name]" clearable placeholder="请选择" @change="(val) => changed(val, itemChildList.name)"> <el-select v-if="itemChildList.type == 'el-select'"
<el-option v-for="it in itemChildList.selectOptions" :key="it.code" :label="it.name" :value="it.code" /> size="mini"
v-model="formData[itemChildList.name]"
clearable
placeholder="请选择"
@change="(val) => changed(val, itemChildList.name)">
<el-option v-for="it in itemChildList.selectOptions"
:key="it.code"
:label="it.name"
:value="it.code" />
</el-select> </el-select>
<el-slider v-if="itemChildList.type == 'el-slider'" v-model="formData[itemChildList.name]" @change="(val) => changed(val, itemChildList.name)" /> <el-slider v-if="itemChildList.type == 'el-slider'"
v-model="formData[itemChildList.name]"
@change="(val) => changed(val, itemChildList.name)" />
</el-form-item> </el-form-item>
<customColorComponents v-if="itemChildList.type == 'customColor'" :key="'b-' + idx" v-model="formData[itemChildList.name]" /> <customColorComponents v-if="itemChildList.type == 'customColor'"
:key="'b-' + idx"
v-model="formData[itemChildList.name]" />
</template> </template>
</el-collapse-item> </el-collapse-item>
</el-collapse> </el-collapse>
@ -111,10 +220,10 @@ export default {
options: Array, options: Array,
value: { value: {
type: [Object], type: [Object],
default: () => {}, default: () => { },
}, },
}, },
data() { data () {
return { return {
formData: {}, formData: {},
inputShow: {}, // inputShow: {}, //
@ -135,28 +244,28 @@ export default {
} }
}, },
watch: { watch: {
value(newValue, oldValue) { value (newValue, oldValue) {
this.formData = newValue || {} this.formData = newValue || {}
}, },
options() { options () {
this.setDefaultValue() this.setDefaultValue()
this.isShowData() this.isShowData()
}, },
formData: { formData: {
handler() { handler () {
this.$emit('onChanged', this.formData) this.$emit('onChanged', this.formData)
}, },
deep: true, deep: true,
}, },
}, },
created() { created () {
this.isShowData() this.isShowData()
this.setDefaultValue() this.setDefaultValue()
}, },
mounted() {}, mounted () { },
methods: { methods: {
// //
changed(val, key) { changed (val, key) {
if (val.extend) { if (val.extend) {
this.$set(this.formData, key, val.value) this.$set(this.formData, key, val.value)
} else { } else {
@ -172,19 +281,19 @@ export default {
} }
} }
}, },
saveData() { saveData () {
this.$emit('onChanged', this.formData) this.$emit('onChanged', this.formData)
this.dialogVisibleStaticData = false this.dialogVisibleStaticData = false
}, },
// //
addStaticData() { addStaticData () {
this.dialogVisibleStaticData = true this.dialogVisibleStaticData = true
}, },
handleClose() { handleClose () {
this.dialogVisibleStaticData = false this.dialogVisibleStaticData = false
}, },
// //
isShowData() { isShowData () {
let currentData = {} let currentData = {}
const data = [] const data = []
for (let i = 0; i < this.options.length; i++) { for (let i = 0; i < this.options.length; i++) {
@ -203,7 +312,7 @@ export default {
}) })
}, },
// //
setDefaultValue() { setDefaultValue () {
if (this.options && this.options.length > 0) { if (this.options && this.options.length > 0) {
for (let i = 0; i < this.options.length; i++) { for (let i = 0; i < this.options.length; i++) {
const obj = this.options[i] const obj = this.options[i]
@ -222,7 +331,7 @@ export default {
} }
}, },
// //
isShowForm(val, type) { isShowForm (val, type) {
return Object.prototype.toString.call(val) == type return Object.prototype.toString.call(val) == type
}, },
}, },
@ -230,6 +339,9 @@ export default {
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
/deep/ .el-form-item {
margin-bottom: 5px;
}
/deep/ .el-form-item__label { /deep/ .el-form-item__label {
font-size: 12px; font-size: 12px;
color: #fff; color: #fff;

@ -6,15 +6,21 @@
!--> !-->
<template> <template>
<div class="layout"> <div class="layout">
<div v-if="toolIsShow" class="layout-left" :style="{ width: widthLeftForTools + 'px' }"> <div v-if="toolIsShow"
<el-tabs type="border-card" :stretch="true"> class="layout-left"
:style="{ width: widthLeftForTools + 'px' }">
<el-tabs type="border-card"
:stretch="true">
<!-- 左侧组件栏--> <!-- 左侧组件栏-->
<el-tab-pane label="工具栏"> <el-tab-pane label="工具栏">
<!-- <el-divider content-position="center">html</el-divider>--> <!-- <el-divider content-position="center">html</el-divider>-->
<draggable v-for="widget in widgetTools" :key="widget.code" @end="(evt) => widgetOnDragged(evt, widget.code)"> <draggable v-for="widget in widgetTools"
:key="widget.code"
@end="(evt) => widgetOnDragged(evt, widget.code)">
<div class="tools-item"> <div class="tools-item">
<span class="tools-item-icon"> <span class="tools-item-icon">
<svg-icon :icon-class="widget.icon" /> <i class="iconfont"
:class="widget.icon"></i>
</span> </span>
<span class="tools-item-text">{{ widget.label }}</span> <span class="tools-item-text">{{ widget.label }}</span>
</div> </div>
@ -22,9 +28,12 @@
</el-tab-pane> </el-tab-pane>
<!-- 左侧图层--> <!-- 左侧图层-->
<el-tab-pane label="图层"> <el-tab-pane label="图层">
<div v-for="(item, index) in layerWidget" :key="index" class="tools-item"> <div v-for="(item, index) in layerWidget"
:key="index"
class="tools-item">
<span class="tools-item-icon"> <span class="tools-item-icon">
<svg-icon :icon-class="item.icon" /> <i class="iconfont"
:class="item.icon"></i>
</span> </span>
<span class="tools-item-text">{{ item.label }}</span> <span class="tools-item-text">{{ item.label }}</span>
</div> </div>
@ -32,47 +41,92 @@
</el-tabs> </el-tabs>
</div> </div>
<div class="layout-left-fold" :style="{ width: widthLeftForToolsHideButton + 'px' }" @click="toolIsShow = !toolIsShow"> <div class="layout-left-fold"
:style="{ width: widthLeftForToolsHideButton + 'px' }"
@click="toolIsShow = !toolIsShow">
<i class="iconfont iconfold" /> <i class="iconfont iconfold" />
</div> </div>
<div class="layout-middle" :style="{ width: middleWidth + 'px', height: middleHeight + 'px' }"> <div class="layout-middle"
:style="{ width: middleWidth + 'px', height: middleHeight + 'px' }">
<div class="top-button"> <div class="top-button">
<span class="btn"> <span class="btn">
<el-tooltip class="item" effect="dark" content="保存" placement="bottom"> <el-tooltip class="item"
<svg-icon icon-class="report" @click="saveData" /> effect="dark"
content="保存"
placement="bottom">
<i class="iconfont iconsave"
@click="saveData"></i>
</el-tooltip> </el-tooltip>
</span> </span>
<span class="btn"> <span class="btn">
<el-tooltip class="item" effect="dark" content="预览" placement="bottom"> <el-tooltip class="item"
<svg-icon icon-class="eye-open" @click="viewScreen" /> effect="dark"
content="预览"
placement="bottom">
<i class="iconfont iconyulan"
@click="viewScreen"></i>
</el-tooltip> </el-tooltip>
</span> </span>
</div> </div>
<div class="workbench-container" :style="{ width: bigscreenWidthInWorkbench + 'px', height: bigscreenHeightInWorkbench + 'px' }"> <div class="workbench-container"
<vue-ruler-tool v-model="dashboard.presetLine" class="vueRuler" :step-length="50" :parent="true" :position="'relative'" :is-scale-revise="true" :visible.sync="dashboard.presetLineVisible"> :style="{ width: bigscreenWidthInWorkbench + 'px', height: bigscreenHeightInWorkbench + 'px' }">
<div id="workbench" class="workbench" :style="{ transform: workbenchTransform, width: bigscreenWidth + 'px', height: bigscreenHeight + 'px', 'background-color': dashboard.backgroundColor, 'background-image': 'url(' + dashboard.backgroundImage + ')', 'background-position': '0% 0%', 'background-size': '100% 100%', 'background-repeat': 'initial', 'background-attachment': 'initial', 'background-origin': 'initial', 'background-clip': 'initial' }" @click="setOptionsOnClickScreen"> <vue-ruler-tool v-model="dashboard.presetLine"
<widget v-for="(widget, index) in widgets" :key="index" v-model="widget.value" :index="index" :type="widget.type" :bigscreen="{ bigscreenWidth, bigscreenHeight }" @onActivated="setOptionsOnClickWidget" @contextmenu.prevent.native="rightClick($event, index)" /> class="vueRuler"
:step-length="50"
:parent="true"
:position="'relative'"
:is-scale-revise="true"
:visible.sync="dashboard.presetLineVisible">
<div id="workbench"
class="workbench"
:style="{ transform: workbenchTransform, width: bigscreenWidth + 'px', height: bigscreenHeight + 'px', 'background-color': dashboard.backgroundColor, 'background-image': 'url(' + dashboard.backgroundImage + ')', 'background-position': '0% 0%', 'background-size': '100% 100%', 'background-repeat': 'initial', 'background-attachment': 'initial', 'background-origin': 'initial', 'background-clip': 'initial' }"
@click="setOptionsOnClickScreen">
<widget v-for="(widget, index) in widgets"
:key="index"
v-model="widget.value"
:index="index"
:type="widget.type"
:bigscreen="{ bigscreenWidth, bigscreenHeight }"
@onActivated="setOptionsOnClickWidget"
@contextmenu.prevent.native="rightClick($event, index)" />
</div> </div>
</vue-ruler-tool> </vue-ruler-tool>
</div> </div>
</div> </div>
<div class="layout-right" :style="{ width: widthLeftForOptions + 'px' }"> <div class="layout-right"
<el-tabs v-model="activeName" type="border-card" :stretch="true"> :style="{ width: widthLeftForOptions + 'px' }">
<el-tab-pane v-if="isNotNull(widgetOptions.setup) || isNotNull(widgetOptions.collapse)" name="first" label="配置"> <el-tabs v-model="activeName"
<dynamicForm ref="formData" :options="widgetOptions.setup" @onChanged="(val) => widgetValueChanged('setup', val)" /> type="border-card"
:stretch="true">
<el-tab-pane v-if="isNotNull(widgetOptions.setup) || isNotNull(widgetOptions.collapse)"
name="first"
label="配置">
<dynamicForm ref="formData"
:options="widgetOptions.setup"
@onChanged="(val) => widgetValueChanged('setup', val)" />
</el-tab-pane> </el-tab-pane>
<el-tab-pane v-if="isNotNull(widgetOptions.data)" name="second" label="数据"> <el-tab-pane v-if="isNotNull(widgetOptions.data)"
<dynamicForm ref="formData" :options="widgetOptions.data" @onChanged="(val) => widgetValueChanged('data', val)" /> name="second"
label="数据">
<dynamicForm ref="formData"
:options="widgetOptions.data"
@onChanged="(val) => widgetValueChanged('data', val)" />
</el-tab-pane> </el-tab-pane>
<el-tab-pane v-if="isNotNull(widgetOptions.position)" name="third" label="坐标"> <el-tab-pane v-if="isNotNull(widgetOptions.position)"
<dynamicForm ref="formData" :options="widgetOptions.position" @onChanged="(val) => widgetValueChanged('position', val)" /> name="third"
label="坐标">
<dynamicForm ref="formData"
:options="widgetOptions.position"
@onChanged="(val) => widgetValueChanged('position', val)" />
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
</div> </div>
<content-menu :visible.sync="visibleContentMenu" :style-obj="styleObj" @deletelayer="deletelayer" /> <content-menu :visible.sync="visibleContentMenu"
:style-obj="styleObj"
@deletelayer="deletelayer" />
</div> </div>
</template> </template>
@ -93,7 +147,7 @@ export default {
dynamicForm, dynamicForm,
contentMenu, contentMenu,
}, },
data() { data () {
return { return {
widgetTools: widgetTools, // js widgetTools: widgetTools, // js
widthLeftForTools: 200, // widthLeftForTools: 200, //
@ -159,7 +213,7 @@ export default {
}, },
computed: { computed: {
// //
middleWidth() { middleWidth () {
var widthLeftAndRight = 0 var widthLeftAndRight = 0
if (this.toolIsShow) { if (this.toolIsShow) {
widthLeftAndRight += this.widthLeftForTools // widthLeftAndRight += this.widthLeftForTools //
@ -170,26 +224,26 @@ export default {
var middleWidth = this.bodyWidth - widthLeftAndRight var middleWidth = this.bodyWidth - widthLeftAndRight
return middleWidth return middleWidth
}, },
middleHeight() { middleHeight () {
return this.bodyHeight return this.bodyHeight
}, },
// //
bigscreenScaleInWorkbench() { bigscreenScaleInWorkbench () {
var widthScale = this.middleWidth / this.bigscreenWidth var widthScale = this.middleWidth / this.bigscreenWidth
var heightScale = this.middleHeight / this.bigscreenHeight var heightScale = this.middleHeight / this.bigscreenHeight
return Math.min(widthScale, heightScale) return Math.min(widthScale, heightScale)
}, },
workbenchTransform() { workbenchTransform () {
return `scale(${this.bigscreenScaleInWorkbench}, ${this.bigscreenScaleInWorkbench})` return `scale(${this.bigscreenScaleInWorkbench}, ${this.bigscreenScaleInWorkbench})`
}, },
// //
bigscreenWidthInWorkbench() { bigscreenWidthInWorkbench () {
return this.getPXUnderScale(this.bigscreenWidth) return this.getPXUnderScale(this.bigscreenWidth)
}, },
bigscreenHeightInWorkbench() { bigscreenHeightInWorkbench () {
return this.getPXUnderScale(this.bigscreenHeight) return this.getPXUnderScale(this.bigscreenHeight)
}, },
layerWidget() { layerWidget () {
const layerWidgetArr = [] const layerWidgetArr = []
for (let i = 0; i < this.widgets.length; i++) { for (let i = 0; i < this.widgets.length; i++) {
layerWidgetArr.push(getToolByCode(this.widgets[i].type)) layerWidgetArr.push(getToolByCode(this.widgets[i].type))
@ -197,7 +251,7 @@ export default {
return layerWidgetArr return layerWidgetArr
}, },
}, },
mounted() { mounted () {
// //
this.setOptionsOnClickScreen() this.setOptionsOnClickScreen()
@ -206,7 +260,7 @@ export default {
this.widgets = [] this.widgets = []
}, },
methods: { methods: {
async initEchartData() { async initEchartData () {
const reportCode = this.$route.query.reportCode const reportCode = this.$route.query.reportCode
const { code, data } = await detailDashboard(reportCode) const { code, data } = await detailDashboard(reportCode)
if (code != 200) return if (code != 200) return
@ -215,7 +269,7 @@ export default {
this.widgets = processData this.widgets = processData
this.dashboard = screenData this.dashboard = screenData
}, },
handleBigScreen(data) { handleBigScreen (data) {
const optionScreen = this.deepClone(getToolByCode('screen').options) const optionScreen = this.deepClone(getToolByCode('screen').options)
const setup = optionScreen.setup const setup = optionScreen.setup
for (const key in data) { for (const key in data) {
@ -233,7 +287,7 @@ export default {
width: data.width, width: data.width,
} }
}, },
handleInitEchartsData(data) { handleInitEchartsData (data) {
console.log(data) console.log(data)
const widgets = data.dashboard.widgets const widgets = data.dashboard.widgets
const widgetsData = [] const widgetsData = []
@ -254,7 +308,7 @@ export default {
} }
return widgetsData return widgetsData
}, },
handleOptionsData(data, option) { handleOptionsData (data, option) {
for (const key in data.setup) { for (const key in data.setup) {
for (let i = 0; i < option.setup.length; i++) { for (let i = 0; i < option.setup.length; i++) {
if (key == option.setup[i].name) { if (key == option.setup[i].name) {
@ -292,7 +346,7 @@ export default {
return option return option
}, },
// //
async saveData() { async saveData () {
if (!this.widgets || this.widgets.length == 0) { if (!this.widgets || this.widgets.length == 0) {
this.$message.error('请添加组件') this.$message.error('请添加组件')
return return
@ -312,7 +366,7 @@ export default {
if (code != '200') return if (code != '200') return
}, },
// //
viewScreen() { viewScreen () {
var routeUrl = this.$router.resolve({ var routeUrl = this.$router.resolve({
path: '/report/bigscreen/viewer', path: '/report/bigscreen/viewer',
query: { reportCode: this.$route.query.reportCode }, query: { reportCode: this.$route.query.reportCode },
@ -320,12 +374,12 @@ export default {
window.open(routeUrl.href, '_blank') window.open(routeUrl.href, '_blank')
}, },
// //
getPXUnderScale(px) { getPXUnderScale (px) {
return this.bigscreenScaleInWorkbench * px return this.bigscreenScaleInWorkbench * px
}, },
// //
widgetOnDragged(evt, widgetCode) { widgetOnDragged (evt, widgetCode) {
var widgetType = widgetCode var widgetType = widgetCode
// //
@ -367,7 +421,7 @@ export default {
}, },
// //
handleDefaultValue(widgetJson) { handleDefaultValue (widgetJson) {
for (const key in widgetJson) { for (const key in widgetJson) {
if (key == 'options') { if (key == 'options') {
// collapsedatapositionsetup // collapsedatapositionsetup
@ -407,7 +461,7 @@ export default {
}, },
// //
setOptionsOnClickScreen() { setOptionsOnClickScreen () {
this.screenCode = 'screen' this.screenCode = 'screen'
// //
this.activeName = 'first' this.activeName = 'first'
@ -415,7 +469,7 @@ export default {
}, },
// //
setOptionsOnClickWidget(index) { setOptionsOnClickWidget (index) {
// //
this.activeName = 'first' this.activeName = 'first'
this.screenCode = '' this.screenCode = ''
@ -434,7 +488,7 @@ export default {
}, },
// //
widgetValueChanged(key, val) { widgetValueChanged (key, val) {
/* this.widgets this.widgetIndex value /* this.widgets this.widgetIndex value
widgets: [{ widgets: [{
type: 'widget-text', type: 'widget-text',
@ -455,7 +509,7 @@ export default {
} }
} }
}, },
rightClick(event, index) { rightClick (event, index) {
this.rightClickIndex = index this.rightClickIndex = index
const left = event.clientX const left = event.clientX
const top = event.clientY const top = event.clientY
@ -469,10 +523,10 @@ export default {
this.visibleContentMenu = true this.visibleContentMenu = true
return false return false
}, },
deletelayer() { deletelayer () {
this.widgets.splice(this.rightClickIndex, 1) this.widgets.splice(this.rightClickIndex, 1)
}, },
setDefaultValue(options, val) { setDefaultValue (options, val) {
for (let i = 0; i < options.length; i++) { for (let i = 0; i < options.length; i++) {
if (Object.prototype.toString.call(options[i]) == '[object Object]') { if (Object.prototype.toString.call(options[i]) == '[object Object]') {
for (const k in val) { for (const k in val) {
@ -640,30 +694,47 @@ export default {
background-color: #263445; background-color: #263445;
height: calc(100vh - 40px); height: calc(100vh - 40px);
overflow-x: hidden; overflow-x: hidden;
overflow-y: scroll; overflow-y: auto;
.el-tab-pane { .el-tab-pane {
color: #bfcbd9; color: #bfcbd9;
} }
&::-webkit-scrollbar { &::-webkit-scrollbar {
width: 14px; width: 5px;
height: 14px; height: 14px;
} }
&::-webkit-scrollbar-track, &::-webkit-scrollbar-track,
&::-webkit-scrollbar-thumb { &::-webkit-scrollbar-thumb {
border-radius: 999px; border-radius: 1px;
border: 5px solid transparent; border: 0 solid transparent;
} }
&::-webkit-scrollbar-track-piece {
/*修改滚动条的背景和圆角*/
background: #29405c;
-webkit-border-radius: 7px;
}
&::-webkit-scrollbar-track { &::-webkit-scrollbar-track {
box-shadow: 1px 1px 5px rgba(0, 0, 0, 0.5) inset; box-shadow: 1px 1px 5px rgba(55, 175, 255, 0.5) inset;
} }
&::-webkit-scrollbar-thumb { &::-webkit-scrollbar-thumb {
min-height: 20px; min-height: 20px;
background-clip: content-box; background-clip: content-box;
box-shadow: 0 0 0 5px rgba(0, 0, 0, 0.5) inset; box-shadow: 0 0 0 5px rgba(55, 175, 255, 0.5) inset;
} }
&::-webkit-scrollbar-corner { &::-webkit-scrollbar-corner {
background: transparent; background: transparent;
} }
/*修改垂直滚动条的样式*/
&::-webkit-scrollbar-thumb:vertical {
background-color: #00113a;
-webkit-border-radius: 7px;
}
/*修改水平滚动条的样式*/
&::-webkit-scrollbar-thumb:horizontal {
background-color: #00113a;
-webkit-border-radius: 7px;
}
} }
} }
} }

@ -71,7 +71,7 @@ const widgetTools = [
code: 'widget-text', code: 'widget-text',
type: 'html', type: 'html',
label: '文本', label: '文本',
icon: 'text', icon: 'iconziyuan',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -196,7 +196,7 @@ const widgetTools = [
code: 'widget-marquee', code: 'widget-marquee',
type: 'html', type: 'html',
label: '滚动文本', label: '滚动文本',
icon: 'marquee', icon: 'iconhengxiangwenzi',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -334,7 +334,7 @@ const widgetTools = [
code: 'widget-href', code: 'widget-href',
type: 'html', type: 'html',
label: '超链接', label: '超链接',
icon: 'href', icon: 'iconchaolianjie',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -483,7 +483,7 @@ const widgetTools = [
code: 'widget-time', code: 'widget-time',
type: 'html', type: 'html',
label: '当前时间', label: '当前时间',
icon: 'time', icon: 'iconshijian',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -614,7 +614,7 @@ const widgetTools = [
code: 'widget-image', code: 'widget-image',
type: 'html', type: 'html',
label: '图片', label: '图片',
icon: 'image', icon: 'icontupian',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -788,7 +788,7 @@ const widgetTools = [
code: 'widget-video', code: 'widget-video',
type: 'html', type: 'html',
label: '视频', label: '视频',
icon: 'video', icon: 'iconshipin',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -858,7 +858,7 @@ const widgetTools = [
code: 'widget-iframe', code: 'widget-iframe',
type: 'html', type: 'html',
label: '内联框架', label: '内联框架',
icon: 'iframe', icon: 'iconkuangjia',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -929,7 +929,7 @@ const widgetTools = [
code: 'widget-barchart', code: 'widget-barchart',
type: 'chart', type: 'chart',
label: '柱形图', label: '柱形图',
icon: 'barChart', icon: 'iconzhuzhuangtu',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -1491,7 +1491,7 @@ const widgetTools = [
code: 'widget-linechart', code: 'widget-linechart',
type: 'chart', type: 'chart',
label: '折线图', label: '折线图',
icon: 'lineChart', icon: 'icontubiaozhexiantu',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -2074,7 +2074,7 @@ const widgetTools = [
code: 'widget-barlinechart', code: 'widget-barlinechart',
type: 'chart', type: 'chart',
label: '柱线图', label: '柱线图',
icon: 'barLineChart', icon: 'iconzhuxiantu',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -2637,7 +2637,7 @@ const widgetTools = [
code: 'widget-piechart', code: 'widget-piechart',
type: 'chart', type: 'chart',
label: '饼图', label: '饼图',
icon: 'pieChart', icon: 'iconicon_tubiao_bingtu',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -3011,7 +3011,7 @@ const widgetTools = [
code: 'widget-hollow-piechart', code: 'widget-hollow-piechart',
type: 'chart', type: 'chart',
label: '空心饼图', label: '空心饼图',
icon: 'hollowPieChart', icon: 'icon020kongxinbingtu',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -3385,7 +3385,7 @@ const widgetTools = [
code: 'widget-funnel', code: 'widget-funnel',
type: 'chart', type: 'chart',
label: '漏斗图', label: '漏斗图',
icon: 'funnel', icon: 'iconloudoutu',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -3751,7 +3751,7 @@ const widgetTools = [
code: 'widget-gauge', code: 'widget-gauge',
type: 'chart', type: 'chart',
label: '仪表盘', label: '仪表盘',
icon: 'speed', icon: 'iconyibiaopan',
options: { options: {
// 配置 // 配置
setup: [ setup: [
@ -3900,13 +3900,13 @@ const widgetTools = [
// }, // },
] ]
const getToolByCode = function(code) { const getToolByCode = function (code) {
// 获取大屏底层设置属性 // 获取大屏底层设置属性
if (code == 'screen') { if (code == 'screen') {
return screenConfig return screenConfig
} }
// 获取组件 // 获取组件
var item = widgetTools.find(function(item, index, arrs) { var item = widgetTools.find(function (item, index, arrs) {
return item.code === code return item.code === code
}) })
return item return item

@ -55,8 +55,7 @@
placement="bottom-start"> placement="bottom-start">
<el-button type="text" <el-button type="text"
@click="preview()"> @click="preview()">
<svg-icon icon-class="yulancopy" <i class="iconfont iconfuzhi"></i>
class="yulancopy" />
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip class="item" <el-tooltip class="item"
@ -65,8 +64,7 @@
placement="bottom-start"> placement="bottom-start">
<el-button type="text" <el-button type="text"
@click="save()"> @click="save()">
<svg-icon icon-class="baocun" <i class="iconfont iconsave"></i>
class="baocun" />
</el-button> </el-button>
</el-tooltip> </el-tooltip>
</div> </div>

@ -55,8 +55,7 @@
placement="bottom-start"> placement="bottom-start">
<el-button type="text" <el-button type="text"
@click="preview()"> @click="preview()">
<svg-icon icon-class="yulancopy" <i class="iconfont iconfuzhi"></i>
class="yulancopy" />
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip class="item" <el-tooltip class="item"
@ -65,8 +64,7 @@
placement="bottom-start"> placement="bottom-start">
<el-button type="text" <el-button type="text"
@click="save()"> @click="save()">
<svg-icon icon-class="baocun" <i class="iconfont iconsave"></i>
class="baocun" />
</el-button> </el-button>
</el-tooltip> </el-tooltip>
</div> </div>

@ -13,14 +13,14 @@
download="xxx.xlsx"> download="xxx.xlsx">
<el-button type="text" <el-button type="text"
@click="download('')"> @click="download('')">
<svg-icon icon-class="excel" />导出excel <i class="iconfont iconexcel"></i>导出excel
</el-button> </el-button>
</a> </a>
<a v-if="reportCode != null" <a v-if="reportCode != null"
download="xxx.pdf"> download="xxx.pdf">
<el-button type="text" <el-button type="text"
@click="download('gaea_template_pdf')"> @click="download('gaea_template_pdf')">
<svg-icon icon-class="pdf" />导出pdf <i class="iconfont iconpdf"></i>导出pdf
</el-button> </el-button>
</a> </a>
</div> </div>

Loading…
Cancel
Save