feat: 更新UI主题和样式,优化页面布局和交互
- 将侧边栏主题从深色改为浅色 - 移除多个组件的背景色和金属风格样式 - 调整按钮、表格和分页组件的样式和间距 - 新增easycode扫码功能页面 - 更新基础URL配置和应用版本号 - 优化登录后跳转逻辑和登出功能 - 调整滚动条和菜单项的样式
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
// 应用全局配置
|
||||
module.exports = {
|
||||
baseUrl: 'http://192.168.31.116:8080',
|
||||
// baseUrl: 'http://140.143.206.120:8080',
|
||||
// baseUrl: 'http://192.168.31.116:8080',
|
||||
baseUrl: 'http://140.143.206.120:8080',
|
||||
// baseUrl: 'http://localhost:8080',
|
||||
// 应用信息
|
||||
appInfo: {
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
"name" : "科伦普",
|
||||
"appid" : "__UNI__E781B49",
|
||||
"description" : "",
|
||||
"versionName" : "1.2.0",
|
||||
"versionCode" : "100",
|
||||
"versionName" : "3.4",
|
||||
"versionCode" : 1,
|
||||
"transformPx" : false,
|
||||
"app-plus" : {
|
||||
"usingComponents" : true,
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
{
|
||||
"pages": [
|
||||
{
|
||||
"path": "pages/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "首页",
|
||||
"path" : "pages/easycode/easycode",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "扫码",
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/login",
|
||||
@@ -13,6 +14,13 @@
|
||||
"navigationBarTitleText": "登录"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "首页",
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
"path": "pages/mine/index",
|
||||
@@ -91,28 +99,28 @@
|
||||
"navigationBarTitleText": "RuoYi",
|
||||
"navigationBarBackgroundColor": "#FFFFFF"
|
||||
},
|
||||
"tabBar": {
|
||||
"list": [
|
||||
{
|
||||
"text": "产线",
|
||||
"pagePath": "pages/index",
|
||||
"selectedIconPath": "/static/images/tabbar/home_.png",
|
||||
"iconPath": "/static/images/tabbar/home.png"
|
||||
},
|
||||
{
|
||||
"text": "扫码",
|
||||
"pagePath": "pages/code/code",
|
||||
"selectedIconPath": "/static/images/tabbar/work_.png",
|
||||
"iconPath": "/static/images/tabbar/work.png"
|
||||
},
|
||||
{
|
||||
"text": "我的",
|
||||
"pagePath": "pages/mine/index",
|
||||
"selectedIconPath": "/static/images/tabbar/mine_.png",
|
||||
"iconPath": "/static/images/tabbar/mine.png"
|
||||
}
|
||||
]
|
||||
},
|
||||
// "tabBar": {
|
||||
// "list": [
|
||||
// {
|
||||
// "text": "产线",
|
||||
// "pagePath": "pages/index",
|
||||
// "selectedIconPath": "/static/images/tabbar/home_.png",
|
||||
// "iconPath": "/static/images/tabbar/home.png"
|
||||
// },
|
||||
// {
|
||||
// "text": "扫码",
|
||||
// "pagePath": "pages/code/code",
|
||||
// "selectedIconPath": "/static/images/tabbar/work_.png",
|
||||
// "iconPath": "/static/images/tabbar/work.png"
|
||||
// },
|
||||
// {
|
||||
// "text": "我的",
|
||||
// "pagePath": "pages/mine/index",
|
||||
// "selectedIconPath": "/static/images/tabbar/mine_.png",
|
||||
// "iconPath": "/static/images/tabbar/mine.png"
|
||||
// }
|
||||
// ]
|
||||
// },
|
||||
"easycom": {
|
||||
"autoscan": true,
|
||||
"custom": {
|
||||
|
||||
60
apps/hand-factory/pages/easycode/easycode.vue
Normal file
60
apps/hand-factory/pages/easycode/easycode.vue
Normal file
@@ -0,0 +1,60 @@
|
||||
<template>
|
||||
<view>
|
||||
<button v-for='item in types' @click="handleScan(item.dictValue)">
|
||||
{{ item.dictLabel }}
|
||||
</button>
|
||||
|
||||
<button @click='handleLogout'>
|
||||
退出登录
|
||||
</button>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getDicts } from '@/api/system/dict/data.js'
|
||||
import { getGenerateRecord } from '@/api/wms/code.js'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
types: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
handleLogout() {
|
||||
this.$modal.confirm('确定注销并退出系统吗?').then(() => {
|
||||
this.$store.dispatch('LogOut').then(() => {}).finally(() => {
|
||||
this.$tab.reLaunch('/pages/login')
|
||||
})
|
||||
})
|
||||
},
|
||||
handleScan(type) {
|
||||
// 1. 扫码
|
||||
uni.scanCode({
|
||||
success(res) {
|
||||
const result = res.result;
|
||||
// 2. 解析二维码的content,获取enter_coil_no、current_coil_no和coil_id
|
||||
const qrcodeRecord = qrcodeRes.data;
|
||||
const content = JSON.parse(qrcodeRecord.content);
|
||||
const enterCoilNo = content.enter_coil_no;
|
||||
const currentCoilNo = content.current_coil_no;
|
||||
const coilId = content.coil_id && content.coil_id !== 'null' ? content.coil_id : null;
|
||||
|
||||
// 3. 调用创建待操作记录的API
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
// 获取字典
|
||||
getDicts('easycode_type').then(res => {
|
||||
console.log(res)
|
||||
this.types = res.data
|
||||
})
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
@@ -64,7 +64,7 @@
|
||||
onLoad() {
|
||||
//#ifdef H5
|
||||
if (getToken()) {
|
||||
this.$tab.reLaunch('/pages/index')
|
||||
this.$tab.reLaunch('/pages/easycode/easycode')
|
||||
}
|
||||
//#endif
|
||||
},
|
||||
@@ -122,7 +122,7 @@
|
||||
loginSuccess(result) {
|
||||
// 设置用户信息
|
||||
this.$store.dispatch('GetInfo').then(res => {
|
||||
this.$tab.reLaunch('/pages/index')
|
||||
this.$tab.reLaunch('/pages/easycode/easycode')
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@@ -103,9 +103,9 @@
|
||||
},
|
||||
handleLogout() {
|
||||
this.$modal.confirm('确定注销并退出系统吗?').then(() => {
|
||||
// this.$store.dispatch('LogOut').then(() => {}).finally(() => {
|
||||
this.$store.dispatch('LogOut').then(() => {}).finally(() => {
|
||||
this.$tab.reLaunch('/pages/login')
|
||||
// })
|
||||
})
|
||||
})
|
||||
},
|
||||
handleToEditInfo() {
|
||||
|
||||
Reference in New Issue
Block a user