Commit d81f32a3 authored by renjintao's avatar renjintao

Merge branch 'master' of git.mes123.com:zhouyx/mes-ui into product-rjt

parents 9f91144d b69a6cf3
...@@ -74,7 +74,6 @@ ...@@ -74,7 +74,6 @@
<slot name="leftBottom" v-if="leftOneName"> <slot name="leftBottom" v-if="leftOneName">
<Icon :type="leftOneIcon" class="iconStyle" /> <Icon :type="leftOneIcon" class="iconStyle" />
{{ leftOneName }} {{ leftOneName }}
<!-- v-show="leftBtmicon" -->
</slot> </slot>
</span> </span>
<span class="overdue f14 fwBold mr20"> <span class="overdue f14 fwBold mr20">
...@@ -84,9 +83,9 @@ ...@@ -84,9 +83,9 @@
</slot> </slot>
</span> </span>
</div> </div>
<span class="rightMore"> <div class="rightMore">
<slot name="rightBottom"> </slot> <slot name="rightBottom"> </slot>
</span> </div>
</div> </div>
</div> </div>
</div> </div>
...@@ -283,7 +282,7 @@ export default { ...@@ -283,7 +282,7 @@ export default {
} }
} }
.bottomCard { .bottomCard {
justify-content: space-between; // justify-content: space-between;
padding-bottom: 20px; padding-bottom: 20px;
padding-left: 14px; padding-left: 14px;
.leftBtm { .leftBtm {
...@@ -307,9 +306,6 @@ export default { ...@@ -307,9 +306,6 @@ export default {
} }
.cardBox:hover { .cardBox:hover {
box-shadow: 0px 0px 10px rgba(38, 128, 235, 0.4); box-shadow: 0px 0px 10px rgba(38, 128, 235, 0.4);
// .topCard {
// background: rgba(38, 128, 235, 0.4);
// }
} }
.borderCss { .borderCss {
border: 2px solid #2680eb; border: 2px solid #2680eb;
......
<template> <template>
<div class="datalife"> <div class="datalife ">
<div class="bigBing" :style="{width:220*bigNum+'px'}" v-if="mode"> <div class="bigBing" :style="{width:220*bigNum+100+'px'}" v-if="mode">
<div v-for="(item, index) in data" :key="index" class="linebox"> <div v-for="(item, index) in data" :key="index" class="linebox">
<div class="box" :class="curIndex == index ? 'boxBorder1':curIndex<index ? ' boxBorder2':' boxBorder' " > <div class="box" :class="curIndex == index ? 'boxBorder1':curIndex<index ? ' boxBorder2':' boxBorder' " >
<Tag type="dot" :color="item.color?item.color:tagColor" >{{ item.name }}</Tag> <Tag type="dot" :color="item.color?item.color:tagColor" >{{ item.name }}</Tag>
...@@ -9,8 +9,21 @@ ...@@ -9,8 +9,21 @@
<span class="item arrow-right" :class="[curIndex==index? 'boxBorder1' :curIndex<index? 'boxBorder2':'boxBorder']" ></span> <span class="item arrow-right" :class="[curIndex==index? 'boxBorder1' :curIndex<index? 'boxBorder2':'boxBorder']" ></span>
</div> </div>
</div> </div>
<div class='rightCode '>
<Poptip :content="code" placement='left-start'>
<a
data-clipboard-action="copy"
:data-clipboard-text="code"
@click="copy"
id="code"
class="tag-read"
><Icon type="ios-more" /></a
>
</Poptip>
</div>
</div> </div>
<div class="bigBing" :style="{width:240*bigNum+'px'}" v-else> <div class="bigBing" :style="{width:240*bigNum+100+'px'}" v-else>
<div class="lifeBox" v-for="(item, index) in data" :key="index"> <div class="lifeBox" v-for="(item, index) in data" :key="index">
<div class="arrow-left"> <div class="arrow-left">
<b class="right" v-if="index != 0"> <b class="right" v-if="index != 0">
...@@ -26,11 +39,26 @@ ...@@ -26,11 +39,26 @@
></b> ></b>
</div> </div>
</div> </div>
<div class='rightCode'>
<Poptip :content="code" placement='left-start'>
<a
data-clipboard-action="copy"
:data-clipboard-text="code"
@click="copy"
id="code"
class="tag-read"
><Icon type="ios-more" /></a
>
</Poptip>
</div>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import Clipboard from "clipboard";
export default { export default {
name: "life", name: "life",
data() { data() {
...@@ -60,6 +88,9 @@ export default { ...@@ -60,6 +88,9 @@ export default {
type:String, type:String,
default:"" default:""
} }
},
async fetch({ store, params }) {
await store.dispatch("loadDictionary"); // 加载数据字典
}, },
created() { created() {
this.data = this.$store.getters.dictionaryByKey(this.code) || []; this.data = this.$store.getters.dictionaryByKey(this.code) || [];
...@@ -71,13 +102,35 @@ export default { ...@@ -71,13 +102,35 @@ export default {
}) })
}, },
methods: { methods: {
copy() {
var clipboard = new Clipboard(".tag-read");
clipboard.on("success", (e) => {
this.$Message.success("复制成功:" + this.code);
clipboard.destroy();
});
clipboard.on("error", (e) => {
// 不支持复制
console.log("该浏览器不支持自动复制"); // 释放内存
clipboard.destroy();
});
},
}, },
}; };
</script> </script>
<style lang="less" > <style lang="less" >
.datalife { .datalife {
overflow-x: auto; overflow-x: auto;
width: auto;
.bigBing{
position: relative;
.rightCode{
position: absolute;
right: 0;
top: 0;
}
}
.linebox { .linebox {
display: inline-flex; display: inline-flex;
.box { .box {
...@@ -270,5 +323,9 @@ export default { ...@@ -270,5 +323,9 @@ export default {
} }
} }
} }
// .ivu-poptip-popper{
// top: 27px;
// right:0
// }
} }
</style> </style>
\ No newline at end of file
<template> <template>
<div <div class="rightM pr" v-if="rightM && rightList">
class="rightM flex" <div class="flex rightMbtns mr10" :class="{'pa':!more}" @mouseleave="more=true" >
:class="{ mr10: num == 1 }" <slot>
v-if="rightM && rightList" <op
@mouseleave="outPut" class="mr5 opBtns tc"
> v-if="btnBoxList && btnBoxList.length > 0"
<slot > v-for="(v, i) in btnBoxList"
<op v-if="rightList && rightList.slice(0, num).length > 0" :key="i"
v-for="(v, i) in rightList.slice(0, num)" :title="v.name"
:key="i" :type="v.type"
:title="v.name" :msg="v.msg"
:type="v.type" :disable="v.disable == null || v.disable == undefined ? false : true"
:msg="v.msg" @click.native="v.click(row,$event)"
:disable="v.disable" >
@click="v.click(row,$event)" <Icon
> :type="v.icon == null || v.icon == undefined ? 'ios-paper' : v.icon"
<Icon :type="v.icon==null || v.icon==undefined ? 'ios-paper':v.icon" v-if="v.type=='icon'|| v.type=='' || v.type==undefined || v.type==null "/> v-if="
<span v-if="v.name"> v.type == 'icon' ||
{{ v.name }} v.type == '' ||
</span> v.type == undefined ||
</op> v.type == null
<span "
class="elliPsis fwBold" />
slot="elliPsis" <span v-if="v.name">
v-if="rightList && rightList.length > num > 0" {{ v.name }}
> </span>
<span :class="{ hide: inlines, mr10: !inlines }" @mouseenter="inFo" </op>
>•••</span > <div
<span class="mr10" :class="{ inline: inlines, hide: !inlines }"> class="elliPsis fwBold mr10"
<op v-if="num<rightList.length&&more"
v-for="(value, index) in rightList.slice(num)" @mouseenter="more=false"
:key="index" >
:title="value.name" •••
:type="value.type" </div>
:msg="value.msg" </slot>
:disable="value.disable" </div>
@click="value.click(row,$event)"
v-if="rightList && rightList.slice(num).length >= num"
>
<Icon :type="value.icon==''?'ios-paper':value.icon" v-if="value.type=='icon'|| value.type=='' || value.type==undefined || value.type==null"/>
<span v-if="value.name">
{{ value.name }}
</span>
</op>
</span>
</span>
</slot>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
name: "rm",
data() { data() {
return { return {
inlines: false, more: true,
btnBoxList: [],
}; };
}, },
props: { props: {
row: { row: {
type:[Object,Array], type: [Object, Array],
default: [] default: [],
}, },
rightList: { rightList: {
type:[Object,Array], type: Array,
default: [], default: [],
}, },
num: { num: {
...@@ -75,25 +65,44 @@ export default { ...@@ -75,25 +65,44 @@ export default {
}, },
}, },
mounted() { mounted() {
// console.log("$slots",this.$slots,this.$slots.default)
}, },
methods: { methods: {
inFo() { // hello(row,event){
this.inlines = true; // console.log('111',row,event)
}, // }
outPut() {
this.inlines = false;
},
}, },
computed:{
btnBoxList(){
if(this.num>=this.rightList.length){
return this.rightList;
}else {
if(this.more)
return this.rightList.slice(0, this.num);
else
return this.rightList;
}
}
}
}; };
</script> </script>
<style lang="less" >
<style lang="less" scoped>
.rightM { .rightM {
overflow: visible;
cursor: pointer; cursor: pointer;
height: auto; width: 100%;
height: 100%;
.elliPsis { .elliPsis {
color: #2680eb; color: #2680eb;
} }
.rightMbtns{
background: #ffffff;
right: 0;
top:-12px;
z-index: 99;
}
.opBtns{
min-width: 55px;
}
} }
</style> </style>
\ No newline at end of file
...@@ -52,7 +52,7 @@ export default { ...@@ -52,7 +52,7 @@ export default {
// }, // },
series: [ series: [
{ {
name: "访问来源", name: "产品消耗工时占比",
type: "pie", type: "pie",
radius: ["25%", "33%"], radius: ["25%", "33%"],
center: ["28%", "60%"], center: ["28%", "60%"],
...@@ -92,10 +92,10 @@ export default { ...@@ -92,10 +92,10 @@ export default {
}, },
}, },
data: [ data: [
{ value: 335, name: "直接访问" }, { value: 335, name: "V+圆锥齿轮" },
{ value: 310, name: "邮件营销" }, { value: 310, name: "A类螺旋齿轮" },
{ value: 234, name: "联盟广告" }, { value: 234, name: "AV单齿轮风力装置" },
{ value: 135, name: "视频广告" }, { value: 135, name: "DF-变级齿轮箱" },
], ],
}, },
], ],
......
...@@ -34,7 +34,7 @@ export default { ...@@ -34,7 +34,7 @@ export default {
text: "月度计划进行情况", text: "月度计划进行情况",
left: "left", left: "left",
left: 160, left: 160,
top: 28, top: 25,
textStyle: { textStyle: {
color: "#106FFE", color: "#106FFE",
}, },
...@@ -64,7 +64,7 @@ export default { ...@@ -64,7 +64,7 @@ export default {
// }, // },
series: [ series: [
{ {
name: "访问来源", name: "月度计划进行情况",
type: "pie", type: "pie",
radius: "55%", radius: "55%",
center: ["40%", "60%"], center: ["40%", "60%"],
......
...@@ -81,7 +81,7 @@ export default { ...@@ -81,7 +81,7 @@ export default {
name: "来源", name: "来源",
type: "pie", type: "pie",
radius: ["16%", "18%"], radius: ["16%", "18%"],
center: ["13%", "24%"], center: ["13%", "22%"],
avoidLabelOverlap: false, avoidLabelOverlap: false,
hoverAnimation: false, hoverAnimation: false,
label: { label: {
...@@ -133,7 +133,7 @@ export default { ...@@ -133,7 +133,7 @@ export default {
name: "来源", name: "来源",
type: "pie", type: "pie",
radius: ["16%", "18%"], radius: ["16%", "18%"],
center: ["10%", "24%"], center: ["10%", "22%"],
avoidLabelOverlap: false, avoidLabelOverlap: false,
hoverAnimation: false, hoverAnimation: false,
label: { label: {
......
...@@ -38,7 +38,7 @@ export default { ...@@ -38,7 +38,7 @@ export default {
title: { title: {
text: "本月质量合格率", text: "本月质量合格率",
left: "22%", left: "22%",
top: 16, top: 8,
textStyle: { textStyle: {
color: "#106FFE", color: "#106FFE",
}, },
......
<!--
* @Author: your name
* @Date: 2020-11-20 09:47:27
* @LastEditTime: 2020-11-27 18:24:31
* @LastEditors: Please set LastEditors
* @Description: In User Settings Edit
* @FilePath: \mes-ui\pages\bigScreen\qualityProblem.vue
-->
<template> <template>
<div class="quality"> <div class="quality">
<h4>质量问题滚动播报</h4> <h4>质量问题滚动播报</h4>
...@@ -74,7 +82,7 @@ export default { ...@@ -74,7 +82,7 @@ export default {
h4 { h4 {
height: 50px; height: 50px;
line-height: 50px; line-height: 35px;
font-size: 17px; font-size: 17px;
padding-top: 2px; padding-top: 2px;
color: #106ffe; color: #106ffe;
...@@ -85,6 +93,7 @@ export default { ...@@ -85,6 +93,7 @@ export default {
height: 36px; height: 36px;
line-height: 36px; line-height: 36px;
background: #2f2f57; background: #2f2f57;
margin-top: -10px;
} }
.item-row { .item-row {
height: 44px; height: 44px;
......
...@@ -39,7 +39,7 @@ export default { ...@@ -39,7 +39,7 @@ export default {
title: { title: {
text: "年度计划完成情况", text: "年度计划完成情况",
left: "42%", left: "42%",
top: 16, top: 8,
textStyle: { textStyle: {
color: "#106FFE", color: "#106FFE",
}, },
......
...@@ -33,7 +33,7 @@ export default { ...@@ -33,7 +33,7 @@ export default {
title: { title: {
text: "暂停任务类型分布", text: "暂停任务类型分布",
left: "11%", left: "11%",
top: 20, top: 8,
textStyle: { textStyle: {
color: "#106FFE", color: "#106FFE",
}, },
......
...@@ -199,7 +199,7 @@ export default { ...@@ -199,7 +199,7 @@ export default {
} }
Api.create(this.entity) Api.create(this.entity)
.then((r) => { .then((r) => {
debugger;
if (r.success) { if (r.success) {
this.$Message.success("保存成功"); this.$Message.success("保存成功");
//添加当前登陆人为项目经理 //添加当前登陆人为项目经理
......
...@@ -171,12 +171,10 @@ Vue.component("FilesViewer", FilesViewer) ...@@ -171,12 +171,10 @@ Vue.component("FilesViewer", FilesViewer)
Vue.use(Contextmenu); Vue.use(Contextmenu);
//注入mock //注入mock
// require("../mock") require("../mock")
// Vue.component("Vcard", Vcard) Vue.component("Vcard", Vcard)
// Vue.component("BtnBox", BtnBox) Vue.component("BtnBox", BtnBox)
// Vue.component("RightM", RightM) Vue.component("RightM", RightM)
//注入mock
// require("../mock")
Vue.prototype.$api = request; Vue.prototype.$api = request;
Vue.prototype.$http = Api; Vue.prototype.$http = Api;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment