需求新增

dev
吱屋 1 year ago
parent ed6b4d3abf
commit 9c49f1bd05
  1. 51
      ant-design-vue-jeecg/src/views/requirementitem/modules/RequirementItemForm.vue
  2. 10
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/requirementitem/entity/RequirementItem.java

@ -8,10 +8,23 @@
<j-dict-select-tag type="list" v-model="model.projectId" dictCode="projectx,project_name,id" placeholder="请选择项目" :disabled="disablecol" @change="getxqbm"/> <j-dict-select-tag type="list" v-model="model.projectId" dictCode="projectx,project_name,id" placeholder="请选择项目" :disabled="disablecol" @change="getxqbm"/>
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="24"> <!-- <a-col :span="24">
<a-form-model-item label="类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeId"> <a-form-model-item label="类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeId">
<j-dict-select-tag type="list" v-model="model.typeId" dictCode="requirement_type,type_name,id" placeholder="请选择类型" /> <j-dict-select-tag type="list" v-model="model.typeId" dictCode="requirement_type,type_name,id" placeholder="请选择类型" />
</a-form-model-item> </a-form-model-item>
</a-col> -->
<a-col :span="24">
<a-form-model-item label="类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="typeName">
<j-popup
v-model="model.typeName"
field="typeName"
org-fields="id,type_name"
dest-fields="typeId,typeName"
code="typename"
:multi="true"
@input="popupCallback"
/>
</a-form-model-item>
</a-col> </a-col>
<a-col :span="24" v-if="num===0"> <a-col :span="24" v-if="num===0">
<a-form-model-item label="上级需求" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="upperId"> <a-form-model-item label="上级需求" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="upperId">
@ -28,14 +41,19 @@
<a-input v-model="model.requirementName" placeholder="请输入中文名称" ></a-input> <a-input v-model="model.requirementName" placeholder="请输入中文名称" ></a-input>
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="24">
<a-form-model-item label="需求文件" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="requirementFile">
<j-upload v-model="model.requirementFile" ></j-upload>
</a-form-model-item>
</a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-model-item label="需求等级" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="requirementLevel"> <a-form-model-item label="需求等级" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="requirementLevel">
<j-dict-select-tag type="list" v-model="model.requirementLevel" dictCode="requirement_level" placeholder="请选择需求等级" /> <j-dict-select-tag type="radio" v-model="model.requirementLevel" dictCode="requirement_level" placeholder="请选择需求等级" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
<a-form-model-item label="需求状态" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="requirementStatus"> <a-form-model-item label="需求状态" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="requirementStatus">
<j-dict-select-tag type="list" v-model="model.requirementStatus" dictCode="requirement_status" placeholder="请选择需求状态" /> <j-dict-select-tag type="radio" v-model="model.requirementStatus" dictCode="requirement_status" placeholder="请选择需求状态" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="24"> <a-col :span="24">
@ -43,13 +61,11 @@
<j-image-upload isMultiple v-model="model.requirementPic" ></j-image-upload> <j-image-upload isMultiple v-model="model.requirementPic" ></j-image-upload>
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="24">
<a-form-model-item label="需求文件" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="requirementFile"> </a-row>
<j-upload v-model="model.requirementFile" ></j-upload> <a-row>
</a-form-model-item> <a-col>
</a-col> <a-form-model-item label="需求描述" :labelCol="labelCol1" :wrapperCol="wrapperCol1" prop="requirementDescribe">
<a-col :span="24">
<a-form-model-item label="需求描述" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="requirementDescribe">
<j-editor v-model="model.requirementDescribe" /> <j-editor v-model="model.requirementDescribe" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
@ -83,13 +99,21 @@
model:{ model:{
}, },
labelCol: { labelCol: {
xs: { span: 24 }, xs: { span: 23 },
sm: { span: 5 }, sm: { span: 6 },
}, },
wrapperCol: { wrapperCol: {
xs: { span: 24 }, xs: { span: 24 },
sm: { span: 16 }, sm: { span: 16 },
}, },
labelCol1: {
xs: { span: 24 },
sm: { span: 3 },
},
wrapperCol1: {
xs: { span: 24 },
sm: { span: 20 },
},
confirmLoading: false, confirmLoading: false,
validatorRules: { validatorRules: {
projectId: [ projectId: [
@ -127,6 +151,9 @@
//model //model
}, },
methods: { methods: {
popupCallback(value,row){
this.model = Object.assign(this.model, row);
},
getxqbm(){ getxqbm(){
if(this.model.upperId===undefined||this.model.upperId===null){ if(this.model.upperId===undefined||this.model.upperId===null){
this.model.upperId = ""; this.model.upperId = "";

@ -62,11 +62,15 @@ public class RequirementItem implements Serializable {
@Dict(dictTable = "projectx", dicText = "project_name", dicCode = "id") @Dict(dictTable = "projectx", dicText = "project_name", dicCode = "id")
@ApiModelProperty(value = "项目id") @ApiModelProperty(value = "项目id")
private java.lang.String projectId; private java.lang.String projectId;
/**类型id*/ /**类型id*/
@Excel(name = "类型id", width = 15, dictTable = "requirement_type", dicText = "type_name", dicCode = "id") @Excel(name = "类型id", width = 15, dictTable = "requirement_type", dicText = "type_name", dicCode = "id")
@Dict(dictTable = "requirement_type", dicText = "type_name", dicCode = "id") @Dict(dictTable = "requirement_type", dicText = "type_name", dicCode = "id")
@ApiModelProperty(value = "类型id") @ApiModelProperty(value = "类型id")
private java.lang.String typeId; private java.lang.String typeId;
/**类型*/
@Excel(name = "类型", width = 15)
@ApiModelProperty(value = "类型")
private java.lang.String typeName;
/**上级需求id*/ /**上级需求id*/
@Excel(name = "上级需求id", width = 15) @Excel(name = "上级需求id", width = 15)
@ApiModelProperty(value = "上级需求id") @ApiModelProperty(value = "上级需求id")

Loading…
Cancel
Save