提交 4669d370 authored 作者: 邓文彬's avatar 邓文彬

fix(mock数据): 完成

上级 c7a1eb48
{
"pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
{
"path": "pages/login/login"
},
{
"path": "pages/home/home",
"style": {
"navigationBarTitleText": ""
}
},
{
"path": "pages/login/login"
},
{ //操作日志
"path": "pages/index/operLog"
},
//杭州内网机房巡检
{
"path": "pages/report/sampleTable"
},
{ //修改密码
"path": "pages/index/editPd"
},
......@@ -33,9 +21,6 @@
"navigationBarTitleText": ""
}
}
],
"globalStyle": {
"pageOrientation": "landscape",
......
<template>
<view class="content">
<view class="login_wrap">
<view class="top-module">
<image src="@/static/logo.png" alt="" />
<view class="title">杭州内网监管在线</view>
</view>
<view class="form_wrap">
<view class="input_wrap">
<uni-easyinput
......@@ -46,8 +51,7 @@ import moment from "moment";
import { Base64 } from "js-base64";
export default {
components: {
},
components: {},
data() {
return {
person: {
......@@ -67,7 +71,6 @@ export default {
this.$store.commit("SET_DARF_DATA", {});
this.$store.commit("SET_LOG_LIST", []);
this.$store.commit("SET_ALL_DATA", []);
},
// 定义返回退出
onBackPress(options) {
......@@ -116,11 +119,13 @@ export default {
this.person.user == this.personList[key].user &&
this.person.pd == this.personList[key].passWord
) {
const userInfo = this.personList[key];
this.$store.commit("SET_USER", userInfo);
uni.setStorageSync("now_user", userInfo);
uni.setStorageSync("last_time", userInfo.LastSynchronizationTime || "");
uni.setStorageSync(
"last_time",
userInfo.LastSynchronizationTime || ""
);
uni.navigateTo({
url: "/pages/home/home",
......@@ -138,8 +143,6 @@ export default {
// 更新日志信息
const logContent = getLogContent(LOG_TYPE_ENUM.login);
log_list.push(logContent);
this.$store.commit("SET_LOG_LIST", log_list);
addLog(log_list);
......@@ -147,7 +150,6 @@ export default {
uni.hideLoading();
})
.catch((error) => {
if (error.code == 0) {
uni.showToast({
title: error.msg,
......@@ -167,7 +169,6 @@ export default {
// 密码不正确
} else {
uni.showToast({
title: "密码错误,请重试",
icon: "none",
......@@ -177,7 +178,6 @@ export default {
}
// 不存在该账号
} else {
uni.showToast({
title: "您无权登录,请联系管理员处理",
icon: "none",
......@@ -211,12 +211,30 @@ export default {
justify-content: center;
align-items: center;
.top-module {
width: 350px;
margin-bottom: 48px;
text-align: center;
image{
width: 88px;
height: 88px;
}
.title {
font-size: 26px;
color: #000000;
line-height: 34px;
text-shadow: 0 2px 4px rgba(0, 0, 0, 0.16);
}
}
.login_wrap {
}
.log-input {
width: 350px;
margin-bottom: 24px;
background: #fff;
color: #4a4a4a;
}
/deep/.is-input-border {
......@@ -229,37 +247,40 @@ export default {
}
/deep/.uni-easyinput__placeholder-class {
color: #ffffff;
color: #4a4a4a;
}
/deep/.is-focused {
border: 1px solid #ffffff !important;
border: 1px solid #4a4a4a !important;
.uniui-eye-filled {
color: #ffffff !important;
color: #4a4a4a !important;
}
.uniui-eye-slash-filled {
color: #ffffff !important;
color: #4a4a4a !important;
}
}
/deep/.uni-input-input {
color: #ffffff !important;
color: #4a4a4a !important;
}
/deep/.uniui-clear {
color: #ffffff !important;
color: #4a4a4a !important;
}
.login_btn {
background: #3774f6;
box-shadow: 0px 2px 14px 0px rgba(51, 104, 246, 0.24);
border-radius: 3px;
.login_btn_text {
width: 350px;
height: 40px;
background-color: #ffffff;
background-color: #3774f6;
box-shadow: 0px 1px 4px 0px rgba(84, 116, 232, 0.16);
border-radius: 2px;
display: flex;
align-items: center;
justify-content: center;
color: #577bff;
color: #fff;
}
}
}
......
......@@ -13,11 +13,10 @@
v-if="getValue(item.ratioKey, item.upValue) != 0"
>
{{ Math.abs(getValue(item.ratioKey, item.upValue)) }}
<!-- <svg-icon
:icon-class="
getValue(item.ratioKey, item.upValue) > 0 ? 'up' : 'down1'
"
/> -->
<image v-if=" getValue(item.ratioKey, item.upValue) > 0" src="@/static/img/huanbishangsheng.png"></image>
<image v-else src="@/static/img/huanbixiajiang.png"></image>
</text>
</view>
<view
......@@ -93,14 +92,13 @@ export default {
}
.upValue {
font-size: 16px;
// color: #ef5e59;
margin-left: 12px;
&.up {
color: #ef5e59;
}
&.down {
color: #0cc991;
image{
width: 16px;
height: 16px;
transform: translateY(2px);
}
}
}
.children {
......
......@@ -13,11 +13,11 @@
v-if="getValue(item.ratioKey, item.upValue) != 0"
>
{{ Math.abs(getValue(item.ratioKey, item.upValue)) }}
<svg-icon
:icon-class="
getValue(item.ratioKey, item.upValue) > 0 ? 'up' : 'down1'
"
/>
<image v-if=" getValue(item.ratioKey, item.upValue) > 0" src="@/static/img/huanbishangsheng.png"></image>
<image v-else src="@/static/img/huanbixiajiang.png"></image>
</text>
</view>
</view>
......@@ -70,11 +70,13 @@ export default {
}
.upValue {
font-size: 16px;
color: #ef5e59;
margin-left: 12px;
&.down {
color: #0cc991;
image{
width: 16px;
height: 16px;
transform: translateY(2px);
}
}
}
}
......
<template>
<view class="sampleTable">
<uni-nav-bar
:fixed="true"
background-color="rgba(214, 240, 255, 0.0)"
status-bar
rightWidth="300"
>
<block slot="left">
<view class="uni-nav-bar-text" @click="back">
<text class="iconfont icon-Arrow-Left"></text
></view>
</block>
</uni-nav-bar>
<view class="main">
<!-- 占位---不可删除 -->
<view class="seize-seat"> </view>
<view class="container box-shaow-box">
<view v-if="isJF" class="image-item top-image">
<image
src="@/static/img/add-img/jf_table.png"
mode="widthFix"
></image>
</view>
<view v-else class="image-item top-image">
<image
src="@/static/img/add-img/jd_table.png"
mode="widthFix"
></image>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
isJF: false,
};
},
onNavigationBarButtonTap(val) {
uni.navigateBack();
},
onLoad(options) {
this.isJF = options.isJF == 1;
},
methods: {
checkImage(val) {
let res = "";
res = `/static/img/report-table/report${val + 1}.png`;
return res;
},
back() {
uni.navigateBack();
},
},
};
</script>
<style lang="less" scoped>
.sampleTable {
width: 100%;
height: 100%;
background-image: linear-gradient(
90deg,
#e9f7fe 0%,
#dceffe 40%,
#d5ebfd 66%,
#c9e8fe 100%
);
.main {
margin-top: -44px;
width: 100%;
background-size: 100% 40rpx;
background-repeat: no-repeat;
.container {
margin: 0 auto;
width: 730rpx;
height: calc(100vh - 44px - var(--status-bar-height) - 20px);
padding: 23.53rpx 17.65rpx;
padding-bottom: 0;
// width: 341.18rpx;
overflow: auto;
display: flex;
flex-wrap: wrap;
justify-sampletable: space-between;
.image-item {
text-align: center;
width: 60%;
height: 100%;
background-color: #ffffff;
border-radius: 4px;
margin: 0 auto;
}
.top-image {
height: 288.24rpx;
}
image {
width: 100%;
box-shadow: 0px 0px 9.41rpx 0px rgba(84, 116, 232, 0.2);
// object-fit: contain;
}
}
}
.seize-seat {
height: 50px;
width: 100%;
background-image: linear-gradient(
90deg,
#e9f7fe 0%,
#dceffe 40%,
#d5ebfd 66%,
#c9e8fe 100%
);
}
// 导航栏样式
.uni-nav-bar-text {
height: 36px;
width: 36px;
background: #ffffff;
border: 0.4px solid rgba(224, 224, 224, 1);
border-radius: 18px;
border-radius: 50%;
color: #333;
text-align: center;
.iconfont {
font-size: 20px;
line-height: 36px;
}
}
}
</style>
差异被折叠。
static/logo.png

3.9 KB | W: | H:

static/logo.png

18.8 KB | W: | H:

static/logo.png
static/logo.png
static/logo.png
static/logo.png
  • 2-up
  • Swipe
  • Onion skin
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论