fix: 🧩 财务管理显示问题
This commit is contained in:
parent
2a8aca1642
commit
49c2eb264f
|
@ -72,7 +72,10 @@ defineExpose({ formRef });
|
||||||
<!-- 类别id -->
|
<!-- 类别id -->
|
||||||
<el-form-item :label="$t('category')" prop="categoryId">
|
<el-form-item :label="$t('category')" prop="categoryId">
|
||||||
<el-select v-model="form.categoryId" :placeholder="$t('select') + $t('category')" clearable filterable>
|
<el-select v-model="form.categoryId" :placeholder="$t('select') + $t('category')" clearable filterable>
|
||||||
<el-option v-for="item in categoryUserStore.allCategoryList" :key="item.id" :label="item.categoryName" :navigationBar="false" :value="item.id" />
|
<el-option v-for="item in categoryUserStore.allCategoryList" :key="item.id" :label="item.categoryName" :navigationBar="false" :value="item.id">
|
||||||
|
<el-text v-if="item.isBuiltin" effect="plain" size="large" type="info">{{ item.categoryName }}</el-text>
|
||||||
|
<el-text v-else effect="plain" size="large" type="success">{{ item.categoryName }}</el-text>
|
||||||
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
|
|
|
@ -36,7 +36,19 @@ export const columns: TableColumnList = [
|
||||||
// 描述
|
// 描述
|
||||||
{ label: $t('description'), prop: 'description' },
|
{ label: $t('description'), prop: 'description' },
|
||||||
// 交易日期
|
// 交易日期
|
||||||
{ label: $t('transactionDate'), prop: 'transactionDate', width: 160 },
|
{
|
||||||
|
label: $t('transactionDate'),
|
||||||
|
prop: 'transactionDate',
|
||||||
|
width: 190,
|
||||||
|
sortable: true,
|
||||||
|
formatter({ transactionDate }) {
|
||||||
|
return (
|
||||||
|
<ElText type={'success'} style={{ fontWeight: 800 }}>
|
||||||
|
{transactionDate}
|
||||||
|
</ElText>
|
||||||
|
);
|
||||||
|
},
|
||||||
|
},
|
||||||
{ label: $t('table.updateTime'), prop: 'updateTime', sortable: true, width: 160 },
|
{ label: $t('table.updateTime'), prop: 'updateTime', sortable: true, width: 160 },
|
||||||
{ label: $t('table.createTime'), prop: 'createTime', sortable: true, width: 160 },
|
{ label: $t('table.createTime'), prop: 'createTime', sortable: true, width: 160 },
|
||||||
{ label: $t('table.operation'), fixed: 'right', width: 160, slot: 'operation' },
|
{ label: $t('table.operation'), fixed: 'right', width: 160, slot: 'operation' },
|
||||||
|
|
|
@ -27,7 +27,7 @@ export function onAdd() {
|
||||||
width: '30%',
|
width: '30%',
|
||||||
props: {
|
props: {
|
||||||
formInline: {
|
formInline: {
|
||||||
type: 1,
|
type: -1,
|
||||||
amount: undefined,
|
amount: undefined,
|
||||||
description: undefined,
|
description: undefined,
|
||||||
transactionDate: dayjs(Date.now()).format('YYYY-MM-DD HH:mm:ss'),
|
transactionDate: dayjs(Date.now()).format('YYYY-MM-DD HH:mm:ss'),
|
||||||
|
|
|
@ -22,7 +22,7 @@ export async function onSearch() {
|
||||||
/** 添加分类信息 */
|
/** 添加分类信息 */
|
||||||
export function onAdd() {
|
export function onAdd() {
|
||||||
addDialog({
|
addDialog({
|
||||||
title: `${$t('addNew')}${$t('category-user')}`,
|
title: `${$t('addNew')}${$t('categoryUser')}`,
|
||||||
width: '30%',
|
width: '30%',
|
||||||
props: {
|
props: {
|
||||||
formInline: {
|
formInline: {
|
||||||
|
@ -50,7 +50,7 @@ export function onAdd() {
|
||||||
/** 更新分类信息 */
|
/** 更新分类信息 */
|
||||||
export function onUpdate(row: any) {
|
export function onUpdate(row: any) {
|
||||||
addDialog({
|
addDialog({
|
||||||
title: `${$t('modify')}${$t('category-user')}`,
|
title: `${$t('modify')}${$t('categoryUser')}`,
|
||||||
width: '30%',
|
width: '30%',
|
||||||
props: {
|
props: {
|
||||||
formInline: {
|
formInline: {
|
||||||
|
|
|
@ -112,7 +112,10 @@ defineExpose({ formRef });
|
||||||
<!-- 类别id -->
|
<!-- 类别id -->
|
||||||
<el-form-item :label="$t('category')" prop="categoryId">
|
<el-form-item :label="$t('category')" prop="categoryId">
|
||||||
<el-select v-model="form.categoryId" :placeholder="$t('select') + $t('category')" clearable filterable>
|
<el-select v-model="form.categoryId" :placeholder="$t('select') + $t('category')" clearable filterable>
|
||||||
<el-option v-for="item in categoryUserStore.allCategoryList" :key="item.id" :label="item.categoryName" :navigationBar="false" :value="item.id" />
|
<el-option v-for="item in categoryUserStore.allCategoryList" :key="item.id" :label="item.categoryName" :navigationBar="false" :value="item.id">
|
||||||
|
<el-text v-if="item.isBuiltin" effect="plain" size="large" type="info">{{ item.categoryName }}</el-text>
|
||||||
|
<el-text v-else effect="plain" size="large" type="success">{{ item.categoryName }}</el-text>
|
||||||
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue