|  | @@ -7,6 +7,24 @@ const dsk = (function () {
 | 
	
		
			
				|  |  |          { key: 'item', value: 3, name: '单项工程' },
 | 
	
		
			
				|  |  |          { key: 'unit', value: 4, name: '单位工程' },
 | 
	
		
			
				|  |  |      ];
 | 
	
		
			
				|  |  | +    const DefaultFileType = [
 | 
	
		
			
				|  |  | +        { key: 'submission', value: 1, name: '投标' },
 | 
	
		
			
				|  |  | +        { key: 'invitation', value: 2, name: '招标/预算' },
 | 
	
		
			
				|  |  | +        { key: 'control', value: 3, name: '控制价' },
 | 
	
		
			
				|  |  | +        { key: 'change_budget', value: 4, name: '变更预算' },
 | 
	
		
			
				|  |  | +        { key: 'estimate', value: 5, name: '概算' },
 | 
	
		
			
				|  |  | +        { key: 'settlement', value: 10, name: '结算' },
 | 
	
		
			
				|  |  | +        { key: 'gusuan', value: 15, name: '估算(可行性估算)' },
 | 
	
		
			
				|  |  | +        { key: 'suggest_gusuan', value: 16, name: '建议估算' },
 | 
	
		
			
				|  |  | +        { key: 'three_bill_budget', value: 18, name: '三级清单预算' },
 | 
	
		
			
				|  |  | +        { key: 'bills_budget', value: 19, name: '清单预算' },
 | 
	
		
			
				|  |  | +    ];
 | 
	
		
			
				|  |  | +    // todo 每个编办下,文件类型对应的值不同,待需求整理数据
 | 
	
		
			
				|  |  | +    const CompilationFileType = [
 | 
	
		
			
				|  |  | +        { compliationId: '5de61133d46f6f000d15d347', name: '全国公路(2018)', fileType: DefaultFileType },
 | 
	
		
			
				|  |  | +        { compliationId: '63f31fe113566500140e4902', name: '广东公路(2018)', fileType: DefaultFileType },
 | 
	
		
			
				|  |  | +        { compliationId: '66b1f3f6ad66620013c13883', name: '浙江公路(2025)', fileType: DefaultFileType },
 | 
	
		
			
				|  |  | +    ];
 | 
	
		
			
				|  |  |      const projectTypeKey = (function(arr) {
 | 
	
		
			
				|  |  |          const result = {};
 | 
	
		
			
				|  |  |          for (const a of arr) {
 | 
	
	
		
			
				|  | @@ -147,8 +165,11 @@ const dsk = (function () {
 | 
	
		
			
				|  |  |                  if (data.type === projectTypeKey.project) {
 | 
	
		
			
				|  |  |                      cur = parent;
 | 
	
		
			
				|  |  |                  } else {
 | 
	
		
			
				|  |  | +                    console.log(data);
 | 
	
		
			
				|  |  |                      const type = projectType.find(x => { return x.value === data.type; });
 | 
	
		
			
				|  |  | -                    const node = { type: type.value, type_str: type.name, dsk_id: data.ID, name: data.name, project_id: project.ID, compilation_id: compilation.ID };
 | 
	
		
			
				|  |  | +                    const FileType = CompilationFileType.find(x => { return x.compliationId === compilation.ID; }) || DefaultFileType;
 | 
	
		
			
				|  |  | +                    const pftype = data.property && data.property.file_type ? FileType.find(x => { return x.value === data.file_type; }) : null;
 | 
	
		
			
				|  |  | +                    const node = { type: type.value, type_str: type.name, file_type_str: pftype ? pftype.name : '', dsk_id: data.ID, name: data.name, project_id: project.ID, compilation_id: compilation.ID };
 | 
	
		
			
				|  |  |                      cur = subjectTree.addNode(node, parent);
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  |                  if (data.children) {
 | 
	
	
		
			
				|  | @@ -235,8 +256,9 @@ const dsk = (function () {
 | 
	
		
			
				|  |  |              SpreadJsObj.initSheet(this.subjectSheet, {
 | 
	
		
			
				|  |  |                  cols: [
 | 
	
		
			
				|  |  |                      {title: '选择', field: 'selected', hAlign: 1, width: 60, formatter: '@', cellType: 'checkbox'},
 | 
	
		
			
				|  |  | -                    {title: '项目/分段名称', field: 'name', hAlign: 0, width: 740, formatter: '@', cellType: 'tree'},
 | 
	
		
			
				|  |  | -                    {title: '类型', field: 'type_str', hAlign: 0, width: 80, formatter: '@' },
 | 
	
		
			
				|  |  | +                    {title: '项目/分段名称', field: 'name', hAlign: 0, width: 660, formatter: '@', cellType: 'tree'},
 | 
	
		
			
				|  |  | +                    {title: '项目类型', field: 'file_type_str', hAlign: 1, width: 80, formatter: '@' },
 | 
	
		
			
				|  |  | +                    {title: '类型', field: 'type_str', hAlign: 1, width: 80, formatter: '@' },
 | 
	
		
			
				|  |  |                  ],
 | 
	
		
			
				|  |  |                  emptyRows: 0,
 | 
	
		
			
				|  |  |                  headRows: 1,
 |