首页模块修改-查询部分修改
This commit is contained in:
parent
8117affa71
commit
266edb37e6
|
|
@ -21,3 +21,9 @@ export const queryContactUnitsListApi = (data) => {
|
||||||
params: data
|
params: data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
/** 往来单位列表查询-下拉选 */
|
||||||
|
export const queryContactUnitsSelApi = (data) => {
|
||||||
|
return request.get('/base/customer/getUnitInfoSelect', {
|
||||||
|
params: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -21,3 +21,9 @@ export const queryProjectListApi = (data) => {
|
||||||
params: data
|
params: data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
/** 工程列表查询-下拉选 */
|
||||||
|
export const queryProjectSelApi = (data) => {
|
||||||
|
return request.get('/base/project/getProjectSelect', {
|
||||||
|
params: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -52,10 +52,7 @@
|
||||||
v-model="queryParams[item.f_model]"
|
v-model="queryParams[item.f_model]"
|
||||||
style="width: 240px"
|
style="width: 240px"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
type="daterange"
|
type="date"
|
||||||
range-separator="-"
|
|
||||||
start-placeholder="开始日期"
|
|
||||||
end-placeholder="结束日期"
|
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
|
|
|
||||||
|
|
@ -72,9 +72,9 @@ export const constantRoutes = [
|
||||||
name: 'Index',
|
name: 'Index',
|
||||||
meta: { title: '首页', icon: 'dashboard', affix: true }
|
meta: { title: '首页', icon: 'dashboard', affix: true }
|
||||||
},
|
},
|
||||||
{
|
/* {
|
||||||
path: 'ProjectManage',
|
path: 'ProjectManage',
|
||||||
component: () => import('@/views/base/project'),
|
component: () => import('@/views/base/project'),
|
||||||
name: 'ProjectManage',
|
name: 'ProjectManage',
|
||||||
meta: { title: '工程管理', icon: 'dashboard', affix: true }
|
meta: { title: '工程管理', icon: 'dashboard', affix: true }
|
||||||
},
|
},
|
||||||
|
|
@ -95,7 +95,7 @@ export const constantRoutes = [
|
||||||
component: () => import('@/views/base/agreement'),
|
component: () => import('@/views/base/agreement'),
|
||||||
name: 'ProtocolManage',
|
name: 'ProtocolManage',
|
||||||
meta: { title: '协议管理', icon: 'dashboard', affix: true }
|
meta: { title: '协议管理', icon: 'dashboard', affix: true }
|
||||||
}
|
} */
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -13,9 +13,15 @@ export const commonMixin = {
|
||||||
this.dialogConfig.outerVisible = true
|
this.dialogConfig.outerVisible = true
|
||||||
},
|
},
|
||||||
/** 删除 */
|
/** 删除 */
|
||||||
handleDeleteData(data) {
|
handleDeleteData(id) {
|
||||||
this.$modal.confirm('是否确定删除').then(() => {
|
this.$modal.confirm('是否确定删除').then(() => {
|
||||||
console.log('确定删除--')
|
console.log('确定删除--', id)
|
||||||
|
/* deleteProjectApi(id).then(res => {
|
||||||
|
console.log(res)
|
||||||
|
history.go(0)
|
||||||
|
}).catch(err => {
|
||||||
|
console.log(err)
|
||||||
|
}) */
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
/** 编辑 */
|
/** 编辑 */
|
||||||
|
|
@ -46,4 +52,4 @@ export const commonMixin = {
|
||||||
this.dialogConfig.outerVisible = false
|
this.dialogConfig.outerVisible = false
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,17 @@
|
||||||
<el-row type="flex" justify="space-between" :gutter="24">
|
<el-row type="flex" justify="space-between" :gutter="24">
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="租赁单位" prop="customer">
|
<el-form-item label="租赁单位" prop="customer">
|
||||||
<el-input v-model="protocolParams.customer" />
|
<el-select
|
||||||
|
v-model="protocolParams.customer"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in unitSelRange"
|
||||||
|
:key="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
|
|
@ -26,7 +36,15 @@
|
||||||
<el-form-item label="租赁工程" prop="project">
|
<el-form-item label="租赁工程" prop="project">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="protocolParams.project"
|
v-model="protocolParams.project"
|
||||||
></el-select>
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in projSelRange"
|
||||||
|
:key="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
|
|
@ -38,9 +56,7 @@
|
||||||
<el-row :gutter="24">
|
<el-row :gutter="24">
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="合同编号" prop="contractNumber">
|
<el-form-item label="合同编号" prop="contractNumber">
|
||||||
<el-select
|
<el-input v-model="protocolParams.contractNumber" />
|
||||||
v-model="protocolParams.contractNumber"
|
|
||||||
></el-select>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<!-- <el-col :span="12">
|
<!-- <el-col :span="12">
|
||||||
|
|
@ -92,6 +108,12 @@ import {
|
||||||
addProtocolApi,
|
addProtocolApi,
|
||||||
editProtocolApi
|
editProtocolApi
|
||||||
} from '@/api/base/agreement'
|
} from '@/api/base/agreement'
|
||||||
|
import {
|
||||||
|
queryContactUnitsSelApi
|
||||||
|
} from '@/api/base/customer'
|
||||||
|
import {
|
||||||
|
queryProjectSelApi
|
||||||
|
} from '@/api/base/project'
|
||||||
import { addProjectApi, editProjectApi } from '@/api/base/project'
|
import { addProjectApi, editProjectApi } from '@/api/base/project'
|
||||||
export default {
|
export default {
|
||||||
name: 'FormProtocol',
|
name: 'FormProtocol',
|
||||||
|
|
@ -101,6 +123,10 @@ export default {
|
||||||
default: () => null,
|
default: () => null,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
created() {
|
||||||
|
this.queryUnitSel()
|
||||||
|
this.queryProjSel()
|
||||||
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
if (this.editParams) {
|
if (this.editParams) {
|
||||||
Object.assign(this.protocolParams, this.editParams)
|
Object.assign(this.protocolParams, this.editParams)
|
||||||
|
|
@ -122,6 +148,10 @@ export default {
|
||||||
remark: '', // 备注
|
remark: '', // 备注
|
||||||
url: '', // 合同附件
|
url: '', // 合同附件
|
||||||
},
|
},
|
||||||
|
// 租赁单位下拉框
|
||||||
|
unitSelRange: [],
|
||||||
|
// 租赁工程下拉框
|
||||||
|
projSelRange: [],
|
||||||
// 校验规则
|
// 校验规则
|
||||||
protocolParamsRules: {
|
protocolParamsRules: {
|
||||||
/* scrapNum: [
|
/* scrapNum: [
|
||||||
|
|
@ -156,6 +186,30 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
/** 查询往来单位下拉框 */
|
||||||
|
queryUnitSel() {
|
||||||
|
queryContactUnitsSelApi().then(res => {
|
||||||
|
console.log(res)
|
||||||
|
this.unitSelRange = res.data.map(item => {
|
||||||
|
return {
|
||||||
|
label: item.name,
|
||||||
|
value: item.id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}).catch(err => {})
|
||||||
|
},
|
||||||
|
/** 查询租赁工程下拉框 */
|
||||||
|
queryProjSel() {
|
||||||
|
queryProjectSelApi().then(res => {
|
||||||
|
console.log(res)
|
||||||
|
this.projSelRange = res.data.map(item => {
|
||||||
|
return {
|
||||||
|
label: item.name,
|
||||||
|
value: item.id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}).catch(err => {})
|
||||||
|
},
|
||||||
/** 确认按钮 */
|
/** 确认按钮 */
|
||||||
onSubmit() {
|
onSubmit() {
|
||||||
this.$refs.protocolParamsRef.validate((valid) => {
|
this.$refs.protocolParamsRef.validate((valid) => {
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,13 @@
|
||||||
|
let agreementStatus = [
|
||||||
|
{ label: '已结算', value: 0 },
|
||||||
|
{ label: '未结算', value: 1 },
|
||||||
|
]
|
||||||
|
|
||||||
export const formLabel = [
|
export const formLabel = [
|
||||||
{ f_label: '关键字', f_model: 'keywords', f_type: 'date' },
|
{ f_label: '开始时间', f_model: 'startTime', f_type: 'date' },
|
||||||
{ f_label: '关键字', f_model: 'keywords', f_type: 'ipt' },
|
{ f_label: '结束时间', f_model: 'endTime', f_type: 'date' },
|
||||||
{ f_label: '状态', f_model: 'keywords', f_type: 'sel' },
|
{ f_label: '关键字', f_model: 'keyWord', f_type: 'ipt' },
|
||||||
|
{ f_label: '状态', f_model: 'isBalance', f_type: 'sel', f_selList: agreementStatus },
|
||||||
]
|
]
|
||||||
export const columnsList = [
|
export const columnsList = [
|
||||||
{ t_props: 'signDate', t_label: '协议签订时间', },
|
{ t_props: 'signDate', t_label: '协议签订时间', },
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue