feat(cargo-type): 优化搜索区布局并添加展开收缩功能
- 将类别和货物类型编码两个搜索字段改为单行并排布局,提升界面紧凑度 - 添加展开/收缩切换按钮,默认收缩,按钮带箭头图标动画 - searchMenuSlot 中新增展开/收缩按钮,移除搜索图标 - 调整相关样式,实现搜索区域元素横向排列,增强用户体验
This commit is contained in:
@@ -35,7 +35,6 @@ export const getCargoTypeOption = ctx => ({
|
||||
updateBtnText: '提交',
|
||||
searchShow: true,
|
||||
searchMenuSpan: 24,
|
||||
searchIcon: true,
|
||||
searchIndex: 8,
|
||||
searchMenuPosition: 'right',
|
||||
border: true,
|
||||
@@ -56,6 +55,7 @@ export const getCargoTypeOption = ctx => ({
|
||||
dataType: 'number',
|
||||
dicData: typeLevelDic,
|
||||
search: true,
|
||||
searchSpan: 12,
|
||||
value: 2,
|
||||
span: 24,
|
||||
minWidth: 120,
|
||||
@@ -106,6 +106,7 @@ export const getCargoTypeOption = ctx => ({
|
||||
prop: 'cargoCode',
|
||||
minWidth: 140,
|
||||
search: true,
|
||||
searchSpan: 12,
|
||||
maxlength: 4,
|
||||
editDisabled: true,
|
||||
rules: [
|
||||
|
||||
@@ -91,7 +91,6 @@
|
||||
<el-button
|
||||
type="primary"
|
||||
text
|
||||
icon="el-icon-view"
|
||||
v-if="permission.cargo_type_view"
|
||||
@click="$refs.crud.rowView(row, index)"
|
||||
>
|
||||
@@ -100,7 +99,6 @@
|
||||
<el-button
|
||||
type="primary"
|
||||
text
|
||||
icon="el-icon-edit"
|
||||
v-if="permission.cargo_type_edit"
|
||||
@click="$refs.crud.rowEdit(row, index)"
|
||||
>
|
||||
@@ -109,7 +107,6 @@
|
||||
<el-button
|
||||
type="primary"
|
||||
text
|
||||
icon="el-icon-delete"
|
||||
v-if="permission.cargo_type_delete"
|
||||
@click="rowDel(row)"
|
||||
>
|
||||
@@ -618,14 +615,33 @@ export default {
|
||||
}
|
||||
|
||||
:deep(.avue-crud__search) {
|
||||
padding: 12px 12px 4px;
|
||||
padding: 12px 12px 8px;
|
||||
margin-bottom: 8px;
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: nowrap;
|
||||
gap: 16px;
|
||||
}
|
||||
|
||||
:deep(.avue-crud__search .el-form-item__label) {
|
||||
min-width: 160px;
|
||||
white-space: nowrap;
|
||||
:deep(.avue-crud__search > .el-form) {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: nowrap;
|
||||
}
|
||||
|
||||
:deep(.avue-crud__search .el-form-item) {
|
||||
margin-bottom: 0;
|
||||
margin-right: 16px;
|
||||
}
|
||||
|
||||
:deep(.avue-crud__search-menu) {
|
||||
flex-shrink: 0;
|
||||
padding: 0;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
:deep(.el-table) {
|
||||
|
||||
Reference in New Issue
Block a user