liangxiaozhen
2023-08-06 1d17c4022a928eacff7309016cde76f29ad257fb
force-app/main/default/lwc/lexCreateNewServiceContract/lexCreateNewServiceContract.js
@@ -9,7 +9,7 @@
import {
    CloseActionScreenEvent
} from 'lightning/actions';
import init from '@salesforce/apex/otherButtonMaintenanceContractCtl.init';
import init from '@salesforce/apex/buttonAccountCtl.init';
export default class LexCreateNewServiceContract extends LightningElement {
    @api recordId;
@@ -41,13 +41,13 @@
            if (result != null) {
                this.IsLoading = false;
                this.Id = result.Id;
                this.HospitalC = result.HospitalC;
                this.HospitalIdC = result.HospitalIdC;
                this.DepartmentClassC = result.DepartmentClassC;
                this.DepartmentClassIdC = result.DepartmentClassIdC;
                this.HospitalC = result.HospitalC == undefined ? "" : result.HospitalC;;
                this.HospitalIdC = result.HospitalIdC == undefined ? "" : result.HospitalIdC;;
                this.DepartmentClassC = result.DepartmentClassC == undefined ? "" : result.DepartmentClassC;;
                this.DepartmentClassIdC = result.DepartmentClassIdC == undefined ? "" : result.DepartmentClassIdC;;
                this.Name = result.Name;
                this.PrintInspectupReport();
                this.CreateNewServiceContract();
                this.dispatchEvent(new CloseActionScreenEvent());
            }
        }).catch(error => {
@@ -55,8 +55,8 @@
        })
    }
    // 报告书明细编辑
    PrintInspectupReport() {
    // 新建新服务合同
    CreateNewServiceContract() {
        var Hospital = this.HospitalC;
        var Hospitalid = this.HospitalIdC;
        var Department = this.DepartmentClassC;
@@ -72,6 +72,6 @@
            console.log(url);
        // window.top.location.href = url;
        window.top.location.href = url;
    }
}