修改优化
This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
:footer-style="{ textAlign: 'right' }"
|
||||
destroyOnClose
|
||||
@close="onClose">
|
||||
<div class="ns-form-title"><div class="title">{{text}}</div></div>
|
||||
<a-form
|
||||
ref="formRef"
|
||||
:model="formState"
|
||||
@@ -78,8 +79,9 @@
|
||||
const visible = ref(false);
|
||||
const formState = ref({});
|
||||
const formRef = ref();
|
||||
const labelCol = { span: 5 };
|
||||
const wrapperCol = { span: 19 };
|
||||
const labelCol = { span: 4 };
|
||||
const wrapperCol = { span: 20 };
|
||||
const text = ref('新增报告')
|
||||
const disabledDate = (current: moment.Moment | null) => {
|
||||
if (formState.value.reportPeriod === '2') {
|
||||
const year = current.year();
|
||||
@@ -140,6 +142,7 @@
|
||||
name: 'userAdd',
|
||||
type: 'primary',
|
||||
handle: () => {
|
||||
text.value = '新增报告'
|
||||
visible.value = true;
|
||||
},
|
||||
},
|
||||
@@ -183,6 +186,7 @@
|
||||
label: '编辑',
|
||||
name: 'userEdit',
|
||||
handle: (record: any) => {
|
||||
text.value = '编辑报告'
|
||||
visible.value = true;
|
||||
fetch(carbonInventoryCheck.findById, { id: record.id }).then((res) => {
|
||||
formState.value = res.data;
|
||||
@@ -274,4 +278,30 @@
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped></style>
|
||||
<style lang="less" scoped>
|
||||
.ns-form-title {
|
||||
font-weight: bold;
|
||||
user-select: text;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
.title {
|
||||
text-align: left;
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
font-weight: bold;
|
||||
user-select: text;
|
||||
position: relative;
|
||||
padding-left: 9px;
|
||||
}
|
||||
.title::before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
height: 13px;
|
||||
width: 3px;
|
||||
border-radius: 1px;
|
||||
background-color: #2778ff;
|
||||
}
|
||||
</style>
|
||||
|
Reference in New Issue
Block a user