package nccloud.web.mmbd.bchange.bchangemaster.action;

import java.util.HashMap;
//import java.util.List;
import java.util.Map;
//import nccloud.framework.web.ui.pattern.grid.Grid;
import nccloud.web.codeplatform.framework.action.base.BaseAction;
import nccloud.web.codeplatform.framework.action.base.RequstParamWapper;
import nccloud.web.codeplatform.framework.action.base.RequestDTO;
import nccloud.web.codeplatform.framework.action.base.VOTransform;
import nccloud.framework.service.ServiceLocator;
import nccloud.framework.core.util.ArrayUtils;
import nccloud.framework.web.container.IRequest;
import nc.itf.mmbd.bchange.bchangemaster.IBchangeMasterVOService;
import nc.vo.bchange.bchange.BchangeMasterVO;

/**
 * 保存action（主子、单表、单form）
 */
public class SaveBchangeMasterVOAction extends BaseAction{

	@Override
	public Object doAction(IRequest request, RequstParamWapper paramWapper) throws Throwable{
		RequestDTO param = VOTransform.toVO(paramWapper.requestString,RequestDTO.class);
		
		IBchangeMasterVOService service = ServiceLocator.find(IBchangeMasterVOService.class);

		BchangeMasterVO[] vos = this.getVOs(param, BchangeMasterVO.class);
		vos = service.saveBchangeMasterVO(vos  );
		Object result = buildResult(param,param.getBillCard().getHead()!=null,null,vos);
		return result;
	
	}
}
