提交 8f350363 authored 作者: 陆's avatar

商品属性添加了定时器

上级 3373dd18
...@@ -2,7 +2,6 @@ package com.platform.entity; ...@@ -2,7 +2,6 @@ package com.platform.entity;
import cn.hutool.core.codec.Base64; import cn.hutool.core.codec.Base64;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import sun.misc.BASE64Decoder;
import java.io.*; import java.io.*;
...@@ -61,25 +60,25 @@ public class BASE64DecodedMultipartFile implements MultipartFile { ...@@ -61,25 +60,25 @@ public class BASE64DecodedMultipartFile implements MultipartFile {
new FileOutputStream(dest).write(imgContent); new FileOutputStream(dest).write(imgContent);
} }
public static MultipartFile base64ToMultipart(String base64) { // public static MultipartFile base64ToMultipart(String base64) {
try { // try {
String[] baseStrs = base64.split(","); // String[] baseStrs = base64.split(",");
//
BASE64Decoder decoder = new BASE64Decoder(); // BASE64Decoder decoder = new BASE64Decoder();
byte[] b = new byte[0]; // byte[] b = new byte[0];
b = decoder.decodeBuffer(baseStrs[1]); // b = decoder.decodeBuffer(baseStrs[1]);
//
for (int i = 0; i < b.length; ++i) { // for (int i = 0; i < b.length; ++i) {
if (b[i] < 0) { // if (b[i] < 0) {
b[i] += 256; // b[i] += 256;
} // }
} // }
return new BASE64DecodedMultipartFile(b, baseStrs[0]); // return new BASE64DecodedMultipartFile(b, baseStrs[0]);
} catch (IOException e) { // } catch (IOException e) {
e.printStackTrace(); // e.printStackTrace();
return null; // return null;
} // }
} // }
public static File base64ToFile(String base64) { public static File base64ToFile(String base64) {
if(base64==null||"".equals(base64)) { if(base64==null||"".equals(base64)) {
......
...@@ -1256,6 +1256,7 @@ let vm = new Vue({ ...@@ -1256,6 +1256,7 @@ let vm = new Vue({
}, },
//商品参数 //商品参数
getAttrName(){ getAttrName(){
setTimeout(function (){
this.paramsters= [] this.paramsters= []
$.get('../attributes/queryAttrNames', res => { $.get('../attributes/queryAttrNames', res => {
let Attr = JSON.parse(res).list let Attr = JSON.parse(res).list
...@@ -1272,6 +1273,8 @@ let vm = new Vue({ ...@@ -1272,6 +1273,8 @@ let vm = new Vue({
vm.paramsters = Attr vm.paramsters = Attr
console.log(Attr) console.log(Attr)
}) })
},1300)
}, },
//限制输入 //限制输入
verifyInput(e){ verifyInput(e){
......
...@@ -10,6 +10,7 @@ import org.apache.poi.hssf.eventusermodel.dummyrecord.LastCellOfRowDummyRecord; ...@@ -10,6 +10,7 @@ import org.apache.poi.hssf.eventusermodel.dummyrecord.LastCellOfRowDummyRecord;
import org.apache.poi.hssf.eventusermodel.dummyrecord.MissingCellDummyRecord; import org.apache.poi.hssf.eventusermodel.dummyrecord.MissingCellDummyRecord;
import org.apache.poi.hssf.model.HSSFFormulaParser; import org.apache.poi.hssf.model.HSSFFormulaParser;
import org.apache.poi.hssf.record.*; import org.apache.poi.hssf.record.*;
import org.apache.poi.hssf.record.Record;
import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.poifs.filesystem.POIFSFileSystem; import org.apache.poi.poifs.filesystem.POIFSFileSystem;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论