package com.action.ImgList;

import ToolClass.JSON.Transformations_JSON;
import ToolClass.Verify_HTTP;
import com.sqlConnect.dml.T_imginfoDml;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.UnsupportedEncodingException;

/**
 * @program: WebUploader
 * @description: 取出图片地址
 * @author: Dai Yuanchuan
 * @create: 2018-07-11 11:38
 **/
@Controller
@RequestMapping(value = "/Pictureset")
public class Pictureset {

    /**
     * 获取图片集对应的图片地址
     * @param ImgListID
     * @param request
     * @param response
     * @return
     * @throws UnsupportedEncodingException
     */
    @RequestMapping(value = "/PictureAddress",method=RequestMethod.POST)
    public @ResponseBody
    net.sf.json.JSONArray PictureAddress(String ImgListID, HttpServletRequest request, HttpServletResponse response) throws UnsupportedEncodingException {
        request.setCharacterEncoding("utf-8");
        response.setContentType("text/html;charset=utf-8");
        // 验证连接
        if(new Verify_HTTP().Islegal(request)){
           return new Transformations_JSON().List_Transformations_JSON(new T_imginfoDml().According_toImgListID_Inquire(ImgListID));

        }else{
            // 链接非法
            return new Transformations_JSON()
                    .String_Transformations_JSON("[{\"errMsg\":\"Current connection is unlawful\"}]");
        }
    }
}
最近下载更多
pzhyzs  LV2 2023年5月31日
666666777888  LV6 2022年11月6日
2511952410  LV9 2022年10月12日
bin54321  LV7 2022年4月9日
木易雨山  LV7 2021年11月2日
羞羞小子  LV13 2021年4月10日
1254859490  LV2 2021年3月3日
helloworldsbsb  LV7 2020年12月27日
123456nty  LV36 2020年11月26日
17600446733  LV21 2020年6月24日
最近浏览更多
1358849392  LV21 4月12日
WBelong  LV7 2023年12月25日
潘潘123456  LV2 2023年12月24日
shuangfu  LV24 2023年12月2日
kele200  LV3 2023年10月31日
19137715150  LV1 2023年6月18日
ice_candy  LV1 2023年6月13日
pzhyzs  LV2 2023年5月31日
xuyy14gg 2023年5月22日
暂无贡献等级
azursswx 2023年2月13日
暂无贡献等级
顶部 客服 微信二维码 底部
>扫描二维码关注最代码为好友扫描二维码关注最代码为好友