| | |
| | | * @Author: chen jing wu |
| | | * @Date: 2023-05-15 11:14:32 |
| | | * @LastEditors: chen jing wu |
| | | * @LastEditTime: 2023-06-05 14:01:14 |
| | | * @LastEditTime: 2023-09-04 13:16:23 |
| | | */ |
| | | import { LightningElement,wire,track,api} from 'lwc'; |
| | | import { CurrentPageReference } from "lightning/navigation"; |
| | |
| | | import init from '@salesforce/apex/OpportunityLightingButtonController.initForAssignTaskButtonButton'; |
| | | import { NavigationMixin } from 'lightning/navigation'; |
| | | import { encodeDefaultFieldValues } from 'lightning/pageReferenceUtils'; |
| | | export default class LexAssignTaskButton extends LightningElement { |
| | | import RECORD_TYPE_NAME_BY_INQUIRY_FOLLOW_UP from '@salesforce/label/c.RECORD_TYPE_NAME_BY_INQUIRY_FOLLOW_UP'; |
| | | export default class LexAssignTaskButton extends NavigationMixin(LightningElement) { |
| | | @api recordId; |
| | | accountName; |
| | | accountId; |
| | |
| | | this.accountId = result.accountId; |
| | | this.accountName = result.accountName; |
| | | this.oppName = result.name; |
| | | this.recordTypeId = result.recordTypeId; |
| | | this.recordTypeId = RECORD_TYPE_NAME_BY_INQUIRY_FOLLOW_UP; |
| | | this.assignTask(); |
| | | }).catch(error=>{ |
| | | console.log("error"); |
| | |
| | | account__c: this.accountId, |
| | | OpportunityId__c: this.recordId, |
| | | taskStatus__c: '01 分配', |
| | | taskDifferent__c: '上级分配任务' |
| | | taskDifferent__c: '上级分配任务', |
| | | Name: '*' |
| | | }); |
| | | this[NavigationMixin.Navigate]({ |
| | | type: 'standard__objectPage', |
| | | attributes: { |
| | | objectApiName: 'Task', |
| | | objectApiName: 'task__c', |
| | | actionName: 'new' |
| | | }, |
| | | state: { |