| | |
| | | pickList.put('洗消机', xixiaoji); |
| | | pickList.put('光源', guangyuan); |
| | | pickList.put('其他', qita); |
| | | pickList.put('全部',lstPickvals); |
| | | return JSON.serialize(pickList); |
| | | } |
| | | @AuraEnabled |
| | |
| | | submitFlag = submitFlag1; |
| | | return init1(); |
| | | } catch (Exception e) { |
| | | throw new AuraHandledException(e.getMessage()); |
| | | return e.getMessage(); |
| | | } |
| | | } |
| | | // 初始化 |
| | |
| | | if(pros.size() > 0){ |
| | | |
| | | List<ProcessInstanceHistory> items = new List<ProcessInstanceHistory>(); |
| | | maps.put('allowUserId',pros[0].StepsAndWorkitems[0].OriginalActor.Id); |
| | | maps.put('allowUserId',pros[0].StepsAndWorkitems[0].Actor.Id); |
| | | maps.put('userProfileId',UserInfo.getProfileId()); |
| | | for(ProcessInstance pro: pros){ |
| | | items.addAll(pro.StepsAndWorkitems); |
| | | } |
| | | for(ProcessInstanceHistory pro: pros[0].StepsAndWorkitems){ |
| | | if(pro.StepStatus == 'Started'){ |
| | | maps.put('submitUserId',pro.OriginalActorId); |
| | | maps.put('submitUserId',pro.ActorId); |
| | | } |
| | | } |
| | | LostReport.approvalHistorys = items; |
| | |
| | | } |
| | | |
| | | } catch (Exception e) { |
| | | throw new AuraHandledException(e.getMessage()); |
| | | return e.getMessage(); |
| | | } |
| | | } |
| | | // 数据录入 |
| | |
| | | } |
| | | } |
| | | } |
| | | // add tcm 20211119 end |
| | | |
| | | // add tcm 20211118 start |
| | | public static void search() { |
| | | if (LostReport.LostBrands[topNum].LostProducts[secondNum].LostProductss.LostProduct__c==null) { |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].LostProductss.ProductClass__c=null; |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].bool=false; |
| | | |
| | | }else { |
| | | Product2 prd = [select Id,ProductClass__c |
| | | , ProductCategory__c |
| | | from Product2 where Id =:LostReport.LostBrands[topNum].LostProducts[secondNum].LostProductss.LostProduct__c]; |
| | | if (prd.ProductCategory__c!=null) { |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].LostProductss.ProductClass__c=prd.ProductClass__c; |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].LostProductss.ProductCategory__c=prd.ProductCategory__c; |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].bool=true; |
| | | }else { |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].LostProductss.ProductClass__c=null; |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].LostProductss.ProductCategory__c=null; |
| | | LostReport.LostBrands[topNum].LostProducts[secondNum].bool=false; |
| | | |
| | | } |
| | | } |
| | | } |
| | | |
| | | @AuraEnabled |
| | | public static string searchProduct(String lostProduct){ |
| | | Product2 prd = null; |
| | |
| | | , ProductCategory__c |
| | | from Product2 where Id =:lostProduct]; |
| | | } catch (Exception e) { |
| | | throw new AuraHandledException(e.getMessage()); |
| | | return e.getMessage(); |
| | | } |
| | | return JSON.serialize(prd); |
| | | } |