|
|
@@ -25,7 +25,7 @@
|
|
|
|
|
|
<el-form label-width="150px" ref="EntityForm" :model="formData" :disabled="formData.Status > 0">
|
|
|
<el-row>
|
|
|
- <el-col :span="8">
|
|
|
+ <el-col :span="6">
|
|
|
<el-form-item label="提交人" prop="Submitter">
|
|
|
<el-input v-model="formData.Submitter" :readonly="true" placeholder="请输入" style="width: 100%"></el-input>
|
|
|
</el-form-item>
|
|
|
@@ -39,14 +39,23 @@
|
|
|
<!--</el-select>-->
|
|
|
<!--</el-form-item>-->
|
|
|
<!--</el-col>-->
|
|
|
- <el-col :span="8">
|
|
|
+ <el-col :span="6">
|
|
|
+ <el-form-item label="类型" prop="Type" :rules="{ required: true, message: '类型不能为空', trigger: 'change'}">
|
|
|
+ <el-select ref="Type" v-model="formData.Type" placeholder="请选择复审人" style="width: 100%" filterable
|
|
|
+ allow-create default-first-option :disabled="formData.Status > 0">
|
|
|
+ <el-option v-for="item in TypeOptions" :key="item.Id" :label="item.Name" :value="item.Id">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="6">
|
|
|
<el-form-item label="初审人员" prop="FirstAuditName" :rules="{ required: true, message: '初审人员不能为空', trigger: 'change'}">
|
|
|
<el-input ref="selectAuditer" readonly v-model="formData.FirstAuditName" placeholder="请选择初审人">
|
|
|
<el-button slot="append" icon="el-icon-search" @click="chooseAuditorShow" :readonly="formData.Status > 0"></el-button>
|
|
|
</el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="8">
|
|
|
+ <el-col :span="6">
|
|
|
<el-form-item label="复审人员" prop="SecondAudit" :rules="{ required: true, message: '复审人员不能为空', trigger: 'change'}">
|
|
|
<el-select ref="secondAudit" v-model="formData.SecondAudit" placeholder="请选择复审人" style="width: 100%" filterable
|
|
|
allow-create default-first-option :disabled="formData.Status > 0">
|
|
|
@@ -55,7 +64,7 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="16">
|
|
|
+ <el-col :span="12">
|
|
|
<el-form-item label="备注" prop="Remark">
|
|
|
<el-input type="textarea" v-model="formData.Remark"
|
|
|
placeholder="请输入">
|
|
|
@@ -65,10 +74,10 @@
|
|
|
</el-row>
|
|
|
</el-form>
|
|
|
</el-card>
|
|
|
- <el-card class="box-card">
|
|
|
+ <el-card class="box-card" v-if="cardType == '7'">
|
|
|
<div slot="header">
|
|
|
<span>
|
|
|
- <i class="icon icon-table2"></i> 明细
|
|
|
+ <i class="icon icon-table2"></i> 收入业务
|
|
|
<span style="float: right;">
|
|
|
<el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" @click="addItems" v-if="isEdit && formData.Status <= 0">添加明细</el-button>
|
|
|
</span>
|
|
|
@@ -110,13 +119,59 @@
|
|
|
</el-pagination>
|
|
|
</el-card>
|
|
|
|
|
|
+
|
|
|
+ <el-card class="box-card" v-if="cardType == '6'">
|
|
|
+ <div slot="header">
|
|
|
+ <span>
|
|
|
+ <i class="icon icon-table2"></i> 外部市场
|
|
|
+ <span style="float: right;">
|
|
|
+ <el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" @click="addMarketItems" v-if="isEdit && formData.Status <= 0">添加明细</el-button>
|
|
|
+ </span>
|
|
|
+ </span>
|
|
|
+ </div>
|
|
|
+ <el-table :data="entityList" border height="calc(100vh - 243px)" style="width: 100%" @sort-change="orderby" size="mini">
|
|
|
+ <el-table-column label="操作" width="150px" align="center" fixed="right">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-button type="primary" size="mini" @click="editOilcatalog(scope.row)" plain>编辑</el-button>
|
|
|
+ <el-popover placement="top" title="提示">
|
|
|
+ <el-alert
|
|
|
+ title=""
|
|
|
+ description="确认要删除吗?"
|
|
|
+ type="warning"
|
|
|
+ :closable="false">
|
|
|
+ </el-alert>
|
|
|
+ <br/>
|
|
|
+ <div style="text-align: right; margin: 0">
|
|
|
+ <el-button type="danger" size="mini" @click="deleteEntity(scope.row)">删除</el-button>
|
|
|
+ </div>
|
|
|
+ <el-button slot="reference" type="danger" title="删除" style="margin-left:10px" size="mini" plain v-if="isEdit && scope.row.Status == 0">删除</el-button>
|
|
|
+ </el-popover>
|
|
|
+ </template>
|
|
|
+
|
|
|
+ </el-table-column>
|
|
|
+ <!--<el-table-column sortable min-width="80" align="center" show-overflow-tooltip prop="SupplierName" label="序号"></el-table-column>-->
|
|
|
+ <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="CompanyName" label="企业名称"></el-table-column>
|
|
|
+ <el-table-column sortable min-width="500" align="center" show-overflow-tooltip prop="Business" label="业务范围"></el-table-column>
|
|
|
+ <el-table-column sortable min-width="200" align="center" show-overflow-tooltip label="有效期起止">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ {{(jstimehandle(scope.row.ValidityFrom))}}--{{(jstimehandle(scope.row.ValidityTo))}}
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="Remark" label="备注"></el-table-column>
|
|
|
+
|
|
|
+ </el-table>
|
|
|
+ <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"
|
|
|
+ :page-sizes="[10, 15, 20, 25]" :page-size="size" layout="total, sizes, prev, pager, next, jumper" :total="currentItemCount">
|
|
|
+ </el-pagination>
|
|
|
+ </el-card>
|
|
|
+
|
|
|
<choose-auditor ref="chooseAuditor"
|
|
|
@close="setAuditer"
|
|
|
@hideChooseAuditer="chooseAuditorVisible=false"
|
|
|
:visible="chooseAuditorVisible"></choose-auditor>
|
|
|
|
|
|
|
|
|
- <el-dialog title="添加收入业务目录"
|
|
|
+ <el-dialog :title="dialogtitle"
|
|
|
:visible.sync="showadddialog"
|
|
|
width="60%">
|
|
|
<el-form label-width="135px" ref="IncomeEntity" :model="incomeData" :rules="rules" :disabled="incomeData.Status != 0">
|
|
|
@@ -171,6 +226,41 @@
|
|
|
</el-row>
|
|
|
</el-form>
|
|
|
</el-dialog>
|
|
|
+ <el-dialog :title="markettitle"
|
|
|
+ :visible.sync="showaddmarketdialog"
|
|
|
+ width="60%">
|
|
|
+ <el-form label-width="135px" ref="IncomeEntity" :model="incomeData" :disabled="incomeData.Status != 0">
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="供方名称" prop="CompanyName" :rules="{ required: true, message: '供方名称不能为空', trigger: 'blur'}">
|
|
|
+ <el-input v-model="incomeData.CompanyName" :maxlength="255" placeholder="请输入" style="width: 100%"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="有效期" prop="ValidityDate" >
|
|
|
+ <el-date-picker v-model="ValidityDate" type="daterange" range-separator="至"
|
|
|
+ start-placeholder="有效期起" end-placeholder="有效期止"></el-date-picker>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="24">
|
|
|
+ <el-form-item label="营业范围" prop="Business" :rules="{ required: true, message: '营业范围不能为空', trigger: 'blur'}">
|
|
|
+ <el-input v-model="incomeData.Business" type="textarea" style="width: 100%"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="24">
|
|
|
+ <el-form-item label="备注">
|
|
|
+ <el-input v-model="incomeData.Remark" placeholder="请输入" type="textarea" style="width: 100%">
|
|
|
+ </el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="24">
|
|
|
+ <el-form-item style="text-align: center;" v-if="incomeData.Status == 0">
|
|
|
+ <el-button type="primary" size="mini" @click="saveOilcatalog">保存</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ </el-form>
|
|
|
+ </el-dialog>
|
|
|
<el-dialog title="审批流程" :visible.sync="audithistoryshow" width="1200px">
|
|
|
<wf-multi-history :entryinfo="entrydetail"></wf-multi-history>
|
|
|
</el-dialog>
|
|
|
@@ -255,8 +345,16 @@
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+ var validDate = (rule, value, callback) => {
|
|
|
+ if (!value || !value[0] || !value[1]) {
|
|
|
+ callback(new Error('请选择时间'))
|
|
|
+ } else {
|
|
|
+ callback()
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
return {
|
|
|
+ showaddmarketdialog: false,
|
|
|
dialogMakeSure: false,
|
|
|
audithistoryshow: false,
|
|
|
chooseAuditorVisible: false,
|
|
|
@@ -264,7 +362,11 @@
|
|
|
auditBtn: false,
|
|
|
isEdit: true,
|
|
|
|
|
|
+ ValidityDate: null,
|
|
|
+ cardType: '',
|
|
|
auditstepcode: '',
|
|
|
+ markettitle: '',
|
|
|
+ dialogtitle: '',
|
|
|
// 分页参数
|
|
|
size: 10,
|
|
|
currentPage: 1,
|
|
|
@@ -278,6 +380,16 @@
|
|
|
organizeOption: [],
|
|
|
secauditerOptions: [],
|
|
|
entityList: [],
|
|
|
+ TypeOptions: [
|
|
|
+ {
|
|
|
+ Id: '6',
|
|
|
+ Name: '外部市场'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ Id: '7',
|
|
|
+ Name: '收入业务'
|
|
|
+ }
|
|
|
+ ],
|
|
|
|
|
|
shenheForm: {
|
|
|
SuccessStatus: 1,
|
|
|
@@ -291,6 +403,7 @@
|
|
|
},
|
|
|
formData: {
|
|
|
Id: '',
|
|
|
+ Type: '',
|
|
|
Status: '',
|
|
|
SubmitterId: '',
|
|
|
Submitter: '',
|
|
|
@@ -306,10 +419,11 @@
|
|
|
ProcessKey: '',
|
|
|
CreateUserId: ''
|
|
|
},
|
|
|
+ incomeDataTmp: {},
|
|
|
incomeData: {
|
|
|
Id: '',
|
|
|
SubId: '',
|
|
|
- CatalogType: 7,
|
|
|
+ CatalogType: '',
|
|
|
CompanyName: '',
|
|
|
LegalPerson: '',
|
|
|
Address: '',
|
|
|
@@ -321,7 +435,9 @@
|
|
|
Remark: '',
|
|
|
Status: '',
|
|
|
FirstAudit: '',
|
|
|
- SecondAudit: ''
|
|
|
+ SecondAudit: '',
|
|
|
+ ValidityFrom: null,
|
|
|
+ ValidityTo: null
|
|
|
},
|
|
|
rules: {
|
|
|
CompanyName: [
|
|
|
@@ -346,10 +462,17 @@
|
|
|
RecordScope: [
|
|
|
{ required: true, message: '申请备案范围不能为空', trigger: 'blur' }
|
|
|
]
|
|
|
+ },
|
|
|
+ rules1: {
|
|
|
+ ValidityDate: [{
|
|
|
+ validator: validDate,
|
|
|
+ trigger: 'blur'
|
|
|
+ }]
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
created () {
|
|
|
+ Object.assign(this.incomeDataTmp, this.incomeData)
|
|
|
this.formData.SubmitterId = this.authUser.Profile.Id
|
|
|
this.formData.Submitter = this.authUser.Profile.Realname
|
|
|
this.getDictOptions()
|
|
|
@@ -368,6 +491,13 @@
|
|
|
this.dialogMakeSure = true
|
|
|
},
|
|
|
makeSure () {
|
|
|
+ if (this.shenheForm.AuditorRemark.trim().length < 1 ) {
|
|
|
+ this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: '请填写审批意见!'
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
let params = this.shenheForm
|
|
|
api.auditEntity(this.formData.Id, params, this.$axios).then(res => {
|
|
|
if (res.data.code === 0) {
|
|
|
@@ -456,9 +586,33 @@
|
|
|
this.incomeData.Business = val.Business
|
|
|
this.incomeData.ProcessKey = val.ProcessKey
|
|
|
this.incomeData.Status = val.Status
|
|
|
- this.showadddialog = true
|
|
|
+ this.ValidityDate = [new Date(val.ValidityFrom), new Date(val.ValidityTo)]
|
|
|
+ if (this.cardType === '6') {
|
|
|
+ this.markettitle = '编辑外部市场目录'
|
|
|
+ this.showaddmarketdialog = true
|
|
|
+ } else {
|
|
|
+ this.dialogtitle = '编辑收入业务目录'
|
|
|
+ this.showadddialog = true
|
|
|
+ }
|
|
|
+ },
|
|
|
+ // 添加外部市场
|
|
|
+ addMarketItems () {
|
|
|
+ // this.clearIncomeData()
|
|
|
+ this.incomeData.Id = 0
|
|
|
+ this.markettitle = '添加外部市场目录'
|
|
|
+ if (this.formData.Id === 0) {
|
|
|
+ this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: '请先保存审批信息!'
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ this.showaddmarketdialog = true
|
|
|
},
|
|
|
addItems () {
|
|
|
+ // this.clearIncomeData()
|
|
|
+ this.incomeData.Id = 0
|
|
|
+ this.dialogtitle = '添加收入业务目录'
|
|
|
if (this.formData.Id === 0) {
|
|
|
this.$message({
|
|
|
type: 'warning',
|
|
|
@@ -504,6 +658,14 @@
|
|
|
saveOilcatalog () {
|
|
|
// this.incomeData.RegCapital = parseFloat(this.incomeData.RegCapital)
|
|
|
this.incomeData.SubId = this.formData.Id
|
|
|
+ this.incomeData.CatalogType = parseInt(this.formData.Type)
|
|
|
+ if (this.ValidityDate && this.ValidityDate.length === 2) {
|
|
|
+ this.ValidityDate[1].setHours(23)
|
|
|
+ this.ValidityDate[1].setMinutes(59)
|
|
|
+ this.ValidityDate[1].setSeconds(59)
|
|
|
+ this.incomeData.ValidityFrom = this.ValidityDate[0]
|
|
|
+ this.incomeData.ValidityTo = this.ValidityDate[1]
|
|
|
+ }
|
|
|
if (this.incomeData.Id > 0) {
|
|
|
this.editOilcatalogEntity()
|
|
|
} else {
|
|
|
@@ -519,8 +681,9 @@
|
|
|
type: 'success',
|
|
|
message: res.data.message
|
|
|
})
|
|
|
- this.showadddialog = false
|
|
|
this.initincomeDatas()
|
|
|
+ this.showaddmarketdialog = false
|
|
|
+ this.showadddialog = false
|
|
|
} else {
|
|
|
this.$message({
|
|
|
type: 'warning',
|
|
|
@@ -543,6 +706,7 @@
|
|
|
})
|
|
|
_this.initincomeDatas()
|
|
|
_this.showadddialog = false
|
|
|
+ this.showaddmarketdialog = false
|
|
|
} else {
|
|
|
_this.$message({
|
|
|
type: 'warning',
|
|
|
@@ -561,6 +725,7 @@
|
|
|
this.entrydetail.business = this.formData.Id
|
|
|
this.entrydetail.process = this.formData.ProcessKey
|
|
|
this.entrydetail.instance = this.formData.WorkflowId
|
|
|
+ this.cardType = this.formData.Type
|
|
|
this.auditOrgChang(this.formData.FirstAudit)
|
|
|
this.initincomeDatas()
|
|
|
|
|
|
@@ -589,13 +754,14 @@
|
|
|
_size: this.size,
|
|
|
Order: this.Column.Order,
|
|
|
Prop: this.Column.Prop,
|
|
|
- CatalogType: '7',
|
|
|
+ CatalogType: this.cardType,
|
|
|
SubId: this.formData.Id
|
|
|
}
|
|
|
let myCreateOn = []
|
|
|
// 查询条件
|
|
|
catapi.getList(myCreateOn, params, this.$axios).then(res => {
|
|
|
this.entityList = res.data.items
|
|
|
+ console.log(this.entityList, 'this.entityList')
|
|
|
this.currentItemCount = res.data.currentItemCount
|
|
|
})
|
|
|
},
|
|
|
@@ -670,6 +836,25 @@
|
|
|
console.error(err)
|
|
|
})
|
|
|
},
|
|
|
+ clearIncomeData () {
|
|
|
+ Object.assign(this.incomeData, this.incomeDataTmp)
|
|
|
+ // this.incomeData.Id = ''
|
|
|
+ // this.incomeData.SubId = ''
|
|
|
+ // this.incomeData.CatalogType = ''
|
|
|
+ // this.incomeData.CompanyName = ''
|
|
|
+ // this.incomeData.LegalPerson = ''
|
|
|
+ // this.incomeData.Address = ''
|
|
|
+ // this.incomeData.USCCode = ''
|
|
|
+ // this.incomeData.RegCapital = ''
|
|
|
+ // this.incomeData.RecordScope = ''
|
|
|
+ // this.incomeData.IDCode = ''
|
|
|
+ // this.incomeData.Business = ''
|
|
|
+ // this.incomeData.ProcessKey = ''
|
|
|
+ // this.incomeData.Status = ''
|
|
|
+ // this.ValidityDate = null
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
// 列表排序功能
|
|
|
orderby (column) {
|
|
|
if (column.order === 'ascending') {
|
|
|
@@ -698,6 +883,18 @@
|
|
|
this.size = value
|
|
|
this.currentPage = 1
|
|
|
this.initDatas()
|
|
|
+ },
|
|
|
+ jstimehandle (val) {
|
|
|
+ if (val === '') {
|
|
|
+ return '----'
|
|
|
+ } else if (val === '0001-01-01T08:00:00+08:00') {
|
|
|
+ return '----'
|
|
|
+ } else if (val === '5000-01-01T23:59:59+08:00') {
|
|
|
+ return '永久'
|
|
|
+ } else {
|
|
|
+ val = val.replace('T', ' ')
|
|
|
+ return val.substring(0, 10)
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
}
|