对接文件删除
parent
c9ac2204df
commit
e2d229241d
|
@ -7,6 +7,7 @@ import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
import com.zcloud.aspect.DockAnnotation;
|
import com.zcloud.aspect.DockAnnotation;
|
||||||
import com.zcloud.util.*;
|
import com.zcloud.util.*;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
@ -247,6 +248,7 @@ public class ImgFilesController extends BaseController {
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value="/delete")
|
@RequestMapping(value="/delete")
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
|
@DockAnnotation
|
||||||
public Object delete() throws Exception{
|
public Object delete() throws Exception{
|
||||||
Map<String,String> map = new HashMap<String,String>();
|
Map<String,String> map = new HashMap<String,String>();
|
||||||
String errInfo = "success";
|
String errInfo = "success";
|
||||||
|
@ -256,6 +258,7 @@ public class ImgFilesController extends BaseController {
|
||||||
File file = new File(PathUtil.getProjectpath()+pd.getString("FILEPATH"));
|
File file = new File(PathUtil.getProjectpath()+pd.getString("FILEPATH"));
|
||||||
file.delete();
|
file.delete();
|
||||||
imgfilesService.delete(pd);
|
imgfilesService.delete(pd);
|
||||||
|
map.put("dockData", JSON.toJSONString(pd));
|
||||||
map.put("result", errInfo); //返回结果
|
map.put("result", errInfo); //返回结果
|
||||||
return map;
|
return map;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue