|
@@ -318,7 +318,6 @@ export class textbookServer {
|
|
|
let isDate = false;
|
|
|
// 监测空值
|
|
|
list?.forEach((item: Parse.Object) => {
|
|
|
- // arr.add(item.get(filed))
|
|
|
if (
|
|
|
isDate ||
|
|
|
Object.prototype.toString.call(item.get(filed)).indexOf('Date') != -1
|
|
@@ -341,7 +340,7 @@ export class textbookServer {
|
|
|
let query = new Parse.Query('EduTextbook');
|
|
|
query.notEqualTo('isDeleted', true);
|
|
|
query.notEqualTo('discard', true);
|
|
|
- query.equalTo('render', true);
|
|
|
+ // query.equalTo('render', true);
|
|
|
query.select(
|
|
|
'title',
|
|
|
'childrens.ISBN',
|
|
@@ -351,22 +350,42 @@ export class textbookServer {
|
|
|
'childrens.editionUnit',
|
|
|
'inviteUnit',
|
|
|
'user.department',
|
|
|
- 'department.branch'
|
|
|
+ 'department.branch',
|
|
|
+ 'code',
|
|
|
+ // 'eduProcess.profileSubmitted',
|
|
|
+ 'eduProcess.profileSubmitted.email',
|
|
|
+ 'eduProcess.profileSubmitted.user.name',
|
|
|
+ 'eduProcess.profileSubmitted.user.phone'
|
|
|
);
|
|
|
query.limit(3000);
|
|
|
- query.containedIn('status', ['103', '200', '201', '400']);
|
|
|
+ // query.containedIn('status', ['102','103', '200', '201', '400']);
|
|
|
// query.containedIn('status',['400'])
|
|
|
+ query.containedIn('objectId',updateDept.list5)
|
|
|
let data = await query.find();
|
|
|
- let table = `<table border="1px" cellspacing="0" cellpadding="0">
|
|
|
+ // let table = `<table border="1px" cellspacing="0" cellpadding="0">
|
|
|
+ // <thead>
|
|
|
+ // <tr>
|
|
|
+ // <th>序号</th>
|
|
|
+ // <th>申报教材名称</th>
|
|
|
+ // <th>第一主编/作者</th>
|
|
|
+ // <th>ISBN</th>
|
|
|
+ // <th>出版单位</th>
|
|
|
+ // <th>所属院校</th>
|
|
|
+ // <th>最新印次和时间</th>
|
|
|
+ // </tr>
|
|
|
+ // </thead>
|
|
|
+ // <tbody>
|
|
|
+ // `;
|
|
|
+ let table = `<table border="1px" cellspacing="0" cellpadding="0">
|
|
|
<thead>
|
|
|
<tr>
|
|
|
<th>序号</th>
|
|
|
<th>申报教材名称</th>
|
|
|
- <th>第一主编/作者</th>
|
|
|
- <th>ISBN</th>
|
|
|
- <th>出版单位</th>
|
|
|
- <th>所属院校</th>
|
|
|
- <th>最新印次和时间</th>
|
|
|
+ <th>code</th>
|
|
|
+ <th>所属单位</th>
|
|
|
+ <th>单位联系人</th>
|
|
|
+ <th>联系人电话</th>
|
|
|
+ <th>联系人邮箱</th>
|
|
|
</tr>
|
|
|
</thead>
|
|
|
<tbody>
|
|
@@ -375,80 +394,73 @@ export class textbookServer {
|
|
|
for (var row = 0; row < data.length; row++) {
|
|
|
// console.log(data[row].get('user')?.get('department'));
|
|
|
let inviteUnit = data[row]?.get('inviteUnit');
|
|
|
- if (
|
|
|
- data[row]?.get('department')?.get('branch') == '省级教育行政部门' ||
|
|
|
- data[row]?.get('department')?.get('branch') ==
|
|
|
- '有关部门(单位)教育司(局)'
|
|
|
- ) {
|
|
|
- let parentMap = await this.formatNode(
|
|
|
- data[row].get('user')?.get('department')?.id
|
|
|
- );
|
|
|
- inviteUnit = parentMap[2]?.title;
|
|
|
- }
|
|
|
+ // if (
|
|
|
+ // data[row]?.get('department')?.get('branch') == '省级教育行政部门' ||
|
|
|
+ // data[row]?.get('department')?.get('branch') ==
|
|
|
+ // '有关部门(单位)教育司(局)'
|
|
|
+ // ) {
|
|
|
+ // let parentMap = await this.formatNode(
|
|
|
+ // data[row].get('user')?.get('department')?.id
|
|
|
+ // );
|
|
|
+ // inviteUnit = parentMap[2]?.title;
|
|
|
+ // }
|
|
|
_body += '<tr>';
|
|
|
_body += '<td>';
|
|
|
_body += `${row + 1}`;
|
|
|
_body += '</td>';
|
|
|
|
|
|
- // _body += '<td>';
|
|
|
- // _body += ` ${data[row].get('code') || ''}`;
|
|
|
- // _body += '</td>';
|
|
|
-
|
|
|
_body += '<td>';
|
|
|
_body += ` ${data[row].get('title') || '-'}`;
|
|
|
_body += '</td>';
|
|
|
|
|
|
- // _body += '<td>';
|
|
|
- // _body += ` ${(data[row].get("discipline")?.code || "") + '/' + (data[row]?.get("discipline")?.name || "")}`;
|
|
|
- // _body += '</td>';
|
|
|
+ _body += '<td>';
|
|
|
+ _body += ` ${data[row].get('code') || ''}`;
|
|
|
+ _body += '</td>';
|
|
|
|
|
|
_body += '<td>';
|
|
|
- _body += `${this.fromatFiled(data[row]?.get('childrens'), 'author')}`;
|
|
|
+ _body += ` ${data[row].get('inviteUnit') || ''}`;
|
|
|
_body += '</td>';
|
|
|
|
|
|
_body += '<td>';
|
|
|
- _body += ` ${this.fromatFiled(
|
|
|
- data[row]?.get('childrens'),
|
|
|
- 'ISBN'
|
|
|
- )}`;
|
|
|
+ _body += ` ${data[row]?.get('eduProcess')?.get('profileSubmitted')?.get('user')?.get('name') || ''}`;
|
|
|
+ _body += '</td>';
|
|
|
+
|
|
|
+ _body += '<td>';
|
|
|
+ _body += ` ${data[row]?.get('eduProcess')?.get('profileSubmitted')?.get('user')?.get('phone') || ''}`;
|
|
|
+ _body += '</td>';
|
|
|
+
|
|
|
+ _body += '<td>';
|
|
|
+ _body += ` ${data[row]?.get('eduProcess')?.get('profileSubmitted')?.get('email') || ''}`;
|
|
|
_body += '</td>';
|
|
|
|
|
|
// _body += '<td>';
|
|
|
- // _body += `${
|
|
|
- // data[row]?.get('type') == '单本'
|
|
|
- // ? '单本'
|
|
|
- // : '全册 - ' + data[row]?.get('typeNumber') || '-'
|
|
|
- // }`;
|
|
|
+ // _body += `${this.fromatFiled(data[row]?.get('childrens'), 'author')}`;
|
|
|
// _body += '</td>';
|
|
|
|
|
|
// _body += '<td>';
|
|
|
- // _body += `${data[row]?.get('approval') || '-'}`;
|
|
|
+ // _body += ` ${this.fromatFiled(
|
|
|
+ // data[row]?.get('childrens'),
|
|
|
+ // 'ISBN'
|
|
|
+ // )}`;
|
|
|
// _body += '</td>';
|
|
|
|
|
|
- _body += '<td>';
|
|
|
- _body += `${this.fromatFiled(
|
|
|
- data[row]?.get('childrens'),
|
|
|
- 'editionUnit'
|
|
|
- )}`;
|
|
|
- _body += '</td>';
|
|
|
-
|
|
|
// _body += '<td>';
|
|
|
- // _body += ` ${this.fromatFiled(
|
|
|
+ // _body += `${this.fromatFiled(
|
|
|
// data[row]?.get('childrens'),
|
|
|
- // 'editionFirst'
|
|
|
+ // 'editionUnit'
|
|
|
// )}`;
|
|
|
// _body += '</td>';
|
|
|
|
|
|
- _body += '<td>';
|
|
|
- _body += `${inviteUnit}`;
|
|
|
- _body += '</td>';
|
|
|
+ // _body += '<td>';
|
|
|
+ // _body += `${inviteUnit}`;
|
|
|
+ // _body += '</td>';
|
|
|
|
|
|
- _body += '<td>';
|
|
|
- _body += `${this.fromatFiled(
|
|
|
- data[row]?.get('childrens'),
|
|
|
- 'printDate'
|
|
|
- )}`;
|
|
|
- _body += '</td>';
|
|
|
+ // _body += '<td>';
|
|
|
+ // _body += `${this.fromatFiled(
|
|
|
+ // data[row]?.get('childrens'),
|
|
|
+ // 'printDate'
|
|
|
+ // )}`;
|
|
|
+ // _body += '</td>';
|
|
|
|
|
|
_body += '</tr>';
|
|
|
}
|