Browse Source

pdf上传

hongchuangyanfa 2 years ago
parent
commit
f3e7374561

+ 1 - 0
blade-ops-api/blade-resource-api/src/main/java/org/springblade/resource/feign/CommonFileClient.java

@@ -23,4 +23,5 @@ public interface CommonFileClient {
     @PostMapping(value = API_PREFIX + "/excelToPdf", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
     NewBladeFile excelToPdf(MultipartFile file);
 
+
 }

+ 6 - 0
blade-service/blade-manager/pom.xml

@@ -85,6 +85,12 @@
             <artifactId>spire.office.free</artifactId>
             <version>5.3.1</version>
         </dependency>
+
+        <dependency>
+            <groupId>e-iceblue</groupId>
+            <artifactId>spire.pdf.free</artifactId>
+            <version>5.1.0</version>
+        </dependency>
         <dependency>
             <groupId>org.jsoup</groupId>
             <artifactId>jsoup</artifactId>

+ 139 - 23
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/ExcelTabController.java

@@ -51,6 +51,7 @@ import org.springblade.manager.service.*;
 import org.springblade.manager.vo.*;
 import org.springblade.manager.wrapper.ExcelTabWrapper;
 import org.springblade.resource.feign.IOSSClient;
+import org.springframework.jdbc.core.JdbcTemplate;
 import org.springframework.web.bind.annotation.*;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import org.springblade.core.boot.ctrl.BladeController;
@@ -97,6 +98,8 @@ public class ExcelTabController extends BladeController {
 
 	private final WbsTreePrivateMapper wbsTreePrivateMapper;
 
+	private final JdbcTemplate jdbcTemplate;
+
 	/**
 	 * 详情
 	 */
@@ -290,6 +293,9 @@ public class ExcelTabController extends BladeController {
 				return R.data(tree);
 			}
 		}
+		if(wbsType==2){
+
+		}
 
 		return R.fail(200, "未查询到信息");
 	}
@@ -403,9 +409,7 @@ public class ExcelTabController extends BladeController {
 		File file_out = ResourceUtil.getFile(thmlUrl);
 		FileUtil.copy(file_in,file_out);
 		updateWrapper.set("html_url",thmlUrl);
-		wbsTreePrivateService.update(updateWrapper);
-		//关联项目下所有的合同段
-		wbsTreeContractService.updateAllNodeTabById(aPrivate);
+
 
 
 		// 匹配关联
@@ -427,32 +431,38 @@ public class ExcelTabController extends BladeController {
 				Element element = tds.get(j);
 				if(element.html().indexOf("el-input")>=0){
 					String titleName = element.attr("title");
-					double maxScore = 0.6;
-					String lastName = "";
-					String attrInfo = "";
+					double maxScore = 0.48;
+					String lastName = "警告";
+					String attrInfo = "key"+"__"+i+"_"+j;;
 
 					for(WbsFormElement elementInfo : elementList){
 						String ysName = elementInfo.getEName().replaceAll("[^\u4E00-\u9FA5_]", "");
 						if(titleName.equals(ysName)){
 							lastName = elementInfo.getEName();
-							attrInfo = elementInfo.getEKey()+"="+i+"_"+j;
+							attrInfo = elementInfo.getEKey()+"__"+i+"_"+j;
 							break;
 						}else{
 							if(MathUtil.sim(titleName,ysName) > maxScore){
-								attrInfo = elementInfo.getEKey()+"="+i+"_"+j;
+								attrInfo = elementInfo.getEKey()+"__"+i+"_"+j;
 								lastName = ysName ;
 								maxScore = MathUtil.sim(titleName,ysName);
 							}
 						}
 					}
 					String oncklickText = "'"+lastName +"',"+i+","+j;
-					element.children().get(0).attr("placeholder",lastName).attr("@focus","getInformation("+oncklickText+")").attr("keyName",attrInfo).attr("weighing",maxScore+"");//.attr("v-model","formData."+attrInfo);
+					element.children().get(0).attr("placeholder",lastName).attr("@focus","getInformation("+oncklickText+")")
+							.attr("weighing",maxScore+"").attr("id",attrInfo).attr("keyName",attrInfo).attr("v-model","formData."+attrInfo);
 				}
 			}
 		}
 
 		File writefile = new File(thmlUrl);
 		FileUtil.writeToFile(writefile, doc.html(), Boolean.parseBoolean("UTF-8"));
