提交修改文件2:1、2、13文件1:2、3、4
This commit is contained in:
parent
31d5cf81d9
commit
d0a2e3d94b
|
@ -285,6 +285,10 @@ import { datasyncqueryPage,
|
||||||
this.form.validateFields((err, values) => {
|
this.form.validateFields((err, values) => {
|
||||||
console.log('values',values)
|
console.log('values',values)
|
||||||
this.datamodel = values;
|
this.datamodel = values;
|
||||||
|
if(this.datamodel.database==null){
|
||||||
|
this.$message.warning("源数据库未选择");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
var that = this;
|
var that = this;
|
||||||
if (!err) {
|
if (!err) {
|
||||||
that.confirmLoading = true;
|
that.confirmLoading = true;
|
||||||
|
@ -349,6 +353,22 @@ import { datasyncqueryPage,
|
||||||
this.form.validateFields((err, values) => {
|
this.form.validateFields((err, values) => {
|
||||||
console.log('values',values)
|
console.log('values',values)
|
||||||
this.datamodel = values;
|
this.datamodel = values;
|
||||||
|
if(this.datamodel.shipModel==null){
|
||||||
|
this.$message.warning("型号必须选择");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if(this.datamodel.shipNum==null){
|
||||||
|
this.$message.warning("舷号必须选择");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if(this.datamodel.dataType==null){
|
||||||
|
this.$message.warning("数据类型必须选择");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if(this.datamodel.dbType==null){
|
||||||
|
this.$message.warning("数据类型必须选择");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
var that = this;
|
var that = this;
|
||||||
if (!err) {
|
if (!err) {
|
||||||
that.confirmLoading = true;
|
that.confirmLoading = true;
|
||||||
|
|
|
@ -134,6 +134,13 @@ export default {
|
||||||
handleOk() {
|
handleOk() {
|
||||||
this.$refs.ruleForm.validate(valid => {
|
this.$refs.ruleForm.validate(valid => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
|
if(this.form.maxVal < this.form.minVal){
|
||||||
|
this.$notification.error({
|
||||||
|
message: '系统提示',
|
||||||
|
description: '最大值不可小于最小值'
|
||||||
|
})
|
||||||
|
return false;
|
||||||
|
}
|
||||||
this.confirmLoading = true;
|
this.confirmLoading = true;
|
||||||
if (!this.form.id) {
|
if (!this.form.id) {
|
||||||
createRules(this.form).then(res => {
|
createRules(this.form).then(res => {
|
||||||
|
|
|
@ -182,11 +182,12 @@
|
||||||
deleteAllFile({}).then((res) => {
|
deleteAllFile({}).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
this.$message.success(res.result);
|
this.$message.success(res.result);
|
||||||
|
this.ipagination.total = 0;
|
||||||
|
this.ipagination.current = 1;
|
||||||
} else {
|
} else {
|
||||||
this.$message.warning(res.message);
|
this.$message.warning(res.message);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.loadData()
|
|
||||||
this.$refs.modalForm.open();
|
this.$refs.modalForm.open();
|
||||||
},
|
},
|
||||||
initWebSocket: function () {
|
initWebSocket: function () {
|
||||||
|
|
|
@ -15,7 +15,8 @@
|
||||||
<a-input v-decorator="['name',{
|
<a-input v-decorator="['name',{
|
||||||
rules: [
|
rules: [
|
||||||
{ required: true, message: '任务名称不能为空' },
|
{ required: true, message: '任务名称不能为空' },
|
||||||
{ min: 0, max: 30, message: '长度0-30位' }
|
{ min: 0, max: 30, message: '长度0-30位' },
|
||||||
|
{ pattern:new RegExp('^[\u4e00-\u9fa5a-zA-Z0-9]+$','g'),message:'只允许包含数字、字母、中文'},
|
||||||
],
|
],
|
||||||
validateTrigger: 'blur'
|
validateTrigger: 'blur'
|
||||||
}]" ></a-input>
|
}]" ></a-input>
|
||||||
|
|
|
@ -19,7 +19,9 @@
|
||||||
</a-row>
|
</a-row>
|
||||||
</a-form>
|
</a-form>
|
||||||
</div>
|
</div>
|
||||||
<a-table ref="table" size="middle" style="height:calc(100vh - 343px);background:#e6e9f1;padding: 10px;" bordered rowKey="id" :columns="columns" :dataSource="dataSource" @change="handleTableChange">
|
<a-table ref="table" size="middle" style="height:calc(100vh - 343px);background:#e6e9f1;padding: 10px;" bordered rowKey="id"
|
||||||
|
:custom-row="handleCustomRow"
|
||||||
|
:columns="columns" :dataSource="dataSource" @change="handleTableChange">
|
||||||
<span slot="action" slot-scope="text, record">
|
<span slot="action" slot-scope="text, record">
|
||||||
<a @click="handleEdit(record)">选中</a>
|
<a @click="handleEdit(record)">选中</a>
|
||||||
</span>
|
</span>
|
||||||
|
@ -164,7 +166,8 @@ export default {
|
||||||
fileLinkCount: 0
|
fileLinkCount: 0
|
||||||
},
|
},
|
||||||
cleaningVariancesource: [],
|
cleaningVariancesource: [],
|
||||||
totalNumberCataloguesData: []
|
totalNumberCataloguesData: [],
|
||||||
|
selectedRowId :null
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
@ -179,6 +182,17 @@ export default {
|
||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleCustomRow(record) {
|
||||||
|
return {
|
||||||
|
onClick: () => {
|
||||||
|
console.log(record.id)
|
||||||
|
this.selectedRowId = record.id;
|
||||||
|
},
|
||||||
|
class: {
|
||||||
|
'row-highlight': this.selectedRowId === record.id
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
handleTableChange(pagination, filters, sorter) {
|
handleTableChange(pagination, filters, sorter) {
|
||||||
if (Object.keys(sorter).length > 0) {
|
if (Object.keys(sorter).length > 0) {
|
||||||
this.isorter.column = sorter.field;
|
this.isorter.column = sorter.field;
|
||||||
|
@ -189,6 +203,7 @@ export default {
|
||||||
},
|
},
|
||||||
handleEdit(value) {
|
handleEdit(value) {
|
||||||
this.cleaningVariancesource = [];
|
this.cleaningVariancesource = [];
|
||||||
|
this.selectedRowId = value.id;
|
||||||
getDataAnalysis({ taskId: value.id, startDate: value.startTime, endDate: value.endTime }).then((res) => {
|
getDataAnalysis({ taskId: value.id, startDate: value.startTime, endDate: value.endTime }).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
res.result.schemaNames.forEach(row => {
|
res.result.schemaNames.forEach(row => {
|
||||||
|
@ -326,7 +341,10 @@ export default {
|
||||||
.quarter-div .datanum {
|
.quarter-div .datanum {
|
||||||
font-size: 26px;
|
font-size: 26px;
|
||||||
}
|
}
|
||||||
|
/* 高亮样式 */
|
||||||
|
/deep/.row-highlight {
|
||||||
|
background-color: #ffffff !important;
|
||||||
|
}
|
||||||
.quarter-div .ant-col-8,
|
.quarter-div .ant-col-8,
|
||||||
.quarter-div .ant-col-10 {
|
.quarter-div .ant-col-10 {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user