|
@@ -60,7 +60,7 @@ function serializeWhere(params) {
|
|
|
|
|
|
// scan
|
|
|
function saveUploadInfo(params) {
|
|
|
- const sql = `INSERT INTO scan (taskId, schoolId, semesterId, examId, courseCode, courseName, frontOriginImgPath, versoOriginImgPath, studentCode, ocrArea,fileType,roomOrClass,batchNo, isFormal, clientUserId, clientUsername, clientUserLoginTime, isUpload,createdTime, finishTime) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)`;
|
|
|
+ const sql = `INSERT INTO scan (taskId, schoolId, semesterId, examId, courseCode, courseName, frontOriginImgPath, versoOriginImgPath, studentCode, ocrArea,fileTypeId,fileTypeName,roomOrClass,batchNo, isFormal, clientUserId, clientUsername, clientUserLoginTime, isUpload,createdTime, finishTime) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)`;
|
|
|
const datas = [
|
|
|
params.taskId,
|
|
|
params.schoolId,
|
|
@@ -72,7 +72,8 @@ function saveUploadInfo(params) {
|
|
|
params.versoOriginImgPath,
|
|
|
params.studentCode,
|
|
|
params.ocrArea,
|
|
|
- params.fileType,
|
|
|
+ params.fileTypeId,
|
|
|
+ params.fileTypeName,
|
|
|
params.roomOrClass,
|
|
|
params.batchNo,
|
|
|
params.isFormal,
|
|
@@ -95,7 +96,7 @@ function saveUploadInfo(params) {
|
|
|
|
|
|
function batchSaveUploadInfo(datas) {
|
|
|
return new Promise((resolve, reject) => {
|
|
|
- const sql = `INSERT INTO scan (taskId, schoolId, semesterId, examId, courseCode, courseName, frontOriginImgPath, versoOriginImgPath, studentCode, ocrArea,fileType,roomOrClass,batchNo, isFormal, clientUserId, clientUsername, clientUserLoginTime, isUpload,createdTime, finishTime) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)`;
|
|
|
+ const sql = `INSERT INTO scan (taskId, schoolId, semesterId, examId, courseCode, courseName, frontOriginImgPath, versoOriginImgPath, studentCode, ocrArea,fileTypeId,fileTypeName,roomOrClass,batchNo, isFormal, clientUserId, clientUsername, clientUserLoginTime, isUpload,createdTime, finishTime) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)`;
|
|
|
db.serialize(() => {
|
|
|
const stmt = db.prepare(sql);
|
|
|
|