diff --git a/src/views/bjd/dj_input.vue b/src/views/bjd/dj_input.vue
index f6ab2e9..887928d 100644
--- a/src/views/bjd/dj_input.vue
+++ b/src/views/bjd/dj_input.vue
@@ -350,7 +350,7 @@
{
required: true,
message:
- '报检人电话不能为空,该电话用于短信通知企业网上交费。',
+ '报检人电话不能为空。',
trigger: 'change',
},
]"
@@ -1627,9 +1627,6 @@ export default {
this.templateName = '安全阀报检导入模板.xlsx'
}
// 区划跟科室加载完成后读取关联数据
- if (this.formState === 'create' || this.formState === 'newBuild') {
- this.getBjdDepartment()
- }
this.getJylb()
this.getArea()
this.getDepts()
@@ -1869,30 +1866,23 @@ export default {
this.jylbs = data
})
},
+ /**
+ * 查询科室
+ */
getDepts() {
- // 查询科室
this.api({
url: '/department/all',
method: 'get',
params: {
- shebeizhongleidaima: this.bjd.shebeizhongleidaima
+ shebeizhongleidaima: this.bjd.shebeizhongleidaima,
+ quhuadaima: this.bjd.quhuadaima,
+ jianyanleibie: 'JJ'
}
- }).then((data) => {
+ }).then(data => {
this.depts = data
- })
- },
- getBjdDepartment() {
- this.bjdDepartment.shebeizhonglei = this.bjd.shebeizhongleidaima
- this.bjdDepartment.jianyanleibie = this.bjd.jianyanleibie
- this.bjdDepartment.quhumingcheng = this.bjd.quhuadaima
- this.apibjd({
- url: '/bjdDepartment/getBjdDepartment',
- method: 'get',
- params: this.bjdDepartment
- }).then((data) => {
- if (data != null) {
- this.bjdDepartment = data
- this.$set(this.bjd, 'departmentId', this.bjdDepartment.departmentId)
+ if (this.formState === 'create') {
+ this.bjdDepartment = this.depts[0]
+ this.$set(this.bjd, 'departmentId', this.bjdDepartment.id)
}
})
},
diff --git a/src/views/bjd/jj_input.vue b/src/views/bjd/jj_input.vue
index e6323d1..324a373 100644
--- a/src/views/bjd/jj_input.vue
+++ b/src/views/bjd/jj_input.vue
@@ -10,24 +10,6 @@
更新/核价
-
-
- 资料审查
-
-
- 补证通知
-
-
-
- 不予受理
-
-
-
-
- 不予受理
-
-
-
审核通过
@@ -46,9 +28,6 @@
-
- 资料查看
-
打印回执单
@@ -186,72 +165,59 @@
-
+
-
-
-
-
@@ -652,40 +618,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -768,7 +700,6 @@ export default {
shebeizhongleidaima: this.$route.params.sbzldm,
quhuamingcheng: '',
quhuadaima: '',
- lingqufangshi: '自取',
bjType: this.$route.query.bjType
},
param: {
@@ -846,8 +777,9 @@ export default {
created() {
if (this.formState === 'newBuild') {
this.tableData = []
- this.$set(this.bjd, 'shouliriqi', new Date())
- this.$set(this.bjd, 'baojianriqi', new Date())
+ const date = this.formatter.dateFormat('YYYY-MM-dd')
+ this.$set(this.bjd, 'shouliriqi', date)
+ this.$set(this.bjd, 'baojianriqi', date)
this.getSblb()
if (this.bjd.shebeizhongleidaima === '8000') {
this.bjd.shiyongdanwei = '/'
@@ -878,9 +810,6 @@ export default {
this.templateName = '车用气瓶报检导入模板.xlsx'
}
// 区划跟科室加载完成后读取关联数据
- if (this.formState === 'create') {
- this.getBjdDepartment()
- }
this.getJylb()
this.getArea()
this.getDepts()
@@ -903,7 +832,7 @@ export default {
}).then(data => {
this.bjd = data
if (this.bjd.dataSource === 1 && this.formState !== 'finish') {
- this.$set(this.bjd, 'shouliriqi', new Date())
+ this.$set(this.bjd, 'shouliriqi', this.formatter.dateFormat('YYYY-MM-dd'))
}
if (this.bjd.baojiandianhua === undefined || this.bjd.baojiandianhua === null) {
this.bjd.baojiandianhua = this.bjd.shigongdanweiDianhua
@@ -938,8 +867,9 @@ export default {
},
// 报检设备设置默认值
setDefaultValue(obj) {
- this.$set(this.bjd, 'shouliriqi', new Date())
- this.$set(this.bjd, 'baojianriqi', new Date())
+ const date = this.formatter.dateFormat('YYYY-MM-dd')
+ this.$set(this.bjd, 'shouliriqi', date)
+ this.$set(this.bjd, 'baojianriqi', date)
this.bjd.lingqufangshi = '自取'
this.$set(obj, 'neibuleibie', 'JD')
if (this.bjd.shebeizhongleidaima === '1000') {
@@ -1037,27 +967,18 @@ export default {
},
getDepts() { // 查询科室
this.api({
- url: '/department/getDepartmentByCode',
+ url: '/department/all',
method: 'get',
params: {
- code: this.bjd.shebeizhongleidaima
+ shebeizhongleidaima: this.bjd.shebeizhongleidaima,
+ quhuadaima: this.bjd.quhuadaima,
+ jianyanleibie: 'JJ'
}
}).then(data => {
this.depts = data
- })
- },
- getBjdDepartment() {
- this.bjdDepartment.shebeizhonglei = this.bjd.shebeizhongleidaima
- this.bjdDepartment.jianyanleibie = this.bjd.jianyanleibie
- this.bjdDepartment.quhumingcheng = this.bjd.quhuadaima
- this.apibjd({
- url: '/bjdDepartment/getObj',
- method: 'get',
- params: this.bjdDepartment
- }).then(data => {
- if (data != null) {
- this.bjdDepartment = data
- this.$set(this.bjd, 'departmentId', this.bjdDepartment.departmentId)
+ if (this.formState === 'create') {
+ this.bjdDepartment = this.depts[0]
+ this.$set(this.bjd, 'departmentId', this.bjdDepartment.id)
}
})
},
@@ -1419,40 +1340,12 @@ export default {
}
})
},
+ /**
+ * 报检单保存
+ *
+ * @param audit 是否审核通过
+ */
bjdSave(audit) {
- if (audit) {
- let message = '请确认是否要审核通过'
- if (this.bjd.shebeizhongleidaima === '3000' || this.bjd.shebeizhongleidaima === '4000') {
- message = '请确认资料已审核完毕/检验价格已经核定???是否继续??'
- if (this.$store.getters.userId !== 10221 && this.$store.getters.userId !== 10003) {
- // 莱芜科室先收费,此处需要跳过。
- if (this.bjd.ziliaorenlingren.indexOf(this.$store.getters.userId) === -1) {
- // 如果资料认领人中缺少当前人员不允许当前人员进行审核操作。
- this.$message({
- type: 'warning',
- message: '审核受限,您不属于当前资料审核人!!!监督检验报检设备需经科室资料审核!请核价后提示企业将资料递交到科室。'
- })
- return false
- }
- }
- }
- this.$confirm(message, '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- this.bjdQurenSave(audit)
- }).catch(() => {
- this.$message({
- type: 'info',
- message: '已取消操作!'
- })
- })
- } else {
- this.bjdQurenSave(audit)
- }
- }, // 报检单保存
- bjdQurenSave(audit) {
this.$refs['bjd'].validate(valid => {
if (valid) {
if (this.judgeNull(this.bjd.quhuadaima)) {
@@ -1514,7 +1407,8 @@ export default {
data: {
bjd: this.bjd,
paramList: this.tableData,
- audit: audit
+ audit: audit,
+ isShengju: false
}
}).then(data => {
Utils.$emit('bjd-list')
@@ -1531,7 +1425,7 @@ export default {
// 【济南市特种设备检验研究院】您的43项目报检申请资料审核已通过,请根据施工进度登录企业管理平台[申请现场检验]。咨询电话:89738113。
}
} else {
- this.tableData = data.tableData
+ this.tableData = data.renwus
for (const tableObj of this.tableData) {
const sblbpz = []
sblbpz.push(tableObj.shebeileibiedaima)