EAS bos客户端上传发票

发布时间:2023年12月25日

?无法bos启动测试。? 部署到测试服务器上测试

  @Override
	public void actionInvoiceUpload_actionPerformed(ActionEvent e) throws Exception {
    	 
//    	UIContext uiContext = new UIContext(this);
//		uiContext.put("action", "selectCloudInvoice");
//		if(editData.getId() == null || editData.getCreator() == null){
//			MsgBox.showError(this, "BILLIDNOTNULL");
//			SysUtil.abort();
//		}
//		uiContext.put("bill", editData);
//		uiContext.put(UIContext.OWNER, this);
//		IUIWindow uiWindow = null;
//		try{
//			uiWindow  = UIFactory.createUIFactory(UIFactoryName.MODEL).
//					create("com.kingdee.eas.base.wssc.client.InvoiceBillViewUI", uiContext, null, OprtState.VIEW);
//			if(uiWindow != null){
//				uiWindow.show();
//			}
//		}catch (UIException e1){
//			handUIException(e1);
//		}
    	
    	
    	
    	
/*   	UIContext uiContext = new UIContext(this);
    	uiContext.put("action", "selectCloudInvoice");
    	if (this.editData.getId() == null) {
    		this.editData.setId(BOSUuid.create(this.editData.getBOSType()));
    	}
    	uiContext.put("bill", this.editData);
    	uiContext.put("Owner", this);
    	this.storeFields();
    	Method openFpzsInvoicesUI = null;
    	try {
    		Class<?> clazz = Class.forName("com.kingdee.eas.base.wssc.client.InvoiceBillHelper");
    		openFpzsInvoicesUI = clazz.getMethod("openFpzsInvoicesUI", UIContext.class);
    	} catch (Exception var6) {
    		;
    	}
    	if (null == openFpzsInvoicesUI) {
    		try {
    			IUIWindow iuiWindow = UIFactory
    					.createUIFactory("com.kingdee.eas.base.uiframe.client.UIModelDialogFactory")
    					.create("com.kingdee.eas.base.wssc.client.InvoiceBillViewUI", uiContext, (Map) null,
    							OprtState.VIEW);
    			if (iuiWindow != null) {
    				iuiWindow.show();
    			}
    		} catch (Exception var5) {
    			logger.error(var5.getMessage());
    			this.handUIException(var5);
    			SysUtil.abort();
    		}
    	    } else {
    		openFpzsInvoicesUI.invoke((Object) null, uiContext);
    	  } */
    	 
          
		Set invoiceSerialNos = new HashSet();
		Map params = new HashMap();
		params.put("CompanyOrgUnitInfo", this.editData.getFICompany());  // 财务组织
		params.put("currAcctSupplier", null);
		params.put("invoiceSerialNos", invoiceSerialNos);
		params.put("billNumber", this.editData.getNumber());
		params.put("billId", this.editData.getId().toString());
		params.put("ui", this);
		params.put("uiClass", this.getClass().getName());
		IncomeInvoiceClientUtils.openPwyHelper(params);
	}
    
    
    
    
    
    /**
     * 发票导入反写当前单据
     * @param dataJsonObj
     * @throws BOSException 
     * @throws EASBizException 
     */
//    public void fillTable(JSONObject dataJsonObj) throws EASBizException, BOSException {
//    	   
//    	   String companyId = ((CompanyOrgUnitInfo)this.prmtFICompany.getValue()).getId().toString();
//    	   
//			OtherBillInvoiceCollection invoiceCollection = InvoiceUtils.transJson2InvoiceCollectionWithReload((Context)null, companyId, dataJsonObj);
//			OtherBillInvoiceInfo otherBillInvoiceInfo = invoiceCollection.get(0);
//		    this.txtDescription.setText(otherBillInvoiceInfo.getInvoiceNumber());  
//			 
//		 
//
//  }

文章来源:https://blog.csdn.net/MZ199290/article/details/135192183
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。