MaiXinRong 6 часов назад
Родитель
Сommit
81df0c168d

+ 2 - 2
app/const/project_setting.js

@@ -63,7 +63,7 @@ const colSet = {
         { field: 'budget_std', name: '概预算标准', fixed: ['show'] },
         { field: 'budget_std', name: '概预算标准', fixed: ['show'] },
         { field: 'tender_count', name: '标段个数', fixed: [] },
         { field: 'tender_count', name: '标段个数', fixed: [] },
         { field: 'file_count', name: '文件个数', fixed: [] },
         { field: 'file_count', name: '文件个数', fixed: [] },
-        { field: 'contract_count', name: '合同个数', fixed: [] },
+        { field: 'contract_count1', name: '合同个数', fixed: [] },
         { field: 'management', name: '管理单位', fixed: ['show'] },
         { field: 'management', name: '管理单位', fixed: ['show'] },
         { field: 'create_time', name: '创建时间', fixed: [] },
         { field: 'create_time', name: '创建时间', fixed: [] },
         { field: 'control', name: '操作', fixed: ['show'] },
         { field: 'control', name: '操作', fixed: ['show'] },
@@ -91,7 +91,7 @@ const defaultProjectColSet = {
         { field: 'budget_std', show: 1, alias: '' },
         { field: 'budget_std', show: 1, alias: '' },
         { field: 'tender_count', show: 1, alias: '' },
         { field: 'tender_count', show: 1, alias: '' },
         { field: 'file_count', show: 1, alias: '' },
         { field: 'file_count', show: 1, alias: '' },
-        { field: 'contract_count', show: 1, alias: '' },
+        { field: 'contract_count1', show: 1, alias: '' },
         { field: 'management', show: 1, alias: '' },
         { field: 'management', show: 1, alias: '' },
         { field: 'create_time', show: 1, alias: '' },
         { field: 'create_time', show: 1, alias: '' },
         { field: 'control', show: 1, alias: '' },
         { field: 'control', show: 1, alias: '' },

+ 1 - 0
app/controller/sub_proj_controller.js

@@ -21,6 +21,7 @@ module.exports = app => {
             for (const p of projectList) {
             for (const p of projectList) {
                 p.tender_count = await this.ctx.service.tender.count({ spid: p.id });
                 p.tender_count = await this.ctx.service.tender.count({ spid: p.id });
                 p.contract_count = await this.ctx.service.contract.count({ spid: p.id });
                 p.contract_count = await this.ctx.service.contract.count({ spid: p.id });
+                p.contract_count1 = await this.ctx.service.contract.count({ spid: p.id, contract_type: 1 });
                 p.file_count = await this.ctx.service.file.count({ spid: p.id, is_deleted: 0 });
                 p.file_count = await this.ctx.service.file.count({ spid: p.id, is_deleted: 0 });
             }
             }
         }
         }

+ 3 - 3
app/public/js/sub_project.js

@@ -32,7 +32,7 @@ $(document).ready(function() {
                 if (colSetCache.budget_std.show) html.push('<th width="8%">', colSetCache.budget_std.alias, '</th>');
                 if (colSetCache.budget_std.show) html.push('<th width="8%">', colSetCache.budget_std.alias, '</th>');
                 if (colSetCache.tender_count.show) html.push('<th width="5%">', colSetCache.tender_count.alias, '</th>');
                 if (colSetCache.tender_count.show) html.push('<th width="5%">', colSetCache.tender_count.alias, '</th>');
                 if (colSetCache.file_count.show) html.push('<th width="5%">', colSetCache.file_count.alias, '<i class="fa fa-question-circle text-primary" data-placement="bottom" data-toggle="tooltip" data-original-title="指资料归集的所有文件个数"></i>', '</th>');
                 if (colSetCache.file_count.show) html.push('<th width="5%">', colSetCache.file_count.alias, '<i class="fa fa-question-circle text-primary" data-placement="bottom" data-toggle="tooltip" data-original-title="指资料归集的所有文件个数"></i>', '</th>');
-                if (colSetCache.contract_count.show) html.push('<th width="5%">', colSetCache.contract_count.alias, '<i class="fa fa-question-circle text-primary" data-placement="bottom" data-toggle="tooltip" data-original-title="项目支出合同个数"></i>', '</th>');
+                if (colSetCache.contract_count1.show) html.push('<th width="5%">', colSetCache.contract_count1.alias, '<i class="fa fa-question-circle text-primary" data-placement="bottom" data-toggle="tooltip" data-original-title="项目支出合同个数"></i>', '</th>');
                 if (colSetCache.management.show) html.push('<th width="20%">', colSetCache.management.alias, '</th>');
                 if (colSetCache.management.show) html.push('<th width="20%">', colSetCache.management.alias, '</th>');
                 if (colSetCache.create_time.show) html.push('<th width="8%">', colSetCache.create_time.alias, '</th>');
                 if (colSetCache.create_time.show) html.push('<th width="8%">', colSetCache.create_time.alias, '</th>');
                 if (colSetCache.control.show && canEdit) html.push('<th width="20%">', colSetCache.control.alias, '</th>');
                 if (colSetCache.control.show && canEdit) html.push('<th width="20%">', colSetCache.control.alias, '</th>');
@@ -75,7 +75,7 @@ $(document).ready(function() {
                 if (node.is_folder) {
                 if (node.is_folder) {
                     if (colSetCache.tender_count.show) html.push(`<td class="text-center"></td>`);
                     if (colSetCache.tender_count.show) html.push(`<td class="text-center"></td>`);
                     if (colSetCache.file_count.show) html.push(`<td class="text-center"></td>`);
                     if (colSetCache.file_count.show) html.push(`<td class="text-center"></td>`);
-                    if (colSetCache.contract_count.show) html.push(`<td class="text-center"></td>`);
+                    if (colSetCache.contract_count1.show) html.push(`<td class="text-center"></td>`);
                     if (colSetCache.management.show) html.push(`<td class="text-center"></td>`);
                     if (colSetCache.management.show) html.push(`<td class="text-center"></td>`);
                     if (colSetCache.create_time.show) html.push(`<td class="text-center"></td>`);
                     if (colSetCache.create_time.show) html.push(`<td class="text-center"></td>`);
                 } else {
                 } else {
@@ -84,7 +84,7 @@ $(document).ready(function() {
                     // 文件个数
                     // 文件个数
                     if (colSetCache.file_count.show) html.push(`<td class="text-center">${node.file_count}</td>`);
                     if (colSetCache.file_count.show) html.push(`<td class="text-center">${node.file_count}</td>`);
                     // 合同个数
                     // 合同个数
-                    if (colSetCache.contract_count.show) html.push(`<td class="text-center">${node.contract_count}</td>`);
+                    if (colSetCache.contract_count1.show) html.push(`<td class="text-center">${node.contract_count1}</td>`);
                     if (colSetCache.management.show) {
                     if (colSetCache.management.show) {
                         if (canEdit) {
                         if (canEdit) {
                             html.push(`<td class="text-center">${node.management || ''}<a class="ml-2" href="javascript: void(0)" name="set-management"><i class="fa fa-pencil-square-o "></i></a>${node.management ? '<a class="ml-2" href="javascript: void(0)" name="refresh-management"><i class="fa fa-refresh "></i></a>': ''}</td>`);
                             html.push(`<td class="text-center">${node.management || ''}<a class="ml-2" href="javascript: void(0)" name="set-management"><i class="fa fa-pencil-square-o "></i></a>${node.management ? '<a class="ml-2" href="javascript: void(0)" name="refresh-management"><i class="fa fa-refresh "></i></a>': ''}</td>`);

+ 0 - 1
app/view/sub_proj/modal.ejs

@@ -256,7 +256,6 @@
                     <% } %>
                     <% } %>
                     </tbody>
                     </tbody>
                 </table>
                 </table>
-                <div class="text-danger">请勿全选(页面显示不下);谨慎修改别名(修改后,各页面概念将不一致)</div>
             </div>
             </div>
             <form class="modal-footer" action="/subproj/col-set" method="post" onsubmit="return onSetCol();">
             <form class="modal-footer" action="/subproj/col-set" method="post" onsubmit="return onSetCol();">
                 <input type="hidden" name="_csrf_j" value="<%= ctx.csrf %>">
                 <input type="hidden" name="_csrf_j" value="<%= ctx.csrf %>">