| | |
| | | @RestResource(urlMapping='/OFSUploadRepairImage/*') |
| | | global with sharing class OFSUploadRepairImageRest { |
| | | // 20231103 chenjingwu Lightning文件修改 Start |
| | | @HttpPost |
| | | global static void doPost(String repairId, String ccImg, String acImg, String rqId) { |
| | | system.debug('OFSUploadImageRest.start'); |
| | |
| | | // res.responseBody = blob.valueOf(jsonResponse); |
| | | // return; |
| | | // } |
| | | // 20231103 chenjingwu Lightning文件修改 Start |
| | | // List<Attachment> attList = [Select Id, Name, Body, ParentId From Attachment Where Id= :repairQ.contract_consent_id__c]; |
| | | // Attachment att = null; |
| | | List<ContentVersion> verisonList = [select Id,Title,VersionData from ContentVersion where Id =: repairQ.contract_consent_id__c]; |
| | |
| | | } |
| | | ccId = version.Id; |
| | | repairQ.contract_consent_id__c = ccId; |
| | | // 20231103 chenjingwu Lightning文件修改 End |
| | | } catch ( Exception ex ) { |
| | | //TODO: |
| | | //error message:cannot update exception |
| | |
| | | } |
| | | } |
| | | if (String.isNotBlank(acImg)) { |
| | | // 20231103 chenjingwu Lightning文件修改 Start |
| | | // List<Attachment> attList = [Select Id, Name, Body, ParentId From Attachment Where Id= :repair.acceptance_id__c]; |
| | | List<ContentVersion> versionList = [select Id,Title,VersionData from ContentVersion where Id =: repair.acceptance_id__c]; |
| | | // Attachment att = null; |
| | |
| | | // res.responseBody = blob.valueOf(jsonResponse); |
| | | // return; |
| | | } |
| | | // 20231103 chenjingwu Lightning文件修改 End |
| | | } |
| | | |
| | | if (String.isNotBlank(ccId)) { |
| | |
| | | res.responseBody = blob.valueOf(jsonResponse); |
| | | return; |
| | | } |
| | | // 20231103 chenjingwu Lightning文件修改 End |
| | | } |