feat: complete reverse engineering, standard Maven structure, detailed code annotations and IoT-M platform architecture
This commit is contained in:
1 parent
e8dc09fb3c
commit
cd6a4c70e7
3045 files changed
+566733
-1
No files matched your search
@@ -0,0 +1,21 @@
|
||||
package com.midm.controller.lib;
|
||||
|
||||
import com.mitac.cell.barcode.QrCode;
|
||||
import com.mitac.cell.io.McResource;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
@Controller
|
||||
public class BarcodeController {
|
||||
@RequestMapping(
|
||||
value = {"/barcode/qr/{code}"},
|
||||
method = {RequestMethod.GET}
|
||||
)
|
||||
public void qrCode(HttpServletResponse response, @PathVariable String code, @RequestParam(required = false) Integer size, @RequestParam(required = false) Integer margin, @RequestParam(required = false) Boolean encrypt) {
|
||||
McResource.copyToResponse(response, QrCode.toImage(code, size, margin));
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user