From 2d459db54184d82b40cc387ca4208f9358a83075 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=BC=A0=E5=90=8C=E6=B5=B7?= <963808678@qq.com>
Date: Fri, 16 Dec 2022 09:22:23 +0800
Subject: [PATCH 1/5] 12/16
---
src/main.js | 7 +++--
.../detail/modules/operationArea.vue | 6 +++-
.../detail/modules/rightContent.vue | 30 +++++++++++++------
3 files changed, 30 insertions(+), 13 deletions(-)
diff --git a/src/main.js b/src/main.js
index 4fccd46..9bb9851 100644
--- a/src/main.js
+++ b/src/main.js
@@ -27,8 +27,8 @@ import VueContextMenu from 'vue-contextmenu'
import vcolorpicker from 'vcolorpicker'
import VXETable from 'vxe-table'
import 'vxe-table/lib/style.css'
-import 'vue-easytable/libs/theme-default/index.css';
-import VueEasytable from 'vue-easytable';
+import 'vue-easytable/libs/theme-default/index.css'
+import VueEasytable from 'vue-easytable'
Vue.use(VXETable)
Vue.use(VueContextMenu)
@@ -38,9 +38,10 @@ Vue.use(socket, '/hubs/chatHub')
Vue.use(VueAxios)
Vue.use(Dialog)
Vue.use(dataV)
-Vue.use(VueEasytable);
+Vue.use(VueEasytable)
Vue.prototype.hasPerm = hasBtnPermission
Vue.prototype.applocation = sysApplication
+Vue.prototype.$bus = new Vue()
Vue.config.productionTip = false
new Vue({
diff --git a/src/views/main/BookingLedger/detail/modules/operationArea.vue b/src/views/main/BookingLedger/detail/modules/operationArea.vue
index cd8b3e0..7b26d64 100644
--- a/src/views/main/BookingLedger/detail/modules/operationArea.vue
+++ b/src/views/main/BookingLedger/detail/modules/operationArea.vue
@@ -45,7 +45,7 @@
-
+
@@ -690,6 +690,10 @@ export default {
})
}
},
+ beforeUpload(file) {
+ console.log(this.details, 'this.details')
+ this.$bus.$emit('WebTest001', { upFileList: file, attachCode: 'other', attachName: '其他' })
+ },
uploadFile(file) {
const formData = new FormData()
formData.append('file', file.file)
diff --git a/src/views/main/BookingLedger/detail/modules/rightContent.vue b/src/views/main/BookingLedger/detail/modules/rightContent.vue
index 606f6be..8f0e4e4 100644
--- a/src/views/main/BookingLedger/detail/modules/rightContent.vue
+++ b/src/views/main/BookingLedger/detail/modules/rightContent.vue
@@ -17,13 +17,13 @@
@@ -285,7 +285,11 @@ export default {
locaService: []
}
},
- created() {},
+ created() {
+ this.$bus.$on('WebTest001', val => {
+ this.WebTest001(val)
+ })
+ },
watch: {
'$route.query': {
immediate: true,
@@ -392,6 +396,7 @@ export default {
.then(res => {
if (res.success) {
this.fileList = res.data
+ console.log(this.fileList)
}
})
.catch(err => {
@@ -421,12 +426,20 @@ export default {
this.upFileList = newFileList
},
beforeUpload(file) {
- debugger
this.upFileList = [...this.upFileList, file]
return false
},
+ WebTest001(val) {
+ console.log(val.upFileList)
+ this.beforeUpload(val.upFileList)
+ // this.upFileList = this.upFileList.unshift(val.upFileList)
+ this.attachCode = val.attachCode
+ this.attachName = val.attachName
+ this.handleUpload()
+ },
handleUpload() {
const { upFileList, attachCode, attachName } = this
+ console.log(upFileList, attachCode, attachName)
if (upFileList.length === 0) {
this.$message.error('请上传文件')
return false
@@ -867,9 +880,8 @@ export default {
color: #999;
padding: 20px 0;
line-height: 30px;
- .text{
+ .text {
display: inline-block;
-
}
}
}
@@ -1047,7 +1059,7 @@ export default {
width: 140px;
line-height: 32px;
}
- .format{
+ .format {
color: #999;
// color: @primary-color;
// opacity: .8;
From 7d05fbe1a301b97926f5b612930049044e8140e7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=BC=A0=E5=90=8C=E6=B5=B7?= <963808678@qq.com>
Date: Fri, 16 Dec 2022 16:11:51 +0800
Subject: [PATCH 2/5] 12/16
---
.../detail/modules/operationArea.vue | 2 +-
src/views/main/Customer/addForm.vue | 18 ++++++++++++------
2 files changed, 13 insertions(+), 7 deletions(-)
diff --git a/src/views/main/BookingLedger/detail/modules/operationArea.vue b/src/views/main/BookingLedger/detail/modules/operationArea.vue
index 7e4e5da..1aac81e 100644
--- a/src/views/main/BookingLedger/detail/modules/operationArea.vue
+++ b/src/views/main/BookingLedger/detail/modules/operationArea.vue
@@ -698,7 +698,7 @@ export default {
},
beforeUpload(file) {
console.log(this.details, 'this.details')
- this.$bus.$emit('WebTest001', { upFileList: file, attachCode: 'other', attachName: '其他' })
+ // this.$bus.$emit('WebTest001', { upFileList: file, attachCode: 'other', attachName: '其他' })
},
uploadFile(file) {
const formData = new FormData()
diff --git a/src/views/main/Customer/addForm.vue b/src/views/main/Customer/addForm.vue
index a7c5cf5..957b0a5 100644
--- a/src/views/main/Customer/addForm.vue
+++ b/src/views/main/Customer/addForm.vue
@@ -17,7 +17,9 @@
- 基本信息
+
+ 基本信息
+
- 联系人信息
+
+ 联系人信息
+
新增
@@ -122,7 +126,7 @@
resizable
show-overflow
:data="ContactsData"
- :edit-config="{ trigger: 'click', mode: 'cell' }"
+ :edit-config="{ trigger: 'click', mode: 'row' }"
>
@@ -162,7 +166,9 @@
- 财务信息
+
+ 财务信息
+
@@ -376,7 +382,7 @@ export default {
background: #fff;
padding: 25px;
}
-.CsForm .ant-form-item{
+.CsForm .ant-form-item {
margin-bottom: 10px;
}
.CsFormTitle {
@@ -390,7 +396,7 @@ export default {
padding: 0.25rem 0.5rem 0 0.5rem;
/* border: 1px solid #c9c9c9; */
}
-.CsFormTitle span i{
+.CsFormTitle span i {
margin-right: 7px;
}
From f651fc4298ec8fea0e8bbb38558beacbd24bcc96 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=BC=A0=E5=90=8C=E6=B5=B7?= <963808678@qq.com>
Date: Fri, 16 Dec 2022 16:46:51 +0800
Subject: [PATCH 3/5] 12/16
---
src/permission.js | 6 +-
src/store/modules/user.js | 346 +++++++++----------
src/views/main/CommondbCtnlist/addForm.vue | 5 +-
src/views/main/CommondbCtnlist/editForm.vue | 5 +-
src/views/main/CommondbCtnlist/index.vue | 55 +--
src/views/main/CommondbYardlist/addForm.vue | 5 +-
src/views/main/CommondbYardlist/editForm.vue | 5 +-
src/views/main/CommondbYardlist/index.vue | 32 +-
8 files changed, 202 insertions(+), 257 deletions(-)
diff --git a/src/permission.js b/src/permission.js
index 2a4bbc1..9fabf97 100644
--- a/src/permission.js
+++ b/src/permission.js
@@ -101,7 +101,8 @@ router.beforeEach((to, from, next) => {
.catch(() => {
console.log('=== 测试跳转页面,获取个人信息失败 ===')
store.dispatch('Logout').then(() => {
- next({ path: '/user/login', query: { redirect: to.fullPath } })
+ // next({ path: '/user/login', query: { redirect: to.fullPath } })
+ next({ path: '/user/login' })
})
})
store.dispatch('getNoticReceiveList').then(res => {})
@@ -115,7 +116,8 @@ router.beforeEach((to, from, next) => {
// 在免登录白名单,直接进入
next()
} else {
- next({ path: '/user/login', query: { redirect: to.fullPath } })
+ // next({ path: '/user/login', query: { redirect: to.fullPath } })
+ next({ path: '/user/login' })
NProgress.done() // if current page is login will not trigger afterEach hook, so manually handle it
}
}
diff --git a/src/store/modules/user.js b/src/store/modules/user.js
index a99f67c..aec24b0 100644
--- a/src/store/modules/user.js
+++ b/src/store/modules/user.js
@@ -1,30 +1,11 @@
import Vue from 'vue'
-import {
- login,
- getLoginUser,
- logout
-} from '@/api/modular/system/loginManage'
-import {
- sysDictTypeTree
-} from '@/api/modular/system/dictManage'
-import {
- sysMenuChange
-} from '@/api/modular/system/menuManage'
-import {
- ACCESS_TOKEN,
- ALL_APPS_MENU,
- DICT_TYPE_TREE_DATA,
- NOTICE_RECEIVED
-} from '@/store/mutation-types'
-import {
- sysFileInfoPreview
-} from '@/api/modular/system/fileManage'
-import {
- unReadNotice
-} from '@/api/modular/system/noticeReceivedManage'
-import {
- welcome, dateFormat
-} from '@/utils/util'
+import { login, getLoginUser, logout } from '@/api/modular/system/loginManage'
+import { sysDictTypeTree } from '@/api/modular/system/dictManage'
+import { sysMenuChange } from '@/api/modular/system/menuManage'
+import { ACCESS_TOKEN, ALL_APPS_MENU, DICT_TYPE_TREE_DATA, NOTICE_RECEIVED } from '@/store/mutation-types'
+import { sysFileInfoPreview } from '@/api/modular/system/fileManage'
+import { unReadNotice } from '@/api/modular/system/noticeReceivedManage'
+import { welcome, dateFormat } from '@/utils/util'
import store from '../index'
import router from '../../router'
@@ -47,10 +28,7 @@ const user = {
SET_TOKEN: (state, token) => {
state.token = token
},
- SET_NAME: (state, {
- name,
- welcome
- }) => {
+ SET_NAME: (state, { name, welcome }) => {
state.name = name
state.welcome = welcome
},
@@ -74,21 +52,25 @@ const user = {
},
APPEND_NOTICE: (state, notice) => {
notice.publicTime = dateFormat(notice.publicTime, 'YYYY-mm-dd HH:MM:SS')
- let notices = state.notices;
- let temp = notices.rows.filter(m => { return m.value == notice.type })[0]
- let other = notices.rows.filter(m => { return m.value != notice.type })
- temp.noticeData.unshift(notice);
- notices.totalRows++;
+ let notices = state.notices
+ let temp = notices.rows.filter(m => {
+ return m.value == notice.type
+ })[0]
+ let other = notices.rows.filter(m => {
+ return m.value != notice.type
+ })
+ temp.noticeData.unshift(notice)
+ notices.totalRows++
if (temp.noticeData.length > 6) {
- temp.noticeData.pop();
+ temp.noticeData.pop()
}
- notices.rows = [];
- notices.rows.push(temp);
- notices.rows.push.apply(notices.rows, other);
+ notices.rows = []
+ notices.rows.push(temp)
+ notices.rows.push.apply(notices.rows, other)
notices.rows.sort((obj1, obj2) => {
return obj1.index - obj2.index
})
- state.notices = notices;
+ state.notices = notices
},
SET_BOOKINGLIST: (state, list) => {
state.bookingList = list
@@ -100,195 +82,197 @@ const user = {
actions: {
// 登录
- Login({
- commit
- }, userInfo) {
+ Login({ commit }, userInfo) {
return new Promise((resolve, reject) => {
- login(userInfo).then(response => {
- if (!response.success) {
- reject(response.message)
- return
- }
- const result = response.data
- Vue.ls.set(ACCESS_TOKEN, result, 7 * 24 * 60 * 60 * 1000)
- commit('SET_TOKEN', result)
- resolve()
- // eslint-disable-next-line handle-callback-err
- }).catch(error => {
- // eslint-disable-next-line prefer-promise-reject-errors
- reject('后端未启动或代理错误')
- })
+ login(userInfo)
+ .then(response => {
+ if (!response.success) {
+ reject(response.message)
+ return
+ }
+ const result = response.data
+ Vue.ls.set(ACCESS_TOKEN, result, 7 * 24 * 60 * 60 * 1000)
+ commit('SET_TOKEN', result)
+ resolve()
+ // eslint-disable-next-line handle-callback-err
+ })
+ .catch(error => {
+ // eslint-disable-next-line prefer-promise-reject-errors
+ reject('后端未启动或代理错误')
+ })
})
},
// 获取用户信息
- GetInfo({
- commit
- }) {
+ GetInfo({ commit }) {
return new Promise((resolve, reject) => {
- getLoginUser().then(response => {
- if (response.success) {
- const data = response.data
- commit('SET_ADMINTYPE', data.adminType)
- commit('SET_ROLES', 1)
- commit('SET_BUTTONS', data.permissions)
- commit('SET_INFO', data)
- commit('SET_NAME', {
- name: data.name,
- welcome: welcome()
- })
- if (data.avatar != null) {
- sysFileInfoPreview({
- id: data.avatar
- }).then((res) => {
- commit('SET_AVATAR', window.URL.createObjectURL(new Blob([res])))
- }).catch((err) => {
- this.$message.error('预览错误:' + err.message)
+ getLoginUser()
+ .then(response => {
+ if (response.success) {
+ const data = response.data
+ commit('SET_ADMINTYPE', data.adminType)
+ commit('SET_ROLES', 1)
+ commit('SET_BUTTONS', data.permissions)
+ commit('SET_INFO', data)
+ commit('SET_NAME', {
+ name: data.name,
+ welcome: welcome()
})
- // commit('SET_AVATAR', process.env.VUE_APP_API_BASE_URL + '/sysFileInfo/preview?id=' + data.avatar)
+ if (data.avatar != null) {
+ sysFileInfoPreview({
+ id: data.avatar
+ })
+ .then(res => {
+ commit('SET_AVATAR', window.URL.createObjectURL(new Blob([res])))
+ })
+ .catch(err => {
+ this.$message.error('预览错误:' + err.message)
+ })
+ // commit('SET_AVATAR', process.env.VUE_APP_API_BASE_URL + '/sysFileInfo/preview?id=' + data.avatar)
+ }
+ resolve(data)
+ } else {
+ // eslint-disable-next-line no-undef
+ reject(new Error(data.message))
}
- resolve(data)
- } else {
- // eslint-disable-next-line no-undef
- reject(new Error(data.message))
- }
- }).catch(error => {
- reject(error)
- })
+ })
+ .catch(error => {
+ reject(error)
+ })
})
},
// 登出
- Logout({
- commit,
- state
- }) {
- return new Promise((resolve) => {
- logout(state.token).then(() => {
- resolve()
- }).catch(() => {
- resolve()
- }).finally(() => {
- commit('SET_TOKEN', '')
- commit('SET_ROLES', [])
- commit('SET_BUTTONS', [])
- commit('SET_ADMINTYPE', '')
- commit('SET_INFO', null)
- Vue.ls.remove(ACCESS_TOKEN)
- Vue.ls.remove(ALL_APPS_MENU)
- Vue.ls.remove(DICT_TYPE_TREE_DATA)
- })
+ Logout({ commit, state }) {
+ return new Promise(resolve => {
+ logout(state.token)
+ .then(() => {
+ resolve()
+ })
+ .catch(() => {
+ resolve()
+ })
+ .finally(() => {
+ commit('SET_TOKEN', '')
+ commit('SET_ROLES', [])
+ commit('SET_BUTTONS', [])
+ commit('SET_ADMINTYPE', '')
+ commit('SET_INFO', null)
+ Vue.ls.remove(ACCESS_TOKEN)
+ Vue.ls.remove(ALL_APPS_MENU)
+ Vue.ls.remove(DICT_TYPE_TREE_DATA)
+ })
})
},
// 加载所有字典数据
dictTypeData() {
return new Promise((resolve, reject) => {
- sysDictTypeTree().then((data) => {
- if (data.success) {
- const result = data.data
- Vue.ls.set(DICT_TYPE_TREE_DATA, result)
- resolve()
- } else {
- // eslint-disable-next-line no-undef
- reject(new Error(data.message))
- }
- }).catch(error => {
- reject(error)
- })
+ sysDictTypeTree()
+ .then(data => {
+ if (data.success) {
+ const result = data.data
+ Vue.ls.set(DICT_TYPE_TREE_DATA, result)
+ resolve()
+ } else {
+ // eslint-disable-next-line no-undef
+ reject(new Error(data.message))
+ }
+ })
+ .catch(error => {
+ reject(error)
+ })
})
},
// 切换应用菜单
- MenuChange({
- commit
- }, application) {
- return new Promise((resolve) => {
+ MenuChange({ commit }, application) {
+ return new Promise(resolve => {
sysMenuChange({
application: application.code
- }).then((res) => {
- const apps = {
- 'code': '',
- 'name': '',
- 'active': '',
- 'menu': ''
- }
- apps.active = true
- apps.menu = res.data
- // eslint-disable-next-line camelcase
- const all_app_menu = Vue.ls.get(ALL_APPS_MENU)
- // eslint-disable-next-line camelcase
- const new_false_all_app_menu = []
- // 先去除所有默认的,以为此时切换的即将成为前端缓存默认的应用
- all_app_menu.forEach(item => {
- if (item.active) {
- item.active = false
+ })
+ .then(res => {
+ const apps = {
+ code: '',
+ name: '',
+ active: '',
+ menu: ''
}
- new_false_all_app_menu.push(item)
+ apps.active = true
+ apps.menu = res.data
+ // eslint-disable-next-line camelcase
+ const all_app_menu = Vue.ls.get(ALL_APPS_MENU)
+ // eslint-disable-next-line camelcase
+ const new_false_all_app_menu = []
+ // 先去除所有默认的,以为此时切换的即将成为前端缓存默认的应用
+ all_app_menu.forEach(item => {
+ if (item.active) {
+ item.active = false
+ }
+ new_false_all_app_menu.push(item)
+ })
+ // 此时缓存中全部都是不默认的应用
+ Vue.ls.set(ALL_APPS_MENU, new_false_all_app_menu)
+ apps.name = application.name
+ apps.code = application.code
+ const applocationR = []
+ applocationR.push(apps)
+ Vue.ls.set(ALL_APPS_MENU, applocationR)
+ resolve(res)
+ const antDesignmenus = res.data
+ store
+ .dispatch('GenerateRoutes', {
+ antDesignmenus
+ })
+ .then(() => {
+ router.addRoutes(store.getters.addRouters)
+ })
+ // 切换应用刷新整体界面,暂且取消
+ // window.location.reload()
})
- // 此时缓存中全部都是不默认的应用
- Vue.ls.set(ALL_APPS_MENU, new_false_all_app_menu)
- apps.name = application.name
- apps.code = application.code
- const applocationR = []
- applocationR.push(apps)
- Vue.ls.set(ALL_APPS_MENU, applocationR)
- resolve(res)
- const antDesignmenus = res.data
- store.dispatch('GenerateRoutes', {
- antDesignmenus
- }).then(() => {
- router.addRoutes(store.getters.addRouters)
+ .catch(() => {
+ resolve()
})
- // 切换应用刷新整体界面,暂且取消
- // window.location.reload()
- }).catch(() => {
- resolve()
- })
})
},
// 获取收到的通知
- getNoticReceiveList({
- commit
- }) {
+ getNoticReceiveList({ commit }) {
return new Promise((resolve, reject) => {
unReadNotice({
pageSize: 6
- }).then((data) => {
- if (data.success) {
- const result = data.data
- commit('SET_NOTICES', result)
- resolve()
- } else {
- // eslint-disable-next-line no-undef
- reject(new Error(data.message))
- }
- }).catch(error => {
- reject(error)
})
+ .then(data => {
+ if (data.success) {
+ const result = data.data
+ commit('SET_NOTICES', result)
+ resolve()
+ } else {
+ // eslint-disable-next-line no-undef
+ reject(new Error(data.message))
+ }
+ })
+ .catch(error => {
+ reject(error)
+ })
})
},
// 设置订舱列表
- setBookingList({
- commit
- }, obj) {
- return new Promise((resolve) => {
+ setBookingList({ commit }, obj) {
+ return new Promise(resolve => {
commit('SET_BOOKINGLIST', obj)
resolve()
})
},
// 设置需要保存页面
- setNeedSavePages({
- commit
- }, obj) {
- return new Promise((resolve) => {
+ setNeedSavePages({ commit }, obj) {
+ return new Promise(resolve => {
commit('SET_NEEDSAVEPAGES', obj)
resolve()
})
- },
+ }
}
}
diff --git a/src/views/main/CommondbCtnlist/addForm.vue b/src/views/main/CommondbCtnlist/addForm.vue
index b347e53..31e2d79 100644
--- a/src/views/main/CommondbCtnlist/addForm.vue
+++ b/src/views/main/CommondbCtnlist/addForm.vue
@@ -19,7 +19,7 @@
@search="handleSearch"
:default-active-first-option="false"
:show-arrow="false"
- :filter-option="false"
+ :filter-option="filterOption"
:not-found-content="null"
>
@@ -115,6 +115,9 @@ export default {
},
mounted() {},
methods: {
+ filterOption(input, option) {
+ return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+ },
CarrierHandleSearch(data) {
commondbCarrierlist({ cnName: data }).then(res => {
this.carrierCodeData = res.data
diff --git a/src/views/main/CommondbCtnlist/editForm.vue b/src/views/main/CommondbCtnlist/editForm.vue
index 5665f13..ed7c4df 100644
--- a/src/views/main/CommondbCtnlist/editForm.vue
+++ b/src/views/main/CommondbCtnlist/editForm.vue
@@ -19,7 +19,7 @@
@search="handleSearch"
:default-active-first-option="false"
:show-arrow="false"
- :filter-option="false"
+ :filter-option="filterOption"
:not-found-content="null"
>
@@ -117,6 +117,9 @@ export default {
},
mounted() {},
methods: {
+ filterOption(input, option) {
+ return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+ },
CarrierHandleSearch(data) {
commondbCarrierlist({ cnName: data }).then(res => {
this.carrierCodeData = res.data
diff --git a/src/views/main/CommondbCtnlist/index.vue b/src/views/main/CommondbCtnlist/index.vue
index a33efdd..813f034 100644
--- a/src/views/main/CommondbCtnlist/index.vue
+++ b/src/views/main/CommondbCtnlist/index.vue
@@ -10,51 +10,14 @@
-
-
-
+
+
+
-
-
-
- {{ item.name }}
-
-
-
-
-
-
- {{ item.cnName }}
-
-
-
-
-
+
+
+
+
{{ item.name }}
@@ -189,6 +152,9 @@ export default {
this.init()
},
methods: {
+ filterOption(input, option) {
+ return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+ },
handleSearch(data) {
commondbCtn({ Name: data }).then(res => {
this.WCodeData = res.data
@@ -228,7 +194,6 @@ export default {
this.advanced = !this.advanced
},
init() {
-
Object.assign(this.$data, this.$options.data())
this.ColumnsQuery = this.columns
this.FnGetData()
diff --git a/src/views/main/CommondbYardlist/addForm.vue b/src/views/main/CommondbYardlist/addForm.vue
index bf6c572..ba59d5b 100644
--- a/src/views/main/CommondbYardlist/addForm.vue
+++ b/src/views/main/CommondbYardlist/addForm.vue
@@ -19,7 +19,7 @@
@search="handleSearch"
:default-active-first-option="false"
:show-arrow="false"
- :filter-option="false"
+ :filter-option="filterOption"
:not-found-content="null"
>
@@ -99,6 +99,9 @@ export default {
},
mounted() {},
methods: {
+ filterOption(input, option) {
+ return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+ },
handleSearch(data) {
commondbYardlist({ name: data }).then(res => {
this.CodeData = res.data
diff --git a/src/views/main/CommondbYardlist/editForm.vue b/src/views/main/CommondbYardlist/editForm.vue
index 469989d..033b9ee 100644
--- a/src/views/main/CommondbYardlist/editForm.vue
+++ b/src/views/main/CommondbYardlist/editForm.vue
@@ -19,7 +19,7 @@
@search="handleSearch"
:default-active-first-option="false"
:show-arrow="false"
- :filter-option="false"
+ :filter-option="filterOption"
:not-found-content="null"
>
@@ -101,6 +101,9 @@ export default {
},
mounted() {},
methods: {
+ filterOption(input, option) {
+ return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+ },
handleSearch(data) {
commondbYardlist({ name: data }).then(res => {
this.CodeData = res.data
diff --git a/src/views/main/CommondbYardlist/index.vue b/src/views/main/CommondbYardlist/index.vue
index bd6d9e9..2f1d319 100644
--- a/src/views/main/CommondbYardlist/index.vue
+++ b/src/views/main/CommondbYardlist/index.vue
@@ -10,32 +10,14 @@
-
-
-
+
+
+
-
-
-
- {{ item.name }}
-
-
-
-
-
+
+
+
+
{{ item.name }}
From d3f7db405b27b2e09769d0ecd7a27305adbf3497 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=BC=A0=E5=90=8C=E6=B5=B7?= <963808678@qq.com>
Date: Fri, 16 Dec 2022 16:55:44 +0800
Subject: [PATCH 4/5] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=A4=87=E6=B3=A8?=
=?UTF-8?q?=E5=BC=B9=E7=AA=97=20=E9=95=BF=E5=AE=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/main/BookingLedger/detail/modules/rightContent.vue | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/views/main/BookingLedger/detail/modules/rightContent.vue b/src/views/main/BookingLedger/detail/modules/rightContent.vue
index d9d7321..c5de98f 100644
--- a/src/views/main/BookingLedger/detail/modules/rightContent.vue
+++ b/src/views/main/BookingLedger/detail/modules/rightContent.vue
@@ -177,7 +177,7 @@
-
+
Date: Mon, 19 Dec 2022 10:29:05 +0800
Subject: [PATCH 5/5] =?UTF-8?q?OCR=20=E8=B0=83=E6=95=B4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../detail/modules/operationArea.vue | 20 ++++++++++---------
1 file changed, 11 insertions(+), 9 deletions(-)
diff --git a/src/views/main/BookingLedger/detail/modules/operationArea.vue b/src/views/main/BookingLedger/detail/modules/operationArea.vue
index 1aac81e..fc5d181 100644
--- a/src/views/main/BookingLedger/detail/modules/operationArea.vue
+++ b/src/views/main/BookingLedger/detail/modules/operationArea.vue
@@ -658,9 +658,8 @@ export default {
ctx.lineWidth = 1
this.width = e.offsetX - x
this.height = e.offsetY - y
- this.Bx = e.offsetX
- this.By = e.offsetY
- ctx.strokeRect(x, y, e.offsetX + 5 - x, e.offsetY + 5 - y)
+
+ ctx.strokeRect(x, y, e.offsetX - x, e.offsetY - y)
}
},
mousemove(e) {
@@ -672,14 +671,14 @@ export default {
this.$refs.myCanvas.getContext('2d').clearRect(0, 0, this.$refs.myCanvas.width, this.$refs.myCanvas.height)
if (this.imgSrc) {
this.flag = true
- this.x = e.offsetX + 5 // 鼠标落下时的X
- this.y = e.offsetY + 5 // 鼠标落下时的Y
+ this.x = e.offsetX // 鼠标落下时的X
+ this.y = e.offsetY // 鼠标落下时的Y
this.CvBoxType = false
this.width = 0
this.height = 0
}
},
- mouseup() {
+ mouseup(e) {
// console.log(this.width, this.flag, this.imgSrc)
this.flag = false
if (this.imgSrc && this.width != 0 && this.height != 0) {
@@ -692,6 +691,8 @@ export default {
scale: this.scale
}).then(res => {
this.Rdata = res.data
+ this.Bx = this.x + this.width
+ this.By = this.y + this.height
this.CvBoxType = true
})
}
@@ -1227,6 +1228,7 @@ export default {
}
.OCRBox {
/deep/.ant-drawer-body {
+ position: relative;
padding: 0 !important;
}
}
@@ -1248,9 +1250,9 @@ export default {
}
}
.CV {
- width: 100%;
- height: auto;
- background-repeat: no-repeat;
+ // width: 100%;
+ // height: auto;
+ // background-repeat: no-repeat;
}
@import url('../index.less');
.operation-area {