perf: 优化代码生成vue模板 #23
This commit is contained in:
@@ -35,12 +35,13 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-date-picker clearable
|
<el-date-picker
|
||||||
v-model="queryParams.{{ column.python_field }}"
|
v-model="queryParams.{{ column.python_field }}"
|
||||||
type="date"
|
type="date"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
placeholder="请选择{{ comment }}">
|
placeholder="请选择{{ comment }}"
|
||||||
</el-date-picker>
|
clearable
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}">
|
<el-form-item label="{{ comment }}">
|
||||||
@@ -52,7 +53,7 @@
|
|||||||
range-separator="-"
|
range-separator="-"
|
||||||
start-placeholder="开始日期"
|
start-placeholder="开始日期"
|
||||||
end-placeholder="结束日期"
|
end-placeholder="结束日期"
|
||||||
></el-date-picker>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@@ -35,12 +35,13 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-date-picker clearable
|
<el-date-picker
|
||||||
v-model="queryParams.{{ column.python_field }}"
|
v-model="queryParams.{{ column.python_field }}"
|
||||||
type="date"
|
type="date"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
placeholder="请选择{{ comment }}">
|
placeholder="请选择{{ comment }}"
|
||||||
</el-date-picker>
|
clearable
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}">
|
<el-form-item label="{{ comment }}">
|
||||||
@@ -52,7 +53,7 @@
|
|||||||
range-separator="-"
|
range-separator="-"
|
||||||
start-placeholder="开始日期"
|
start-placeholder="开始日期"
|
||||||
end-placeholder="结束日期"
|
end-placeholder="结束日期"
|
||||||
></el-date-picker>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@@ -13,12 +13,13 @@
|
|||||||
v-model="queryParams.{{ column.python_field }}"
|
v-model="queryParams.{{ column.python_field }}"
|
||||||
placeholder="请输入{{ comment }}"
|
placeholder="请输入{{ comment }}"
|
||||||
clearable
|
clearable
|
||||||
|
style="width: 240px"
|
||||||
@keyup.enter="handleQuery"
|
@keyup.enter="handleQuery"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif (column.html_type == "select" or column.html_type == "radio") and dictType %}
|
{% elif (column.html_type == "select" or column.html_type == "radio") and dictType %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable>
|
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable style="width: 240px">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="dict in {{ dictType }}"
|
v-for="dict in {{ dictType }}"
|
||||||
:key="dict.value"
|
:key="dict.value"
|
||||||
@@ -29,18 +30,20 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif (column.html_type == "select" or column.html_type == "radio") and not dictType %}
|
{% elif (column.html_type == "select" or column.html_type == "radio") and not dictType %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable>
|
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable style="width: 240px">
|
||||||
<el-option label="请选择字典生成" value="" />
|
<el-option label="请选择字典生成" value="" />
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-date-picker clearable
|
<el-date-picker
|
||||||
v-model="queryParams.{{ column.python_field }}"
|
v-model="queryParams.{{ column.python_field }}"
|
||||||
type="date"
|
type="date"
|
||||||
value-format="YYYY-MM-DD"
|
value-format="YYYY-MM-DD"
|
||||||
placeholder="请选择{{ comment }}">
|
placeholder="请选择{{ comment }}"
|
||||||
</el-date-picker>
|
clearable
|
||||||
|
style="width: 240px"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}" style="width: 308px">
|
<el-form-item label="{{ comment }}" style="width: 308px">
|
||||||
@@ -51,7 +54,8 @@
|
|||||||
range-separator="-"
|
range-separator="-"
|
||||||
start-placeholder="开始日期"
|
start-placeholder="开始日期"
|
||||||
end-placeholder="结束日期"
|
end-placeholder="结束日期"
|
||||||
></el-date-picker>
|
style="width: 240px"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@@ -13,12 +13,13 @@
|
|||||||
v-model="queryParams.{{ column.python_field }}"
|
v-model="queryParams.{{ column.python_field }}"
|
||||||
placeholder="请输入{{ comment }}"
|
placeholder="请输入{{ comment }}"
|
||||||
clearable
|
clearable
|
||||||
|
style="width: 240px"
|
||||||
@keyup.enter="handleQuery"
|
@keyup.enter="handleQuery"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif (column.html_type == "select" or column.html_type == "radio") and dictType %}
|
{% elif (column.html_type == "select" or column.html_type == "radio") and dictType %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable>
|
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable style="width: 240px">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="dict in {{ dictType }}"
|
v-for="dict in {{ dictType }}"
|
||||||
:key="dict.value"
|
:key="dict.value"
|
||||||
@@ -29,18 +30,20 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif (column.html_type == "select" or column.html_type == "radio") and not dictType %}
|
{% elif (column.html_type == "select" or column.html_type == "radio") and not dictType %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable>
|
<el-select v-model="queryParams.{{ column.python_field }}" placeholder="请选择{{ comment }}" clearable style="width: 240px">
|
||||||
<el-option label="请选择字典生成" value="" />
|
<el-option label="请选择字典生成" value="" />
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type != "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
<el-form-item label="{{ comment }}" prop="{{ column.python_field }}">
|
||||||
<el-date-picker clearable
|
<el-date-picker
|
||||||
v-model="queryParams.{{ column.python_field }}"
|
v-model="queryParams.{{ column.python_field }}"
|
||||||
type="date"
|
type="date"
|
||||||
value-format="YYYY-MM-DD"
|
value-format="YYYY-MM-DD"
|
||||||
placeholder="请选择{{ comment }}">
|
placeholder="请选择{{ comment }}"
|
||||||
</el-date-picker>
|
clearable
|
||||||
|
style="width: 240px"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
{% elif column.html_type == "datetime" and column.query_type == "BETWEEN" %}
|
||||||
<el-form-item label="{{ comment }}" style="width: 308px">
|
<el-form-item label="{{ comment }}" style="width: 308px">
|
||||||
@@ -51,7 +54,8 @@
|
|||||||
range-separator="-"
|
range-separator="-"
|
||||||
start-placeholder="开始日期"
|
start-placeholder="开始日期"
|
||||||
end-placeholder="结束日期"
|
end-placeholder="结束日期"
|
||||||
></el-date-picker>
|
style="width: 240px"
|
||||||
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
Reference in New Issue
Block a user