Commit 1ad73ab7 authored by 骆瑛's avatar 骆瑛

修改项目管理字段

parent 16b2f89a
......@@ -1229,17 +1229,17 @@ export default {
isDeleted: '删除人',
deletionTime: '删除时间',
deleterUserId: '删除人',
name: '分类名称',
name: '名称',
upId: '上级id',
level: '层级',
tenantId: '租户id',
type: '类别',
englishFullName: '英文全称',
englishName: '英文简称',
englishFullName: '命名空间',
englishName: '实体名',
status: '状态',
description: '描述',
inheritCategoryId: '继承分类id',
code: '编码',
code: '表名',
module: '模块',
},
project_atom: {
......@@ -1265,5 +1265,6 @@ export default {
module: '模块',
version: '版本',
projectId: '项目id',
systemName: "系统业务"
}
}
\ No newline at end of file
This diff is collapsed.
......@@ -156,7 +156,7 @@
>删除</a>
</template>
</Table>
<Button type="dashed" long @click="addNew('{}')" class="mt10"
<Button type="dashed" long @click="addNew(0,'{}')" class="mt10"
>新增属性</Button
>
</Col>
......@@ -266,7 +266,7 @@ export default {
this.completeValue = "";
}
});
this.addNew(changeId);
this.addNew(1,changeId);
}
},
upClick(value) {
......@@ -314,18 +314,21 @@ export default {
setRow(row, index) {
this.$set(this.checkList, index, row);
},
addNew(e) {
let id = "",
addNew(index,e) {
let id = "",
code = "",
name = "";
if (e == "{}") {
if (index == 0 && e=='{}') {
id = "";
code = "";
name = "";
} else {
} else if(index == 1 && JSON.stringify(e)!='{}'){
id = e.id;
code = e.code;
name = e.name;
}else{
this.$Message.warning("请选择导入字段!");
return;
}
let maxId = 0;
this.checkList.map((u) => {
......
......@@ -21,7 +21,8 @@
<Button type="primary" @click="add">新增</Button>
</template>
</DataGrid>
<Modal v-model="modal" :title="title" width="1200" footer-hide>
<!-- fullscreen -->
<Modal v-model="modal" :title="title" width="1200" footer-hide fullscreen >
<component :is="detail" :eid="curId" @on-close="cancel" @on-ok="ok" />
</Modal>
</div>
......
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<!-- <Col :span="12"
><FormItem :label="l('creationTime')" prop="creationTime">
<DatePicker
type="date"
v-model="entity.creationTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('creatorUserId')" prop="creatorUserId">
<InputNumber v-model="entity.creatorUserId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem
:label="l('lastModificationTime')"
prop="lastModificationTime"
>
<DatePicker
type="date"
v-model="entity.lastModificationTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('lastModifierUserId')" prop="lastModifierUserId">
<InputNumber
v-model="entity.lastModifierUserId"
></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('isDeleted')" prop="isDeleted">
<InputNumber v-model="entity.isDeleted"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('deletionTime')" prop="deletionTime">
<DatePicker
type="date"
v-model="entity.deletionTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('deleterUserId')" prop="deleterUserId">
<InputNumber v-model="entity.deleterUserId"></InputNumber> </FormItem
></Col> -->
<Col :span="12"
><FormItem :label="l('name')" prop="name">
<Input v-model="entity.name"> </Input> </FormItem
></Col>
<Col :span="12">
<FormItem :label="l('code')" prop="code">
<Input v-model="entity.code"> </Input> </FormItem
>
<Input v-model="entity.code"> </Input> </FormItem>
</Col>
<Col :span="12">
<!-- <FormItem :label="l('type')" prop="type">
<Input v-model="entity.type"> </Input> </FormItem
> -->
<FormItem :label="l('type')" prop="type">
<Dictionary code="base.project.type" v-model="entity.type" ></Dictionary>
</FormItem>
</Col>
<!-- <Col :span="12"
><FormItem :label="l('level')" prop="level">
<Input v-model="entity.level"> </Input> </FormItem
></Col> -->
<Col :span="12"
><FormItem :label="l('englishFullName')" prop="englishFullName">
<Input v-model="entity.englishFullName"> </Input> </FormItem
......@@ -74,9 +23,6 @@
<Input v-model="entity.englishName"> </Input> </FormItem
></Col>
<Col :span="12">
<!-- <FormItem :label="l('status')" prop="status">
<Input v-model="entity.status"> </Input> </FormItem
> -->
<FormItem :label="l('status')" prop="status">
<Dictionary code="base.project.status" v-model="entity.status" ></Dictionary>
</FormItem>
......@@ -85,22 +31,6 @@
><FormItem :label="l('module')" prop="module">
<Input v-model="entity.module"> </Input> </FormItem
></Col>
<!-- <Col :span="12"
><FormItem :label="l('upId')" prop="upId">
<InputNumber v-model="entity.upId"></InputNumber> </FormItem
></Col> -->
<!--
<Col :span="12"
><FormItem :label="l('tenantId')" prop="tenantId">
<InputNumber v-model="entity.tenantId"></InputNumber> </FormItem
></Col> -->
<!-- <Col :span="12"
><FormItem :label="l('inheritCategoryId')" prop="inheritCategoryId">
<InputNumber
v-model="entity.inheritCategoryId"
></InputNumber> </FormItem
></Col> -->
<Col :span="24"
><FormItem :label="l('description')" prop="description">
<Input
......@@ -111,9 +41,7 @@
></Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled"
>保存</Button
>
<Button type="primary" @click="handleSubmit" :disabled="disabled" >保存</Button >
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
......@@ -126,13 +54,6 @@ export default {
return {
disabled: false,
entity: {
// creationTime: null,
// creatorUserId: null,
// lastModificationTime: null,
// lastModifierUserId: null,
// isDeleted: null,
// deletionTime: null,
// deleterUserId: null,
name: "",
upId: this.eid,
level: null,
......
<template>
<div class="detail">
<Row>
<Filed :span="12" :name="l('creationTime')">{{entity.creationTime}}</Filed>
<Filed :span="12" :name="l('creatorUserId')">{{entity.creatorUserId}}</Filed>
<Filed :span="12" :name="l('lastModificationTime')">{{entity.lastModificationTime}}</Filed>
<Filed :span="12" :name="l('lastModifierUserId')">{{entity.lastModifierUserId}}</Filed>
<Filed :span="12" :name="l('isDeleted')">{{entity.isDeleted}}</Filed>
<Filed :span="12" :name="l('deletionTime')">{{entity.deletionTime}}</Filed>
<Filed :span="12" :name="l('deleterUserId')">{{entity.deleterUserId}}</Filed>
<Filed :span="12" :name="l('name')">{{entity.name}}</Filed>
<Filed :span="12" :name="l('upId')">{{entity.upId}}</Filed>
<Filed :span="12" :name="l('level')">{{entity.level}}</Filed>
<Filed :span="12" :name="l('tenantId')">{{entity.tenantId}}</Filed>
<Filed :span="12" :name="l('type')">{{entity.type}}</Filed>
<Filed :span="12" :name="l('englishFullName')">{{entity.englishFullName}}</Filed>
<Filed :span="12" :name="l('englishName')">{{entity.englishName}}</Filed>
<Filed :span="12" :name="l('status')">{{entity.status}}</Filed>
<Filed :span="24" :name="l('description')">{{entity.description}}</Filed>
<Filed :span="12" :name="l('inheritCategoryId')">{{entity.inheritCategoryId}}</Filed>
<Filed :span="12" :name="l('code')">{{entity.code}}</Filed>
<Filed :span="12" :name="l('module')">{{entity.module}}</Filed>
</Row>
</div>
<div class="detail">
<Row>
<Filed :span="12" :name="l('name')">{{ entity.name }}</Filed>
<Filed :span="12" :name="l('type')"><state code="base.project.type" :value="entity.type" /></Filed>
<Filed :span="12" :name="l('englishFullName')">{{
entity.englishFullName
}}</Filed>
<Filed :span="12" :name="l('englishName')">{{
entity.englishName
}}</Filed>
<Filed :span="12" :name="l('status')"><state code="base.project.status" :value="entity.status" /></Filed>
<Filed :span="12" :name="l('code')"> {{ entity.code }}</Filed>
<Filed :span="12" :name="l('module')">{{ entity.module }}</Filed>
<Filed :span="24" :name="l('description')">{{ entity.description }}</Filed>
</Row>
</div>
</template>
<script>
import Api from './api'
export default {
name: 'Add',
data() {
return {
entity: {},
rules: {
name: [{ required: true, message: '必填', trigger: 'blur' }],
code: [{ required: true, message: '必填', trigger: 'blur' }]
}
}
},
props: {
eid: Number
},
mounted() {
if (this.eid > 0) {
this.load(this.eid);
}
},
methods: {
load(v) {
Api.get({ id: v }).then(r => {
this.entity = r.result;
this.$emit('on-load')
})
},
handleClose() {
this.$emit('on-close')
},
l(key) {
key = "project" + "." + key;
return this.$t(key)
}
},
watch: {
eid(v) {
if (v > 0) {
this.load(v);
}
}
}
import Api from "./api";
export default {
name: "Add",
data() {
return {
entity: {},
rules: {
name: [{ required: true, message: "必填", trigger: "blur" }],
code: [{ required: true, message: "必填", trigger: "blur" }],
},
};
},
props: {
eid: Number,
},
mounted() {
if (this.eid > 0) {
this.load(this.eid);
}
},
methods: {
load(v) {
Api.get({ id: v }).then((r) => {
this.entity = r.result;
this.$emit("on-load");
});
},
handleClose() {
this.$emit("on-close");
},
l(key) {
key = "project" + "." + key;
return this.$t(key);
},
},
watch: {
eid(v) {
if (v > 0) {
this.load(v);
}
},
},
};
</script>
\ No newline at end of file
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<!-- <Col :span="12"
><FormItem :label="l('creationTime')" prop="creationTime">
<DatePicker
type="date"
v-model="entity.creationTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('creatorUserId')" prop="creatorUserId">
<InputNumber v-model="entity.creatorUserId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem
:label="l('lastModificationTime')"
prop="lastModificationTime"
>
<DatePicker
type="date"
v-model="entity.lastModificationTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('lastModifierUserId')" prop="lastModifierUserId">
<InputNumber
v-model="entity.lastModifierUserId"
></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('isDeleted')" prop="isDeleted">
<InputNumber v-model="entity.isDeleted"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('deletionTime')" prop="deletionTime">
<DatePicker
type="date"
v-model="entity.deletionTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('deleterUserId')" prop="deleterUserId">
<InputNumber v-model="entity.deleterUserId"></InputNumber> </FormItem
></Col> -->
<Col :span="12"
><FormItem :label="l('name')" prop="name">
<Input v-model="entity.name"> </Input> </FormItem
></Col>
<Col :span="12"
<Col :span="12"
><FormItem :label="l('code')" prop="code">
<Input v-model="entity.code"> </Input> </FormItem
></Col>
<Col :span="12">
<FormItem :label="l('type')" prop="type">
<Dictionary code="base.project.type" v-model="entity.type" ></Dictionary>
<FormItem :label="l('type')" prop="type">
<Dictionary
code="base.project.type"
v-model="entity.type"
></Dictionary>
</FormItem>
</Col>
<!-- <Col :span="12"
><FormItem :label="l('level')" prop="level">
<Input v-model="entity.level"> </Input> </FormItem
></Col> -->
<Col :span="12"
><FormItem :label="l('englishFullName')" prop="englishFullName">
<Input v-model="entity.englishFullName"> </Input> </FormItem
......@@ -68,32 +25,18 @@
><FormItem :label="l('englishName')" prop="englishName">
<Input v-model="entity.englishName"> </Input> </FormItem
></Col>
<Col :span="12"
>
<FormItem :label="l('status')" prop="status">
<Dictionary code="base.project.status" v-model="entity.status" ></Dictionary>
<Col :span="12">
<FormItem :label="l('status')" prop="status">
<Dictionary
code="base.project.status"
v-model="entity.status"
></Dictionary>
</FormItem>
</Col>
<Col :span="12"
<Col :span="12"
><FormItem :label="l('module')" prop="module">
<Input v-model="entity.module"> </Input> </FormItem
></Col>
<!-- <Col :span="12"
><FormItem :label="l('upId')" prop="upId">
<InputNumber v-model="entity.upId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('tenantId')" prop="tenantId">
<InputNumber v-model="entity.tenantId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('inheritCategoryId')" prop="inheritCategoryId">
<InputNumber
v-model="entity.inheritCategoryId"
></InputNumber> </FormItem
></Col> -->
<Col :span="24"
><FormItem :label="l('description')" prop="description">
<Input
......@@ -142,9 +85,14 @@ export default {
this.$refs.form.validate((v) => {
if (v) {
this.disabled = true;
let datas={
let datas = {
creationTime: this.entity.creationTime,
creatorUserId: this.entity.creatorUserId,
description: this.entity.description,
code: this.entity.code,
id: this.entity.id,
englishFullName: this.entity.englishFullName,
englishName: this.entity.englishName,
inheritCategoryId: this.entity.inheritCategoryId,
lastModificationTime: this.entity.lastModificationTime,
lastModifierUserId: this.entity.lastModifierUserId,
......@@ -153,9 +101,9 @@ export default {
name: this.entity.name,
status: this.entity.status,
tenantId: this.entity.tenantId,
type:this.entity.type,
upId: this.entity.upId
}
type: this.entity.type,
upId: this.entity.upId,
};
Api.update(datas)
.then((r) => {
this.disabled = false;
......
<template>
<div style="padding-top: 10px">
<TreeGrid :columns="columns" :items="treeData" ref="grid">
<!-- <DataGrid :columns="columns" :action="action" > -->
<template slot="easySearch"
><Form ref="formInline" :model="easySearch" inline
><FormItem prop="keys"
......@@ -22,7 +21,6 @@
<Button type="primary" @click="add">新增</Button>
</template>
</TreeGrid>
<!-- </DataGrid> -->
<Modal v-model="modal" :title="title" width="1200" footer-hide>
<component :is="detail" :eid="curId" @on-close="cancel" @on-ok="ok" />
</Modal>
......@@ -54,55 +52,6 @@ export default {
detail: null,
curId: 0,
columns: [
// {
// key: "id",
// title: this.$t("id"),
// hide: false,
// align: "left",
// high: true,
// },
// {
// key: "creationTime",
// title: this.l("creationTime"),
// align: "left",
// high: true,
// },
// {
// key: "creatorUserId",
// title: this.l("creatorUserId"),
// align: "left",
// high: true,
// },
// {
// key: "lastModificationTime",
// title: this.l("lastModificationTime"),
// align: "left",
// high: true,
// },
// {
// key: "lastModifierUserId",
// title: this.l("lastModifierUserId"),
// align: "left",
// high: true,
// },
// {
// key: "isDeleted",
// title: this.l("isDeleted"),
// align: "left",
// high: true,
// },
// {
// key: "deletionTime",
// title: this.l("deletionTime"),
// align: "left",
// high: true,
// },
// {
// key: "deleterUserId",
// title: this.l("deleterUserId"),
// align: "left",
// high: true,
// },
{
key: "label",
title: "分类名称",
......@@ -116,25 +65,29 @@ export default {
easy: true,
high: true,
},
// { key: "upId", title: this.l("upId"), align: "left", high: true },
// { key: "level", title: this.l("level"), align: "left", high: true },
// {
// key: "tenantId",
// title: this.l("tenantId"),
// align: "left",
// high: true,
// },
{
{
key: "code",
title: this.l("code"),
align: "left",
code: "project.base.code",
easy: true,
high: true,
},
{ key: "type", title: this.l("type"), align: "left", high: true ,code: "base.project.type"},
{ key: "status", title: this.l("status"), align: "left", high: true ,code: "base.project.status"},
{
key: "type",
title: this.l("type"),
align: "left",
high: true,
code: "base.project.type",
},
{
key: "status",
title: this.l("status"),
align: "left",
high: true,
code: "base.project.status",
},
{
key: "englishFullName",
title: this.l("englishFullName"),
......@@ -149,13 +102,6 @@ export default {
easy: true,
high: true,
},
// {
// key: "inheritCategoryId",
// title: this.l("inheritCategoryId"),
// align: "left",
// high: true,
// },
{ key: "module", title: this.l("module"), align: "left", high: true },
{
title: "操作",
......@@ -224,7 +170,6 @@ export default {
},
"upId"
);
console.log(this.treeData);
});
},
ok() {
......@@ -233,7 +178,10 @@ export default {
this.curId = 0;
},
search() {
this.$refs.grid.reload(this.easySearch);
console.log(this.easySearch);
console.log(this.$refs.grid);
// this.init();
// this.$refs.grid.reload(this.easySearch);
},
add() {
this.curId = 0;
......@@ -301,5 +249,4 @@ export default {
},
};
</script>
<style lang="less">
</style>
\ No newline at end of file
<style lang="less"></style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment