| | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.aspose.words.License; |
| | | import com.aspose.words.SaveFormat; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | |
| | | public IPage<InsOrderPlanVO> selectInsOrderPlanList(Page page, InsOrderPlanDTO insOrderPlanDTO) { |
| | | // todo: 仅看自己或者实验室 |
| | | //获取当前人所属实验室id |
| | | |
| | | String laboratory = null; |
| | | |
| | | String userName = null; |
| | | Integer userId = null; |
| | | if (ObjectUtil.isNotEmpty(insOrderPlanDTO.getUserId())) { |
| | |
| | | |
| | | //设置样式 |
| | | TableStyle tableStyle = new TableStyle(); |
| | | for (int i = 1; i <= max; i++) { |
| | | // 根据减压那结果个数修改长度 |
| | | switch (i) { |
| | | case 1: |
| | | tableStyle.setColWidths(new int[]{650, 2900, 850, 2300, 2100, 1200}); |
| | | break; |
| | | case 2: |
| | | tableStyle.setColWidths(new int[]{650, 2700, 850, 2200, 1200, 1200, 1200}); |
| | | break; |
| | | case 3: |
| | | tableStyle.setColWidths(new int[]{650, 2700, 850, 1600, 1000, 1000, 1000, 1200}); |
| | | break; |
| | | case 4: |
| | | tableStyle.setColWidths(new int[]{650, 2400, 850, 1500, 850, 850, 850, 850, 1200}); |
| | | break; |
| | | case 5: |
| | | tableStyle.setColWidths(new int[]{650, 2200, 850, 1350, 750, 750, 750, 750, 750, 1200}); |
| | | break; |
| | | if(max<=5){ |
| | | for (int i = 1; i <= max; i++) { |
| | | // 根据检验结果个数修改长度 |
| | | switch (i) { |
| | | case 1: |
| | | tableStyle.setColWidths(new int[]{650, 2900, 850, 2300, 2100, 1200}); |
| | | break; |
| | | case 2: |
| | | tableStyle.setColWidths(new int[]{650, 2700, 850, 2200, 1200, 1200, 1200}); |
| | | break; |
| | | case 3: |
| | | tableStyle.setColWidths(new int[]{650, 2700, 850, 1600, 1000, 1000, 1000, 1200}); |
| | | break; |
| | | case 4: |
| | | tableStyle.setColWidths(new int[]{650, 2400, 850, 1500, 850, 850, 850, 850, 1200}); |
| | | break; |
| | | case 5: |
| | | tableStyle.setColWidths(new int[]{650, 2200, 850, 1350, 750, 750, 750, 750, 750, 1200}); |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | |
| | | tableStyle.setWidth("10000"); |
| | | tableStyle.setAlign(TableRowAlign.CENTER); |
| | | BorderStyle borderStyle = new BorderStyle(); |