+		wbsTreePrivateService.update(updateWrapper);
+		//关联项目下所有的合同段
+		aPrivate.setHtmlUrl(thmlUrl);
+		wbsTreeContractService.updateAllNodeTabById(aPrivate);
+
 		return R.success("关联成功");
 	}
 
@@ -462,7 +472,7 @@ public class ExcelTabController extends BladeController {
 	 */
 	@GetMapping("/get-excel-html_buss")
 	@ApiOperationSupport(order = 16)
-	@ApiOperation(value = "清表生成html", notes = "清表生成html")
+	@ApiOperation(value = "用户端生成html", notes = "用户端生成html")
 	@ApiImplicitParams(value = {
 			@ApiImplicitParam(name = "pkeyId", value = "pkeyId", required = true)
 	})
@@ -479,12 +489,12 @@ public class ExcelTabController extends BladeController {
 		File file1 = ResourceUtil.getFile(wbsTreeContract.getHtmlUrl());
 		FileInputStream fileInputStream = new FileInputStream(file1);
 		String htmlString =  IoUtil.readToString(fileInputStream);
+		htmlString = htmlString.replaceAll("placeholder","placeholderxx");
 		// 解析 style
 		Document doc = Jsoup.parse(htmlString);
 		Element table = doc.select("table").first();
 
 
-
 		doc.select("Col").remove();
 		fileInputStream.close();
 		return R.data(table+"");
@@ -501,10 +511,10 @@ public class ExcelTabController extends BladeController {
 	@ApiImplicitParams(value = {
 			@ApiImplicitParam(name = "pkeyId", value = "pkeyId", required = true)
 	})
-	public R getExcelHtml(Long pkeyId) throws IOException {
+	public R getExcelHtml(Long pkeyId) throws IOException, InterruptedException {
 
+		Thread.sleep(200);
 		WbsTreePrivate wbsTreePrivate = wbsTreePrivateMapper.getByPKeyId(pkeyId);
-
 		if(wbsTreePrivate ==null ){
 			return R.fail("该数据下无此节点!");
 		}
@@ -531,8 +541,79 @@ public class ExcelTabController extends BladeController {
 	@PostMapping("/save_buss_data")
 	@ApiOperationSupport(order = 13)
 	@ApiOperation(value = "填报页面数据保存", notes = "填报页面数据保存")
-	public R<String> savaDataInfo1(@Valid @RequestBody JSONObject dataInfo, BladeUser bladeUser) {
-		System.out.println("123456");
+	public R<String> saveBussData(@Valid @RequestBody JSONObject dataInfo, BladeUser bladeUser) {
+		//
+		String contractId = dataInfo.getString("contractId");
+		String pkeyId = dataInfo.getString("pkeyId");
+		String projectId = dataInfo.getString("projectId");
+		dataInfo.remove("contractId");
+		dataInfo.remove("pkeyId");
+		dataInfo.remove("projectId");
+
+		// 去掉
+		Map<String,String> dataMap = new HashMap<>();
+		for(String k:dataInfo.keySet()){
+			String key = k.split("__")[0];
+			if(dataMap.containsKey(key)){
+				dataMap.put(key,dataMap.get(key)+","+k);
+			}else{
+				dataMap.put(key,k);
+			}
+		}
+
+		Map<String,String> dataMap2 = new HashMap<>();
+		dataMap2.put("pkeyId",pkeyId);
+		for(String k:dataMap.keySet()){
+			if(dataMap.get(k).indexOf(",")>=0){
+				String [] ziduan= dataMap.get(k).split(",");
+				String temp = "";
+				for(int i = 0; i < ziduan.length - 1; i++) {
+					for (int j = 0; j < ziduan.length - i - 1; j++) {
+						Integer tr = Integer.parseInt((ziduan[j].split("__")[1]).split("_")[0]);
+						Integer td = Integer.parseInt(ziduan[j].split("__")[1].split("_")[1]);
+
+						Integer tr_1 = Integer.parseInt(ziduan[j + 1].split("__")[1].split("_")[0]);
+						Integer td_1 = Integer.parseInt(ziduan[j + 1].split("__")[1].split("_")[1]);
+
+						if (tr > tr_1 && td==td_1  ) { //纵向排序
+							temp = ziduan[j];
+							ziduan[j] = ziduan[j + 1];
+							ziduan[j + 1] = temp;
+						}
+					}
+				}
+
+				String lastStr = dataInfo.getString(ziduan[0]);
+				for (int i=1 ;i<ziduan.length;i++){
+					lastStr+=","+dataInfo.getString(ziduan[i]);
+				}
+				dataMap2.put(k,lastStr);
+			}else{
+				dataMap2.put(k,dataInfo.getString(dataMap.get(k)));
+			}
+		}
+
+		WbsTreeContract wbsTreeContract = wbsTreeContractService.getBaseMapper().selectOne(Wrappers.<WbsTreeContract>query().lambda()
+				.eq(WbsTreeContract::getPKeyId, pkeyId));
+
+		String tabName = wbsTreeContract.getInitTableName();
+
+		String sqlInfo = "INSERT INTO "+tabName+" ( ";
+		String keyStr = "";
+		String valStr = "";
+		for (String keys : dataMap2.keySet()){
+			keyStr += keys+",";
+			valStr += "'"+dataMap2.get(keys)+"',";
+		}
+
+		keyStr=keyStr.substring(0,keyStr.lastIndexOf(","));
+		valStr=valStr.substring(0,valStr.lastIndexOf(","));
+
+		sqlInfo = sqlInfo + keyStr+") VALUES (" +valStr +")";
+
+		System.out.println(sqlInfo);
+		jdbcTemplate.execute(sqlInfo);
+
 
 		return  R.success("1");
 	}
@@ -559,7 +640,11 @@ public class ExcelTabController extends BladeController {
 
 		//解析
 		Element table = doc.select("table").first();
+
+
+
 		Elements trs = table.select("tr");
+		Element tableinfo = trs.get(0).parent().parent().attr("style","border-collapse: collapse;");
 
 		// 获取总行列数
 		int maxCol = doc.select("Col").size();
@@ -594,7 +679,7 @@ public class ExcelTabController extends BladeController {
 					if(StringUtils.isNotEmpty(keyId)){
 						String classInfo = styleMap.get(keyId);
 						data.removeAttr("class");
-						data.attr("style",styleMap.get(keyId).replaceAll("break-word","inherit"));
+						//data.attr("style",styleMap.get(keyId).replaceAll("break-word","inherit"));
 					}
 
 
@@ -734,7 +819,7 @@ public class ExcelTabController extends BladeController {
 						ExctabCell exctabCell = new ExctabCell();
 						if(textInfo.indexOf("年")>=0 && textInfo.indexOf("月")>=0&& textInfo.indexOf("日")>=0){
 							//data.empty().append("<input type='time' style='width:100%;height:100%' placeholder=''> </input>");
-							data.empty().append("<el-date-picker  style='width:100%;height:100%' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+"  type='date' format='YYYY年MM月DD日' placeholder='请选择时间'> </el-date-picker>");
+							data.empty().append("<el-date-picker  style='width:100%;height:100%'  trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+"  type='date' format='YYYY年MM月DD日' placeholder='请选择时间'> </el-date-picker>");
 							exctabCell.setExctabId(excelId);
 							exctabCell.setTextInfo("签字时间");
 							exctabCell.setIsDeleted(0);
@@ -744,26 +829,26 @@ public class ExcelTabController extends BladeController {
 							String parm = i+","+j+","+x1+","+x2+","+y1+","+y2+",$event";
 							if(index_state){
 								if(rowspan>=1){
-									data.empty().append("<el-input type='textarea'  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'   :rows="+rowspan*2+" placeholder=''> </el-input>");
+									data.empty().append("<el-input type='textarea'  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%;background-color: #edc9a2'   :rows="+rowspan*2+" placeholder=''> </el-input>");
 								}else{
-									data.empty().append("<el-input type='text'  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%' placeholder=''> </el-input>");
+									data.empty().append("<el-input type='text'  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%;background-color: #edc9a2' placeholder=''> </el-input>");
 								}
 							}else{
 								if(j==0 ){
 									if(colspan ==maxCol && i>=1 && i<=2){
 										if(rowspan>=1){
-											data.empty().append("<el-input type='textarea'  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'   :rows="+rowspan*2+" placeholder=''> </el-input>");
+											data.empty().append("<el-input type='textarea'  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%;background-color: #edc9a2'   :rows="+rowspan*2+" placeholder=''> </el-input>");
 										}else{
-											data.empty().append("<el-input type='text' @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%' placeholder=''> </el-input>");
+											data.empty().append("<el-input type='text' @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%;background-color: #edc9a2' placeholder=''> </el-input>");
 										}
 									}
 								}else{
 									Element bforData = tds.get(j-1);
 									if(!bforData.text().isEmpty()){
 										if(rowspan>=1){
-											data.empty().append("<el-input type='textarea' @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'   :rows="+rowspan*2+" placeholder=''> </el-input>");
+											data.empty().append("<el-input type='textarea' @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%;background-color: #edc9a2'   :rows="+rowspan*2+" placeholder=''> </el-input>");
 										}else{
-											data.empty().append("<el-input  type='text' @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%' placeholder=''> </el-input>");
+											data.empty().append("<el-input  type='text' @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+i+" tdIndex="+j+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%;background-color: #edc9a2' placeholder=''> </el-input>");
 										}
 									}
 								}
@@ -860,4 +945,35 @@ public class ExcelTabController extends BladeController {
 		return styleMap;
 	}
 
+	/**
+	 * 清表生成html
+	 */
+	@GetMapping("/get-excel-html-col")
+	@ApiOperationSupport(order = 15)
+	@ApiOperation(value = "元素识别html", notes = "元素识别html")
+	@ApiImplicitParams(value = {
+			@ApiImplicitParam(name = "id", value = "id", required = true)
+	})
+	public R getExcelHtmlByCol(Long id) throws IOException, InterruptedException {
+
+		Thread.sleep(200);
+		ExcelTab detail = excelTabService.getById(id);
+		if(detail ==null ){
+			return R.fail("该数据下无此节点!");
+		}
+		if(detail.getHtmlUrl()==null){
+			return R.fail("请上传清表!");
+		}
+
+		File file1 = ResourceUtil.getFile(detail.getHtmlUrl());
+		FileInputStream fileInputStream = new FileInputStream(file1);
+		String htmlString =   IoUtil.readToString(fileInputStream);
+		// 解析 style
+		Document doc = Jsoup.parse(htmlString);
+		Element table = doc.select("table").first();
+		doc.select("Col").remove();
+		fileInputStream.close();
+		return R.data(table+"");
+	}
+
 }

+ 58 - 8
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/LinkdataInfoController.java

@@ -17,12 +17,18 @@
 package org.springblade.manager.controller;
 
 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.spire.pdf.PdfDocument;
+import com.spire.pdf.PdfPageSettings;
+import com.spire.pdf.graphics.PdfMargins;
+import com.spire.pdf.htmlconverter.qt.HtmlConverter;
+import com.spire.xls.Workbook;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import io.swagger.annotations.ApiParam;
 import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
 import lombok.AllArgsConstructor;
 import javax.validation.Valid;
+import com.spire.pdf.htmlconverter.qt.Size;
 
 import org.jsoup.Jsoup;
 import org.jsoup.nodes.Document;
@@ -52,6 +58,7 @@ import org.springblade.core.boot.ctrl.BladeController;
 import java.io.File;
 import java.io.FileInputStream;
 import java.io.FileNotFoundException;
+import java.io.IOException;
 import java.util.Map;
 
 /**
@@ -177,35 +184,78 @@ public class LinkdataInfoController extends BladeController {
 	@PostMapping("/saveTabColInfo")
 	@ApiOperationSupport(order = 9)
 	@ApiOperation(value = "编辑表单-替换元素||删除文本信息 保存", notes = "传入linkdataInfo")
-	public R saveTabColInfo(@Valid @RequestBody LinkdataInfo linkdataInfo) throws FileNotFoundException {
-
+	public R saveTabColInfo(@Valid @RequestBody LinkdataInfo linkdataInfo) throws IOException {
 
 		// 获取 节点信息
 		WbsTreePrivate wbsTreePrivate = wbsTreePrivateMapper.getByPKeyId(linkdataInfo.getTabId());
-
 		// 读取html页面信息
 		File file1 = ResourceUtil.getFile(wbsTreePrivate.getHtmlUrl());
-		String htmlString =  IoUtil.readToString(new FileInputStream(file1));
+		FileInputStream inputStream = new FileInputStream(file1);
+		String htmlString =  IoUtil.readToString(inputStream);
 		// 样式集合
 		Document doc = Jsoup.parse(htmlString);
-
 		//解析
 		Element table = doc.select("table").first();
 		Elements trs = table.select("tr");
 		Element element = trs.get(linkdataInfo.getTrIndex()).select("td").get(linkdataInfo.getTdIndex());
+
 		if(linkdataInfo.getColName().equals("/")){
 			element.empty();
 		}else{
 			// 获取元素基本信息
-			WbsFormElement wbsFormElement = wbsFormElementService.getById(linkdataInfo.getId());
-			element.children().get(0).attr("placeholder",wbsFormElement.getEName()).attr("keyName",wbsFormElement.getEKey()+"="+linkdataInfo.getTrIndex()+"_"+linkdataInfo.getTdIndex()).attr("weighing","100");//.attr("v-model","formData."+attrInfo);
+			WbsFormElement wbsFormElement = wbsFormElementService.getById(linkdataInfo.getHtmlType());
+			String enName = wbsFormElement.getEName().replaceAll("[^\u4E00-\u9FA5_]", "");
+			String dataInfo2 =wbsFormElement.getEKey()+"__"+linkdataInfo.getTrIndex()+"_"+linkdataInfo.getTdIndex() ;
+			element.children().get(0).
+					attr("placeholder",enName)
+					.attr("keyName",dataInfo2)
+					.attr("weighing","100")
+					.attr("v-model","formData."+dataInfo2)
+					.attr("@focus","getInformation('"+enName+"',"+linkdataInfo.getTrIndex()+","+linkdataInfo.getTdIndex()+")");
 		}
 
 		File writefile = new File(wbsTreePrivate.getHtmlUrl());
 		FileUtil.writeToFile(writefile, doc.html(), Boolean.parseBoolean("UTF-8"));
-
+		inputStream.close();
 		return R.success("操作成功");
 	}
 
 
+/*	public static void main(String[] args) throws FileNotFoundException {
+*//*		String htmlUrl="/Users/hongchuangyanfa/Desktop/privateUrl/1549653308367437824.html";
+		 File file = ResourceUtil.getFile(htmlUrl);
+		FileInputStream inputStream = new FileInputStream(file);
+		 Workbook wb = new Workbook();
+		wb.loadFromMHtml(inputStream);
+		String htmlUrl2="/Users/hongchuangyanfa/Desktop/privateUrl/1549653308367437824.pdf";
+		wb.saveToFile(htmlUrl2);*//*
+
+		String url = "https://www.baidu.com/";
+
+		//转换后的结果文档(结果文档保存在Java项目程序文件下)
+		String fileName = "/Users/hongchuangyanfa/Desktop/pdf/HtmlToPDF.pdf";
+
+		//解压后的插件本地地址(这里是把插件包放在了Java项目文件夹下,也可以自定义其他本地路径)
+		String pluginPath = "/Users/hongchuangyanfa/tool/plugins_mac/";
+		HtmlConverter.setPluginPath(pluginPath);
+
+		//调用方法转换到PDF并设置PDF尺寸
+		HtmlConverter.convert(url, fileName, true, 1000, new Size(700f, 800f), new PdfMargins(0));
+
+		System.out.println("完成");
+
+	*//*	String url="/Users/hongchuangyanfa/Desktop/privateUrl/1550287371163926528.html";
+		//指定输出文档路径
+		String fileName = "/Users/hongchuangyanfa/Desktop/pdf/UrlToPdf.pdf";
+		//指定插件路径
+		String pluginPath = "/Users/hongchuangyanfa/tool/plugins_mac";
+
+		//设置插件路径
+		HtmlConverter.setPluginPath(pluginPath);
+
+		//将URL转换为PDF
+		HtmlConverter.convert(url, fileName, true, 1000000, new Size(1200f, 1000f), new PdfMargins(0));
+		System.out.println("ok");*//*
+
+	}*/
 }

+ 13 - 14
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/TextdictInfoController.java

@@ -168,20 +168,21 @@ public class TextdictInfoController extends BladeController {
 		String x2 = element.children().get(0).attr("x2");
 		String y1 = element.children().get(0).attr("y1");
 		String y2 = element.children().get(0).attr("y2");
-		String placeholder = element.children().get(0).attr("placeholder");
+		String placeholder = element.children().get(0).attr("placeholder").replaceAll("[^(\u4E00-\u9FA5_)]", "");
 		String keyname = element.children().get(0).attr("keyname");
 		String weighing = element.children().get(0).attr("weighing");
 
 		String parm = trindex+","+tdindex+","+x1+","+x2+","+y1+","+y2+",$event";
-		String oncklickText = "'"+keyname +"',"+trindex+","+tdindex;
-
+		String oncklickText =keyname+","+trindex+","+tdindex;
+		String vmode = "formData."+keyname;
 		if(textdictInfo.getTextId().equals("input")){ // 单选框
-			element.empty().append("<el-input type='text' @focus='getInformation("+oncklickText+")' placeholder="+placeholder+" keyname="+keyname+" weighing="+weighing+"  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+trindex+" tdIndex="+tdindex+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'   placeholder='"+placeholder+"'> </el-input>");
+			element.empty().append("<el-input type='text' v-model="+vmode+" @focus='getInformation("+oncklickText+")' placeholder="+placeholder+" keyname="+keyname+" weighing="+weighing+"  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+trindex+" tdIndex="+tdindex+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%' > </el-input>");
 		}else if(textdictInfo.getTextId().equals("textarea")){ // 文本域
-			int rowspan = Integer.parseInt(element.attr("rowspan")+"")*2;
-			element.empty().append("<el-input :rows="+rowspan+" type='textarea' @focus='getInformation("+oncklickText+")' placeholder="+placeholder+" keyname="+keyname+" weighing="+weighing+"  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+trindex+" tdIndex="+tdindex+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'   placeholder='"+placeholder+"'> </el-input>");
+			int rowspan = element.attr("ROWSPAN").equals("") ? 0 : Integer.parseInt(element.attr("ROWSPAN"));
+			//@focus='getInformation("+oncklickText+")'
+			element.empty().append("<el-input :rows="+rowspan*2+"  type='textarea' v-model="+vmode+"  @focus='getInformation("+oncklickText+")'   keyname="+keyname+" weighing="+weighing+"  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+trindex+" tdIndex="+tdindex+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'  > </el-input>");
 		}else if(textdictInfo.getTextId().equals("select")){ // 下拉框
-			String selectText = " <el-select v-model="+keyname+" placeholder='请选择'>";
+			String selectText = " <el-select v-model="+vmode+" placeholder='请选择'>"; //v-model="+keyname+"
 			List<TextdictInfo> optionList = textdictInfo.getTextInfo();
 			if(optionList!=null && optionList.size()>=1){
 				for (int i= 0 ; i<optionList.size();i++)
@@ -195,24 +196,22 @@ public class TextdictInfoController extends BladeController {
 			List<TextdictInfo> optionList = textdictInfo.getTextInfo();
 			if(optionList!=null && optionList.size()>=1){
 				for (int i= 0 ; i<optionList.size();i++)
-					radioText +=" <el-radio v-model="+keyname+" label="+i+">"+optionList.get(i).getDictValue()+"</el-radio>";
+					radioText +=" <el-radio  label="+i+">"+optionList.get(i).getDictValue()+"</el-radio>";
 			}
 			radioText += "</template>";
 			element.empty().append(radioText);
 		}else if(textdictInfo.getTextId().equals("checkbox")){ // 多选框
-			String checkbox = " <el-checkbox-group v-model="+keyname+" placeholder='请选择'>";
+			String checkbox = "";
 			List<TextdictInfo> optionList = textdictInfo.getTextInfo();
 			if(optionList!=null && optionList.size()>=1){
 				for (int i= 0 ; i<optionList.size();i++)
-					checkbox +="<el-checkbox label="+optionList.get(i).getDictValue()+"></el-checkbox>";
+					checkbox +="<el-checkbox>"+optionList.get(i).getDictValue()+"</el-checkbox>";
 			}
-			checkbox += "</el-checkbox-group>";
 			element.empty().append(checkbox);
 		}else if(textdictInfo.getTextId().equals("date")){ // 日期
-			element.empty().append("<el-date-picker type='date' format='YYYY年MM月DD日' @focus='getInformation("+oncklickText+")' placeholder="+placeholder+" keyname="+keyname+" weighing="+weighing+"  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+trindex+" tdIndex="+tdindex+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'   placeholder='"+placeholder+"'> </el-date-picker>");
+			element.empty().append("<el-date-picker v-model="+vmode+" type='date' format='YYYY年MM月DD日' @focus='getInformation("+oncklickText+")' placeholder="+placeholder+" keyname="+keyname+" weighing="+weighing+"  @contextmenu.prevent.native='RightClick("+parm+")' trIndex="+trindex+" tdIndex="+tdindex+"  x1="+x1+" x2="+x2+" y1="+y1+" y2="+y2+" style='width:100%;height:100%'   placeholder='"+placeholder+"'> </el-date-picker>");
 		}else if(textdictInfo.getTextId().equals("daterange")){ // 时间段
-
-			element.empty().append("<el-date-picker v-model="+keyname+"_group1"+" type='date' format='YYYY年MM月DD日'></el-date-picker> 至 <el-date-picker type='date' format='YYYY年MM月DD日' v-model="+keyname+"_group2"+"></el-date-picker>");
+			element.empty().append("<el-date-picker  type='date' format='YYYY年MM月DD日'></el-date-picker> 至 <el-date-picker type='date' format='YYYY年MM月DD日' ></el-date-picker>");
 		}
 
 		File writefile = new File(wbsTreePrivate.getHtmlUrl());

+ 1 - 1
blade-service/blade-manager/src/main/java/org/springblade/manager/mapper/ExcelTabMapper.java

@@ -50,7 +50,7 @@ public interface ExcelTabMapper extends BaseMapper<ExcelTab> {
 	 * @param tenantId
 	 * @return
 	 */
-	List<ExceTabTreVO> tabLazyTree(String tenantId, Long modeId,Long parentId);
+	List<ExceTabTreVO> tabLazyTree(String tenantId, Long modeId,String parentId);
 
 	List<ExceTabTreVO> tabLazyTreeAll(String tenantId, Long modeId,String name);
 

+ 4 - 2
blade-service/blade-manager/src/main/java/org/springblade/manager/mapper/ExcelTabMapper.xml

@@ -85,7 +85,7 @@
         select * from (
                  SELECT a.project_id                                as id,
                         CONCAT_WS("_", b.project_name, a.full_name) as wbsName,
-                        1                                           as wbsType
+                        2                                           as wbsType
                  from m_wbs_tree_private a,
                       m_project_info b
                  where a.is_deleted = 0
@@ -96,7 +96,9 @@
                  SELECT id, c.wbs_name, 1 as wbsType
                  FROM m_wbs_info c
                  where c.is_deleted = 0
-             )d where 1=1
+            UNION ALL
+                SELECT id,wbs_name, 1 as wbsType from m_wbs_info where is_deleted=0
+        )d where 1=1
         <if test="wbstype!=null and wbstype!=''">
             and d.wbsType = #{wbstype}
         </if>

+ 3 - 0
blade-service/blade-manager/src/main/java/org/springblade/manager/service/IExcelTabService.java

@@ -71,4 +71,7 @@ public interface IExcelTabService extends BaseService<ExcelTab> {
 	 * @return
 	 */
 	List<WbsTreeVO> lazyTree(String wbsId, String tenantId, Long parentId);
+
+
+
 }

+ 1 - 0
blade-service/pom.xml

@@ -23,6 +23,7 @@
         <module>blade-user</module>
         <module>blade-manager</module>
         <module>blade-business</module>
+        <module>blade-e-visa</module>
     </modules>
 
     <dependencies>

+ 0 - 1
pom.xml

@@ -39,7 +39,6 @@
         <module>blade-plugin-api</module>
         <module>blade-service</module>
         <module>blade-service-api</module>
-        <module>blade-service/blade-e-visa</module>
     </modules>
 
     <dependencyManagement>