Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
temple_material_request
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
hookehuyr
2024-07-27 21:03:15 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
4d9ac2aeea32a831752ba428ea08152cf379b7e5
4d9ac2ae
1 parent
85a82141
fix 李琛测试调整优化细节
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
4 deletions
src/views/material_pre_request.vue
src/views/material_pre_request.vue
View file @
4d9ac2a
<!--
* @Date: 2024-07-23 12:53:15
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2024-07-2
6 17:39:31
* @LastEditTime: 2024-07-2
7 21:00:09
* @FilePath: /temple_material_request/src/views/material_pre_request.vue
* @Description: 待申领物资页面
-->
...
...
@@ -38,7 +38,7 @@
{{ item.product_name }} / {{ item.spec }}
</div>
</van-col>
<van-col span="8" style="display: flex; align-items: center;">
<van-col
v-if="item.edit"
span="8" style="display: flex; align-items: center;">
<van-field
v-model="item.apply_number"
style="border: 1px solid #f0f0f0; padding: 0; border-radius: 5px;"
...
...
@@ -47,12 +47,15 @@
input-align="center"
placeholder="数量"
type="number"
:disabled="!item.edit"
@blur="onBlur(item)"
@focus="onFocus(item)"
>
<template #left-icon></template>
</van-field> <span style="font-size: 0.9rem; color: #666;">个</span>
</van-col>
<van-col v-else span="8" style="display: flex; align-items: center; justify-content: end;">
<span style="font-size: 0.9rem; color: #666;">{{ item.apply_number }}</span> <span style="font-size: 0.9rem; color: #666;">个</span>
</van-col>
</van-row>
<div v-if="item.error" style="padding: 0.5rem 2rem 0 0; font-size: 0.85rem; color: red; text-align: right;">输入值有误</div>
</div>
...
...
@@ -141,7 +144,7 @@ const $route = useRoute();
const $router = useRouter();
useTitle($route.meta.title);
const activity_id = $route.query.activity_id ? $route.query.activity_id :
800863
;
const activity_id = $route.query.activity_id ? $route.query.activity_id :
''
;
const form_id = $route.query.form_id ? $route.query.form_id : '';
const client_id = $route.query.client_id ? $route.query.client_id : '';
...
...
@@ -155,6 +158,9 @@ const getDeptsList = async () => {
const { data, code } = await myDeptsAPI();
if (code) {
my_depts.value = data;
if (data.length === 1) { // 默认选中第一个
type_checked.value = data[0].dept_id;
}
if (!data.length) {
showToast('您暂无组别无法申领物资');
disabled_btn.value = true;
...
...
@@ -316,6 +322,12 @@ const onBlur = async (item) => { // 输入框失去焦点回调
}
}
const onFocus = (item) => {
if (item.apply_number === '0') {
item.apply_number = '';
}
}
const list = ref([]);
const material_id = ref('');
...
...
Please
register
or
login
to post a comment