当前位置:网站首页>Project training 13 - Interface supplement
Project training 13 - Interface supplement
2022-06-10 23:14:00 【ScarlettWX】
The welcome interface on the front end of the administrator has only one published dynamic rotation box, which is too monotonous , I added three more widgets .
- element UI The progress bar
element UI The progress bar can visually display the scale . Add a progress bar on the home page to display the number of applications processed by the administrator , The progress bar is in a el-card In component , Specific figures are shown below . The front-end code is as follows :
<el-card class="box-card" style=" margin-top: 15px">
<div slot="header" class="clearfix">
<span style="float: left"> Processed application </span>
<el-button style="float: right; padding: 3px 0" type="text" @click="jumpToHA"> Processing applications </el-button>
</div>
<div class="text item">
<el-row>
<el-progress :percentage=percentage ></el-progress>
</el-row>
<el-row><span> </span></el-row>
<el-row><span> </span></el-row>
<el-row>
<span style="float: left"> Number of outstanding applications :{
{
this.noHandle}}</span>
</el-row>
<el-row><span> </span></el-row>
<el-row>
<span style="float: left"> Number of applications processed :{
{
this.alHandle}}</span>
</el-row>
<el-row><span> </span></el-row>
<el-row>
<span style="float: left"> Total number of applications :{
{
this.twHandle}}</span>
</el-row>
</div>
</el-card>
<script>
countApp(){
let _this = this;
axios.get(`api/getAllApplicationList`).then(function (response) {
let result = response.data;
let totalNA=0;
let totalCount=0;
for (let i = 0;i < result.length;i++) {
if(result[i].apg === 2){
totalNA=totalNA+1;
}
totalCount=totalCount+1;
}
_this.noHandle=totalNA;
console.log(" Number of outstanding applications :"+_this.noHandle)
_this.twHandle=totalCount;
console.log(" Total number of applications :"+_this.twHandle)
_this.alHandle=totalCount-totalNA;
console.log(" Number of applications processed :"+_this.alHandle)
_this.percentage=(_this.alHandle/_this.twHandle*100).toFixed(1)
console.log(" percentage :"+_this.percentage)
});
</script>
stay created Partial call this.countApp(), The progress bar is also loaded when the page is loaded .
2. Add a calendar to the page
element UI Provides a calendar component , But the size of the calendar has been fixed . In order to adapt to the size of the home page , Can be in style Use in /deep/ Depth selector to change element UI Style of component . The code is as follows :
/deep/ .el-calendar-table .el-calendar-day{
width: 50px;
height: 50px;
}
Introduction of calendar components :
<el-card class="box-card" style=" margin-top: 15px">
<el-calendar v-model="value">
</el-calendar>
</el-card>
stay data() Of return In a statement value: new Date().
- Quick module
Click the icon in the shortcut module to call the corresponding interface , This is from<router-link :to="'/0-0'">Component implemented . take icon And text type buttons are placed in this component , Click anywhere in the component to jump . The code is as follows :
<router-link :to="'/0-0'">
<div class="quick_menu_item">
<div class="icon">
<i class="el-icon-circle-plus-outline"></i>
</div>
<div class="text"><el-button type="text" > Processing applications </el-button></div>
</div>
</router-link>
- Arrangement
These components are not the same length , The calendar component is longer , If you follow the normal arrangement , Just put these components together , There will be a large area of blank . have access to el-row and el-col To arrange . In a el-row In the component , That is, in one line , Definition<el-col :span="12">Get the effect of two columns . Then put the calendar on the right , The progress bar and shortcut functions are on the left , Sinister col Divided into two el-row Arrange the two components up and down . Finally, adjust the height of individual components . The renderings are as follows :
边栏推荐
- 2022 t elevator repair test question simulation test question bank and online simulation test
- 集度夏一平:不是所有事都向李彦宏汇报,靠产品跟小米华为竞争
- IP反查域名
- Redis数据结构
- Electronic Society C language level 1 7. Draw rectangle
- 06 15 10 20 神秘代码,等你破译
- Is it safe to open a BOC securities account? Is the risk high?
- kubernetes多網卡方案之Multus CNI部署和基本使用
- [QPSK if] Verilog design of QPSK IF signal generation module based on FPGA
- Vscode common shortcuts
猜你喜欢

vulnhub之dc4

Ride the storm and explore the secret behind the open source of flyfish, a data visualization development platform!
![[QPSK if] Verilog design of QPSK IF signal generation module based on FPGA](/img/7d/b021790f1fde266ff9aa360261d581.png)
[QPSK if] Verilog design of QPSK IF signal generation module based on FPGA

【Flutter 问题系列第 6 篇】如何在 Flutter 中实现列表消息的滚动效果

vulnhub之dc3

字蛛(font-spider)教学——ttf/otf字体文件压缩

Can Huawei matepad become the secondary screen of your laptop?

PwnTheBox,Pwn:tutorial1

Question bank and simulation test of 2022 tea artist (intermediate) operation certificate examination

IP反查域名
随机推荐
A journey of database full SQL analysis and audit system performance optimization
期货开户有什么限制嘛?哪里最安全?
About string format(String format, Object... args)
分布式基础
中银证券开户有什么风险吗?安全的吗?
Online questionnaire system based on php+web+mysql
MySQL related -0416
Flowable BPMN相关知识
vulnhub之DC2
【QPSK中频】基于FPGA的QPSK中频信号产生模块verilog设计
Assembly: assembly mixed with c-faction language and corresponding lldb common instructions
0223-总结
[QPSK if] Verilog design of QPSK IF signal generation module based on FPGA
数据与信息资源共享平台(七)
PwnTheBox,Web:hello
Object 有哪些常用方法
数据与信息资源共享平台(六)
AI智能视频分析EasyCVR平台设备通道批量删除功能的开发实现
Icml2022 | revoir la traduction vocale de bout en bout du texte à partir de zéro
Our understanding of the industrial Internet is still trapped in the logic of an Internet like platform and center