Commit d07c0dbc authored by sherlock's avatar sherlock

Merge branch 'dev_oracle_sherlock' into 'dev_oracle'

Dev oracle sherlock

See merge request root/atms!146
parents 3fc51e8f 19758794
...@@ -49,6 +49,11 @@ ...@@ -49,6 +49,11 @@
<groupId>org.springframework</groupId> <groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId> <artifactId>spring-jdbc</artifactId>
</dependency> </dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
<version>3.1.1.RELEASE</version>
</dependency>
<dependency> <dependency>
<groupId>org.springframework</groupId> <groupId>org.springframework</groupId>
<artifactId>spring-aspects</artifactId> <artifactId>spring-aspects</artifactId>
......
package pwc.taxtech.atms.controller;
import io.swagger.annotations.ApiOperation;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import pwc.taxtech.atms.common.message.ErrorMessage;
import pwc.taxtech.atms.dto.OperationResultDto;
import pwc.taxtech.atms.exception.ServiceException;
import pwc.taxtech.atms.service.impl.ExcelDataServiceImpl;
@RestController
@RequestMapping(value = "api/v1/excelData")
public class ExcelDataController {
private static final Logger logger = LoggerFactory.getLogger(ExcelDataController.class);
@Autowired
private ExcelDataServiceImpl excelDataService;
@ResponseBody
@ApiOperation(value = "导入报表数据")
@RequestMapping(value = "importExcelDataFile", method = RequestMethod.POST)
public OperationResultDto parseExcelData(@RequestParam MultipartFile file,
@RequestParam Long templateID,
@RequestParam String projectID){
try {
excelDataService.parseExcelData(file, templateID, projectID);
return OperationResultDto.success();
} catch (ServiceException e) {
return OperationResultDto.error(e.getMessage());
} catch (Exception e) {
logger.error("importTemplateExcelFile error.", e);
}
return OperationResultDto.error(ErrorMessage.SystemError);
}
}
...@@ -120,13 +120,13 @@ public class TemplateGroupController { ...@@ -120,13 +120,13 @@ public class TemplateGroupController {
@ApiOperation(value = "导入报表") @ApiOperation(value = "导入报表")
@RequestMapping(value = "importTemplateExcelFile", method = RequestMethod.POST) @RequestMapping(value = "importTemplateExcelFile", method = RequestMethod.POST)
public OperationResultDto importTemplateExcelFile(@RequestParam MultipartFile file, public OperationResultDto importTemplateExcelFile(@RequestParam MultipartFile file,
@RequestParam Long templateGroupId, @RequestParam Long templateGroupID,
@RequestParam String sheetList, @RequestParam String sheetList,
@RequestParam String tempFileName, @RequestParam String tempFileName,
@RequestParam String reportType, @RequestParam String reportType,
@RequestParam String filename) { @RequestParam String filename) {
try { try {
templateGroupService.importTemplateExcelFile(file, templateGroupId, reportType, sheetList); templateGroupService.importTemplateExcelFile(file, templateGroupID, reportType, sheetList);
return OperationResultDto.success(); return OperationResultDto.success();
} catch (ServiceException e) { } catch (ServiceException e) {
return OperationResultDto.error(e.getMessage()); return OperationResultDto.error(e.getMessage());
......
package pwc.taxtech.atms.service.impl;
import com.google.common.collect.Lists;
import org.apache.commons.lang3.StringUtils;
import org.apache.poi.ss.usermodel.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;
import pwc.taxtech.atms.common.message.ErrorMessage;
import pwc.taxtech.atms.exception.ServiceException;
import pwc.taxtech.atms.vat.dao.PeriodCellDataMapper;
import pwc.taxtech.atms.vat.dao.PeriodCellTemplateMapper;
import pwc.taxtech.atms.vat.dao.PeriodReportMapper;
import pwc.taxtech.atms.vat.entity.*;
import java.io.InputStream;
import java.util.Date;
import java.util.List;
@Service
public class ExcelDataServiceImpl extends AbstractService {
@Autowired
private PeriodCellTemplateMapper periodCellTemplateMapper;
@Autowired
private PeriodCellDataMapper periodCellDataMapper;
@Autowired
private PeriodReportMapper periodReportMapper;
public void parseExcelData(MultipartFile file, Long periodTemplateId, String projectId) throws ServiceException{
if (null == file) {
throw new ServiceException(ErrorMessage.NoFile);
}
try{
InputStream inputStream = file.getInputStream();
Workbook workbook = WorkbookFactory.create(inputStream);
Sheet sheet = workbook.getSheetAt(0);
Date now = new Date();
// insert a record into PERIOD_REPORT
PeriodReport pr = new PeriodReport();
pr.setProjectId(projectId);
pr.setCreateBy("Admin");
pr.setCreateTime(now);
pr.setPeriod(0);
pr.setTemplateId(periodTemplateId);
pr.setUpdateBy("Admin");
pr.setUpdateTime(now);
pr.setId(distributedIdService.nextId());
periodReportMapper.insertSelective(pr);
// get cell template according to templateId
PeriodCellTemplateExample pctExample = new PeriodCellTemplateExample();
pctExample.createCriteria().andReportTemplateIdEqualTo(periodTemplateId);
List<PeriodCellTemplate> templates = periodCellTemplateMapper.selectByExample(pctExample);
// save cell data into PERIOD_CELL_DATA
List<PeriodCellData> list = Lists.newArrayList();
for(PeriodCellTemplate template : templates){
Row r = sheet.getRow(template.getRowIndex());
Cell c = r.getCell(template.getColumnIndex());
if(StringUtils.isBlank(c.getStringCellValue())){
continue;
}
PeriodCellData periodCellData = new PeriodCellData();
periodCellData.setData(c.getStringCellValue());
periodCellData.setId(distributedIdService.nextId());
periodCellData.setCellTemplateId(template.getId());
periodCellData.setUpdateTime(now);
periodCellData.setCreateBy("Admin");
periodCellData.setCreateTime(now);
periodCellData.setPeriod(1);
periodCellData.setUpdateBy("Admin");
periodCellData.setFormulaExp(periodCellData.getData());
periodCellData.setProjectId(projectId);
periodCellData.setReportId(pr.getId());
list.add(periodCellData);
}
periodCellDataMapper.batchInsert(list);
// periodCellDataMapper.batchInsert2(list);
} catch (Exception e){
logger.error("importTemplateExcelFile error.", e);
throw new ServiceException(ErrorMessage.SystemError);
}
}
}
...@@ -75,9 +75,16 @@ public class OutputInvoiceServiceImpl { ...@@ -75,9 +75,16 @@ public class OutputInvoiceServiceImpl {
Organization organization = organizationMapper.selectByPrimaryKey(project.getOrganizationId()); Organization organization = organizationMapper.selectByPrimaryKey(project.getOrganizationId());
OutputInvoiceExample outputInvoiceExample = new OutputInvoiceExample(); OutputInvoiceExample outputInvoiceExample = new OutputInvoiceExample();
outputInvoiceExample.createCriteria().andXFSHEqualTo(organization.getTaxPayerNumber()).andKPZTEqualTo(OUTPUT_KPZT_YES). if(organization.getTaxPayerNumber() == null){
andKPRQBetween(DateUtils.getPeriodBegin(project.getYear(), queryDto.getPeriodStart()), outputInvoiceExample.createCriteria().andXFSHIsNull().andKPZTEqualTo(OUTPUT_KPZT_YES).
DateUtils.getPeriodEnd(project.getYear(), queryDto.getPeriodEnd())); andKPRQBetween(DateUtils.getPeriodBegin(project.getYear(), queryDto.getPeriodStart()),
DateUtils.getPeriodEnd(project.getYear(), queryDto.getPeriodEnd()));
} else {
outputInvoiceExample.createCriteria().andXFSHEqualTo(organization.getTaxPayerNumber()).andKPZTEqualTo(OUTPUT_KPZT_YES).
andKPRQBetween(DateUtils.getPeriodBegin(project.getYear(), queryDto.getPeriodStart()),
DateUtils.getPeriodEnd(project.getYear(), queryDto.getPeriodEnd()));
}
PageHelper.startPage(queryDto.getPageInfo().getPageIndex(), queryDto.getPageInfo().getPageSize()); PageHelper.startPage(queryDto.getPageInfo().getPageIndex(), queryDto.getPageInfo().getPageSize());
List<OutputInvoice> invoices = outputInvoiceMapper.selectByExample(outputInvoiceExample); List<OutputInvoice> invoices = outputInvoiceMapper.selectByExample(outputInvoiceExample);
......
...@@ -290,7 +290,8 @@ public class ReportGeneratorImpl { ...@@ -290,7 +290,8 @@ public class ReportGeneratorImpl {
//如果有正则匹配就进行更新公式解析 //如果有正则匹配就进行更新公式解析
// if (isFind) { // if (isFind) {
periodCellTemplateConfig.setParsedFormula(resultFormula); periodCellTemplateConfig.setParsedFormula(StringUtils.isNotBlank(resultFormula) ? resultFormula : null);
periodCellTemplateConfig.setFormula(StringUtils.isNotBlank(periodCellTemplateConfig.getFormula()) ? resultFormula : null);
periodCellTemplateConfigMapper.updateByPrimaryKeySelective(periodCellTemplateConfig); periodCellTemplateConfigMapper.updateByPrimaryKeySelective(periodCellTemplateConfig);
// } // }
...@@ -366,7 +367,7 @@ public class ReportGeneratorImpl { ...@@ -366,7 +367,7 @@ public class ReportGeneratorImpl {
if (data != null && data.equals("#VALUE!")) { if (data != null && data.equals("#VALUE!")) {
data = "0.0"; data = "0.0";
} }
//evaluator.evaluate(cell) //evaluator.evaluate(cell);
// if (cell.getCellTypeEnum().equals(CellType.NUMERIC)||cell.getCellTypeEnum().equals(CellType.FORMULA)) { // if (cell.getCellTypeEnum().equals(CellType.NUMERIC)||cell.getCellTypeEnum().equals(CellType.FORMULA)) {
// data = Double.toString(cell.getNumericCellValue()); // data = Double.toString(cell.getNumericCellValue());
// } else { // } else {
...@@ -393,6 +394,9 @@ public class ReportGeneratorImpl { ...@@ -393,6 +394,9 @@ public class ReportGeneratorImpl {
// periodFormulaBlockExample.createCriteria().andPeriodEqualTo(period) // periodFormulaBlockExample.createCriteria().andPeriodEqualTo(period)
// .andCellTemplateIdEqualTo(tempPeriodCellTemplate.get().getCellTemplateId()); // .andCellTemplateIdEqualTo(tempPeriodCellTemplate.get().getCellTemplateId());
if(StringUtils.isBlank(resultFormula)){
resultFormula = null;
}
// if (isFind) { // if (isFind) {
cellData.setFormulaExp(resultFormula); cellData.setFormulaExp(resultFormula);
// } else { // } else {
......
...@@ -85,11 +85,11 @@ public class JXFPMX extends FunctionBase implements FreeRefFunction { ...@@ -85,11 +85,11 @@ public class JXFPMX extends FunctionBase implements FreeRefFunction {
// List<InputVATInvoiceResultDto> inputInvoice = SpringContextUtil.inputVatInvoiceMapper.getInputVATInvoiceResultDto(dbName); // List<InputVATInvoiceResultDto> inputInvoice = SpringContextUtil.inputVatInvoiceMapper.getInputVATInvoiceResultDto(dbName);
List<InputInvoiceResultDto> inputInvoice = SpringContextUtil.inputInvoiceMapper.getInputInvoiceResultDto(); List<InputInvoiceResultDto> inputInvoice = SpringContextUtil.inputInvoiceMapper.getInputInvoiceResultDto();
if (!goodsName.equals("99")) { // if (!goodsName.equals("99")) {
inputInvoice = inputInvoice.stream() // inputInvoice = inputInvoice.stream()
.filter(a -> a.getInputInvoiceDetail() != null && StringUtils.isNotBlank(goodsName) && goodsName.equals(a.getInputInvoiceDetail().getSPMC())) // .filter(a -> a.getInputInvoiceDetail() != null && StringUtils.isNotBlank(goodsName) && goodsName.equals(a.getInputInvoiceDetail().getSPMC()))
.collect(Collectors.toList()); // .collect(Collectors.toList());
} // }
if (taxRateVal.compareTo(new BigDecimal("-1")) == 0) { if (taxRateVal.compareTo(new BigDecimal("-1")) == 0) {
inputInvoice = inputInvoice.stream() inputInvoice = inputInvoice.stream()
......
#log4j.debug = true log4j.debug = true
log4j.rootLogger=INFO,stdout,fileoutall,fileoutwarn,fileouterror log4j.rootLogger=INFO,stdout,fileoutall,fileoutwarn,fileouterror
log4j.appender.stdout=org.apache.log4j.ConsoleAppender log4j.appender.stdout=org.apache.log4j.ConsoleAppender
......
...@@ -110,6 +110,10 @@ public interface PeriodCellDataMapper extends MyVatMapper { ...@@ -110,6 +110,10 @@ public interface PeriodCellDataMapper extends MyVatMapper {
*/ */
int updateByPrimaryKey(PeriodCellData record); int updateByPrimaryKey(PeriodCellData record);
int batchInsert2(List<PeriodCellData> list);
int batchInsert(List<PeriodCellData> list);
@Select("<script>" + @Select("<script>" +
"SELECT " + "SELECT " +
" R.PERIOD, C.CELL_TEMPLATE_ID AS CELLTEMPLATEID, DATA " + " R.PERIOD, C.CELL_TEMPLATE_ID AS CELLTEMPLATEID, DATA " +
......
...@@ -7,18 +7,18 @@ import java.util.Date; ...@@ -7,18 +7,18 @@ import java.util.Date;
public class CellInvoiceDto { public class CellInvoiceDto {
String id; String id;
Integer period; Integer period;
Date invoiceDate; String invoiceDate;
String invoiceNumber; String invoiceNumber;
String invoiceCode; String invoiceCode;
BigDecimal amount; String amount;
BigDecimal taxAmount; String taxAmount;
BigDecimal rate; String rate;
String productionName; String productionName;
String dataSourceId; String dataSourceId;
//数据源名称 //数据源名称
String dataSourceName; String dataSourceName;
Integer operationType; String operationType;
Integer invoiceType; String invoiceType;
public String getId() { public String getId() {
return id; return id;
...@@ -36,11 +36,11 @@ public class CellInvoiceDto { ...@@ -36,11 +36,11 @@ public class CellInvoiceDto {
this.period = period; this.period = period;
} }
public Date getInvoiceDate() { public String getInvoiceDate() {
return invoiceDate; return invoiceDate;
} }
public void setInvoiceDate(Date invoiceDate) { public void setInvoiceDate(String invoiceDate) {
this.invoiceDate = invoiceDate; this.invoiceDate = invoiceDate;
} }
...@@ -60,27 +60,27 @@ public class CellInvoiceDto { ...@@ -60,27 +60,27 @@ public class CellInvoiceDto {
this.invoiceCode = invoiceCode; this.invoiceCode = invoiceCode;
} }
public BigDecimal getAmount() { public String getAmount() {
return amount; return amount;
} }
public void setAmount(BigDecimal amount) { public void setAmount(String amount) {
this.amount = amount; this.amount = amount;
} }
public BigDecimal getTaxAmount() { public String getTaxAmount() {
return taxAmount; return taxAmount;
} }
public void setTaxAmount(BigDecimal taxAmount) { public void setTaxAmount(String taxAmount) {
this.taxAmount = taxAmount; this.taxAmount = taxAmount;
} }
public BigDecimal getRate() { public String getRate() {
return rate; return rate;
} }
public void setRate(BigDecimal rate) { public void setRate(String rate) {
this.rate = rate; this.rate = rate;
} }
...@@ -108,19 +108,19 @@ public class CellInvoiceDto { ...@@ -108,19 +108,19 @@ public class CellInvoiceDto {
this.dataSourceName = dataSourceName; this.dataSourceName = dataSourceName;
} }
public Integer getOperationType() { public String getOperationType() {
return operationType; return operationType;
} }
public void setOperationType(Integer operationType) { public void setOperationType(String operationType) {
this.operationType = operationType; this.operationType = operationType;
} }
public Integer getInvoiceType() { public String getInvoiceType() {
return invoiceType; return invoiceType;
} }
public void setInvoiceType(Integer invoiceType) { public void setInvoiceType(String invoiceType) {
this.invoiceType = invoiceType; this.invoiceType = invoiceType;
} }
} }
...@@ -8,14 +8,15 @@ public class OutputInvoiceDataSourceDto { ...@@ -8,14 +8,15 @@ public class OutputInvoiceDataSourceDto {
private Integer type; private Integer type;
private String id; private String id;
private Integer period; private Integer period;
private Date invoiceDate; private String invoiceDate;
private String buyerName; private String buyerName;
private String invoiceCode; private String invoiceCode;
private String invoiceNumber; private String invoiceNumber;
private BigDecimal taxRate; private String taxRate;
private BigDecimal taxAmount; private String taxAmount;
private Integer invoiceType; private String invoiceType;
private String dataSourceId; private String dataSourceId;
private String amount;
//数据源名称 //数据源名称
private String dataSourceName; private String dataSourceName;
...@@ -35,11 +36,11 @@ public class OutputInvoiceDataSourceDto { ...@@ -35,11 +36,11 @@ public class OutputInvoiceDataSourceDto {
this.period = period; this.period = period;
} }
public Date getInvoiceDate() { public String getInvoiceDate() {
return invoiceDate; return invoiceDate;
} }
public void setInvoiceDate(Date invoiceDate) { public void setInvoiceDate(String invoiceDate) {
this.invoiceDate = invoiceDate; this.invoiceDate = invoiceDate;
} }
...@@ -67,27 +68,24 @@ public class OutputInvoiceDataSourceDto { ...@@ -67,27 +68,24 @@ public class OutputInvoiceDataSourceDto {
this.invoiceNumber = invoiceNumber; this.invoiceNumber = invoiceNumber;
} }
public BigDecimal getTaxRate() { public String getTaxRate() {
return taxRate; return taxRate;
} }
public void setTaxRate(BigDecimal taxRate) { public void setTaxRate(String taxRate) {
this.taxRate = taxRate; this.taxRate = taxRate;
} }
public BigDecimal getTaxAmount() { public String getTaxAmount() {
return taxAmount; return taxAmount;
} }
public void setTaxAmount(BigDecimal taxAmount) {
this.taxAmount = taxAmount;
}
public Integer getInvoiceType() { public String getInvoiceType() {
return invoiceType; return invoiceType;
} }
public void setInvoiceType(Integer invoiceType) { public void setInvoiceType(String invoiceType) {
this.invoiceType = invoiceType; this.invoiceType = invoiceType;
} }
...@@ -114,4 +112,16 @@ public class OutputInvoiceDataSourceDto { ...@@ -114,4 +112,16 @@ public class OutputInvoiceDataSourceDto {
public void setType(Integer type) { public void setType(Integer type) {
this.type = type; this.type = type;
} }
public String getAmount() {
return amount;
}
public void setAmount(String amount) {
this.amount = amount;
}
public void setTaxAmount(String taxAmount) {
this.taxAmount = taxAmount;
}
} }
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="pwc.taxtech.atms.vat.dao.PeriodCellTemplateMapper"> <mapper namespace="pwc.taxtech.atms.vat.dao.PeriodCellDataMapper">
<insert id="batchInsert2" parameterType="pwc.taxtech.atms.vat.entity.PeriodCellData">
INSERT ALL
<foreach collection="list" item="item">
INTO PERIOD_CELL_DATA VALUES
(
#{item.id,jdbcType=DECIMAL},
#{item.reportId,jdbcType=DECIMAL},
#{item.cellTemplateId,jdbcType=DECIMAL},
#{item.data,jdbcType=VARCHAR},
#{item.formulaExp,jdbcType=VARCHAR},
#{item.createBy,jdbcType=VARCHAR},
#{item.createTime,jdbcType=TIMESTAMP},
#{item.updateTime,jdbcType=TIMESTAMP},
#{item.updateBy,jdbcType=VARCHAR},
#{item.projectId,jdbcType=VARCHAR},
#{item.period,jdbcType=DECIMAL}
)
</foreach>
SELECT 1 FROM DUAL
</insert>
<insert id="batchInsert" parameterType="pwc.taxtech.atms.vat.entity.PeriodCellData">
INSERT ALL
<foreach collection="list" item="item">
INTO PERIOD_CELL_DATA (
ID,
PERIOD,
REPORT_ID,
CELL_TEMPLATE_ID,
"DATA",
FORMULA_EXP,
CREATE_TIME,
UPDATE_TIME,
CREATE_BY,
UPDATE_BY,
PROJECT_ID
) VALUES
<trim prefix="(" suffix=")" suffixOverrides=",">
<choose>
<when test="item.id != null">#{item.id,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.period != null">#{item.period,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.reportId != null">#{item.reportId,jdbcType=VARCHAR},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.cellTemplateId != null">#{item.cellTemplateId,jdbcType=INTEGER},</when>
<otherwise>0,</otherwise>
</choose>
<choose>
<when test="item.data != null">#{item.data,jdbcType=VARCHAR},</when>
<otherwise>' ',</otherwise>
</choose>
<choose>
<when test="item.formulaExp != null">#{item.formulaExp,jdbcType=VARCHAR},</when>
<otherwise>' ',</otherwise>
</choose>
<choose>
<when test="item.createTime != null">#{item.createTime,jdbcType=TIMESTAMP},</when>
<otherwise>to_date('1970-01-01 08:00:00','yyyy-mm-dd hh24:mi:ss'),</otherwise>
</choose>
<choose>
<when test="item.updateTime != null">#{item.updateTime,jdbcType=TIMESTAMP},</when>
<otherwise>to_date('1970-01-01 08:00:00','yyyy-mm-dd hh24:mi:ss'),</otherwise>
</choose>
<choose>
<when test="item.createBy != null">#{item.createBy,jdbcType=VARCHAR},</when>
<otherwise>' ',</otherwise>
</choose>
<choose>
<when test="item.updateBy != null">#{item.updateBy,jdbcType=VARCHAR},</when>
<otherwise>' ',</otherwise>
</choose>
<choose>
<when test="item.projectId != null">#{item.projectId,jdbcType=VARCHAR},</when>
<otherwise>' ',</otherwise>
</choose>
</trim>
</foreach>
SELECT 1 FROM DUAL
</insert>
</mapper> </mapper>
\ No newline at end of file
...@@ -641,22 +641,22 @@ var vatModule = angular.module('app.vat', ['ui.grid', 'ui.grid.selection', 'ui.g ...@@ -641,22 +641,22 @@ var vatModule = angular.module('app.vat', ['ui.grid', 'ui.grid.selection', 'ui.g
sticky: true sticky: true
}); });
$stateProvider.state({ // $stateProvider.state({
name: 'vat.reductionData.goodsMapping', // name: 'vat.reductionData.goodsMapping',
url: '/goodsMapping', // url: '/goodsMapping',
views: { // views: {
'@vat.reductionData': { // '@vat.reductionData': {
controller: ['$scope', '$stateParams', 'appTranslation', // controller: ['$scope', '$stateParams', 'appTranslation',
function ($scope, $stateParams, appTranslation) { // function ($scope, $stateParams, appTranslation) {
appTranslation.load([appTranslation.vat]); // appTranslation.load([appTranslation.vat]);
}], // }],
template: '<vat-goods-mapping></vat-goods-mapping>', // template: '<vat-goods-mapping></vat-goods-mapping>',
} // }
}, // },
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.vat), // resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.vat),
deepStateRedirect: true, // deepStateRedirect: true,
sticky: true // sticky: true
}); // });
$stateProvider.state({ $stateProvider.state({
name: 'vat.reductionData.caculateData', name: 'vat.reductionData.caculateData',
......
...@@ -62,7 +62,7 @@ ...@@ -62,7 +62,7 @@
</a> </a>
</div> </div>
<div class="nav-element-right" style="width: 180px;"> <!--<div class="nav-element-right" style="width: 180px;">
<div class="form-group input-group"> <div class="form-group input-group">
<input type="text" class="form-control" style="margin-top: 9px;height: 36px;"> <input type="text" class="form-control" style="margin-top: 9px;height: 36px;">
<span class="input-group-btn"> <span class="input-group-btn">
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
</button> </button>
</span> </span>
</div> </div>
</div> </div>-->
<div class="clear"></div> <div class="clear"></div>
</div> </div>
......
...@@ -885,10 +885,10 @@ ...@@ -885,10 +885,10 @@
constant.vatPermission.dataPreview.outputInvoice.queryCode, constant.vatPermission.dataPreview.outputInvoice.queryCode,
constant.vatPermission.dataPreview.inputInvoice.queryCode, constant.vatPermission.dataPreview.inputInvoice.queryCode,
constant.vatPermission.dataManage.accountMappingCode, // constant.vatPermission.dataManage.accountMappingCode,
constant.vatPermission.dataManage.goodsMappingCode, // constant.vatPermission.dataManage.goodsMappingCode,
constant.vatPermission.dataManage.caculateDataCode, constant.vatPermission.dataManage.caculateDataCode,
constant.vatPermission.dataManage.unbilledInvoiceCode, // constant.vatPermission.dataManage.unbilledInvoiceCode,
constant.vatPermission.reportView.bsplCode, constant.vatPermission.reportView.bsplCode,
constant.vatPermission.reportView.taxReturnCode, constant.vatPermission.reportView.taxReturnCode,
...@@ -932,15 +932,16 @@ ...@@ -932,15 +932,16 @@
// else if (data[constant.vatPermission.dataPreview.customInvoice.queryCode]) { // else if (data[constant.vatPermission.dataPreview.customInvoice.queryCode]) {
// $state.go('vat.previewData.customInvoice'); // $state.go('vat.previewData.customInvoice');
// } // }
else if (data[constant.vatPermission.dataManage.accountMappingCode]) { // else if (data[constant.vatPermission.dataManage.accountMappingCode]) {
$state.go('vat.reductionData.accountMapping'); // $state.go('vat.reductionData.accountMapping');
} else if (data[constant.vatPermission.dataManage.goodsMappingCode]) { // } else if (data[constant.vatPermission.dataManage.goodsMappingCode]) {
$state.go('vat.reductionData.goodsMapping'); // $state.go('vat.reductionData.goodsMapping');
} else if (data[constant.vatPermission.dataManage.caculateDataCode]) { // }
else if (data[constant.vatPermission.dataManage.caculateDataCode]) {
$state.go('vat.reductionData.caculateData'); $state.go('vat.reductionData.caculateData');
} else if (data[constant.vatPermission.dataManage.unbilledInvoiceCode]) { } /*else if (data[constant.vatPermission.dataManage.unbilledInvoiceCode]) {
$state.go('vat.reductionData.unbilledInvoice'); $state.go('vat.reductionData.unbilledInvoice');
} else if (data[constant.vatPermission.reportView.bsplCode] || data[constant.vatPermission.reportView.taxReturnCode]) { }*/ else if (data[constant.vatPermission.reportView.bsplCode] || data[constant.vatPermission.reportView.taxReturnCode]) {
$state.go('vat.generateReport'); $state.go('vat.generateReport');
} else if (data[constant.vatPermission.dataAnalysis.modelAnalysisCode]) { } else if (data[constant.vatPermission.dataAnalysis.modelAnalysisCode]) {
$state.go('vat.analyzeLayout.analyzeReport'); $state.go('vat.analyzeLayout.analyzeReport');
......
...@@ -76,8 +76,8 @@ ...@@ -76,8 +76,8 @@
<button type="button" class="btn btn-in-grid" ng-show="serviceTypeId ==='12' && updateStatus" ngf-select="" ng-model="productFileName" ngf-drag-over-class="'dragover'" accept=".xls,.xlsx" ngf-multiple="false" ngf-allow-dir="false"><i class="material-icons middle">add_circle_outline</i>导入</button> <button type="button" class="btn btn-in-grid" ng-show="serviceTypeId ==='12' && updateStatus" ngf-select="" ng-model="productFileName" ngf-drag-over-class="'dragover'" accept=".xls,.xlsx" ngf-multiple="false" ngf-allow-dir="false"><i class="material-icons middle">add_circle_outline</i>导入</button>
</div> </div>
<a href="" ng-click="toggleView('workflowView')" ng-class="{true:'active',false:'inactive'}[currentView == 'workflowView']"><i class="fa fa-tasks" aria-hidden="true"></i></a> <a href="" ng-click="toggleView('workflowView')" ng-class="{true:'active',false:'inactive'}[currentView == 'workflowView']"><i class="fa fa-tasks" aria-hidden="true"></i></a>
<a href="" ng-click="toggleView('listView')" ng-class="{true:'active',false:'inactive'}[currentView == 'listView']"><i class="fa fa-list-ul" aria-hidden="true"></i></a> <!--<a href="" ng-click="toggleView('listView')" ng-class="{true:'active',false:'inactive'}[currentView == 'listView']"><i class="fa fa-list-ul" aria-hidden="true"></i></a>-->
<a href="" ng-click="toggleView('cardView')" ng-class="{true:'active',false:'inactive'}[currentView == 'cardView']"><i class="fa fa-th" aria-hidden="true"></i></a> <!-- <a href="" ng-click="toggleView('cardView')" ng-class="{true:'active',false:'inactive'}[currentView == 'cardView']"><i class="fa fa-th" aria-hidden="true"></i></a>-->
<div class="button-sort" ng-if="currentView == 'cardView'"> <div class="button-sort" ng-if="currentView == 'cardView'">
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
{{ 'OrderBy' | translate }}<span class="glyphicon glyphicon-sort"></span> {{ 'OrderBy' | translate }}<span class="glyphicon glyphicon-sort"></span>
......
...@@ -571,39 +571,39 @@ var vatModule = angular.module('app.vat', ['ui.grid', 'ui.grid.selection', 'ui.g ...@@ -571,39 +571,39 @@ var vatModule = angular.module('app.vat', ['ui.grid', 'ui.grid.selection', 'ui.g
sticky: true sticky: true
}); });
$stateProvider.state({ // $stateProvider.state({
name: 'vat.reductionData.accountMapping', // name: 'vat.reductionData.accountMapping',
url: '/accountMapping', // url: '/accountMapping',
views: { // views: {
'@vat.reductionData': { // '@vat.reductionData': {
controller: ['$scope', '$stateParams', 'appTranslation', // controller: ['$scope', '$stateParams', 'appTranslation',
function ($scope, $stateParams, appTranslation) { // function ($scope, $stateParams, appTranslation) {
appTranslation.load([appTranslation.vat]); // appTranslation.load([appTranslation.vat]);
}], // }],
template: '<vat-account-mapping></vat-account-mapping>', // template: '<vat-account-mapping></vat-account-mapping>',
} // }
}, // },
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.vat), // resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.vat),
deepStateRedirect: true, // deepStateRedirect: true,
sticky: true // sticky: true
}); // });
//
$stateProvider.state({ // $stateProvider.state({
name: 'vat.reductionData.goodsMapping', // name: 'vat.reductionData.goodsMapping',
url: '/goodsMapping', // url: '/goodsMapping',
views: { // views: {
'@vat.reductionData': { // '@vat.reductionData': {
controller: ['$scope', '$stateParams', 'appTranslation', // controller: ['$scope', '$stateParams', 'appTranslation',
function ($scope, $stateParams, appTranslation) { // function ($scope, $stateParams, appTranslation) {
appTranslation.load([appTranslation.vat]); // appTranslation.load([appTranslation.vat]);
}], // }],
template: '<vat-goods-mapping></vat-goods-mapping>', // template: '<vat-goods-mapping></vat-goods-mapping>',
} // }
}, // },
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.vat), // resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.vat),
deepStateRedirect: true, // deepStateRedirect: true,
sticky: true // sticky: true
}); // });
$stateProvider.state({ $stateProvider.state({
name: 'vat.reductionData.caculateData', name: 'vat.reductionData.caculateData',
......
...@@ -760,7 +760,7 @@ var citModule = angular.module('app.cit', ['ui.grid', 'ui.grid.selection', 'ui.g ...@@ -760,7 +760,7 @@ var citModule = angular.module('app.cit', ['ui.grid', 'ui.grid.selection', 'ui.g
sticky: true sticky: true
}); });
$stateProvider.state({ /*$stateProvider.state({
name: 'cit.reductionData.goodsMapping', name: 'cit.reductionData.goodsMapping',
url: '/goodsMapping', url: '/goodsMapping',
views: { views: {
...@@ -775,7 +775,7 @@ var citModule = angular.module('app.cit', ['ui.grid', 'ui.grid.selection', 'ui.g ...@@ -775,7 +775,7 @@ var citModule = angular.module('app.cit', ['ui.grid', 'ui.grid.selection', 'ui.g
resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.cit), resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.cit),
deepStateRedirect: true, deepStateRedirect: true,
sticky: true sticky: true
}); });*/
$stateProvider.state({ $stateProvider.state({
name: 'cit.reductionData.caculateData', name: 'cit.reductionData.caculateData',
......
...@@ -51,18 +51,18 @@ function ($scope, $log, $translate, $location, loginContext, enums, vatSessionSe ...@@ -51,18 +51,18 @@ function ($scope, $log, $translate, $location, loginContext, enums, vatSessionSe
name: 'caculateData', permission: constant.vatPermission.dataManage.caculateDataCode, name: 'caculateData', permission: constant.vatPermission.dataManage.caculateDataCode,
text: $translate.instant('caculateData'), icon: 'fa fa-random', show: true text: $translate.instant('caculateData'), icon: 'fa fa-random', show: true
}, },
{ /*{
name: 'accountMapping', permission: constant.vatPermission.dataManage.accountMappingCode, name: 'accountMapping', permission: constant.vatPermission.dataManage.accountMappingCode,
text: $translate.instant('accountMapping'), icon: 'fa fa-map', show: true text: $translate.instant('accountMapping'), icon: 'fa fa-map', show: true
}, },
{ {
name: 'goodsMapping', permission: constant.vatPermission.dataManage.goodsMappingCode, name: 'goodsMapping', permission: constant.vatPermission.dataManage.goodsMappingCode,
text: $translate.instant('goodsMapping'), icon: 'fa fa-map-signs', show: true text: $translate.instant('goodsMapping'), icon: 'fa fa-map-signs', show: true
}, },
{ {
name: 'unbilledInvoice', permission: constant.vatPermission.dataManage.unbilledInvoiceCode, name: 'unbilledInvoice', permission: constant.vatPermission.dataManage.unbilledInvoiceCode,
text: $translate.instant('unbilledInvoice'), icon: 'fa fa-shield', show: true text: $translate.instant('unbilledInvoice'), icon: 'fa fa-shield', show: true
}, ]; },*/ ];
} }
else { else {
$scope.nodeDicKey = constant.DictionaryDictKey.DataImport; $scope.nodeDicKey = constant.DictionaryDictKey.DataImport;
......
...@@ -131,9 +131,9 @@ function ($scope, $rootScope, $q, $log, $timeout, $state, $translate, projectSer ...@@ -131,9 +131,9 @@ function ($scope, $rootScope, $q, $log, $timeout, $state, $translate, projectSer
constant.vatPermission.dataPreview.inputInvoice.queryCode, constant.vatPermission.dataPreview.inputInvoice.queryCode,
constant.vatPermission.dataManage.caculateDataCode, constant.vatPermission.dataManage.caculateDataCode,
constant.vatPermission.dataManage.accountMappingCode, // constant.vatPermission.dataManage.accountMappingCode,
constant.vatPermission.dataManage.goodsMappingCode, // constant.vatPermission.dataManage.goodsMappingCode,
constant.vatPermission.dataManage.unbilledInvoiceCode, // constant.vatPermission.dataManage.unbilledInvoiceCode,
constant.vatPermission.reportView.bsplCode, constant.vatPermission.reportView.bsplCode,
constant.vatPermission.reportView.taxReturnCode, constant.vatPermission.reportView.taxReturnCode,
...@@ -323,30 +323,30 @@ function ($scope, $rootScope, $q, $log, $timeout, $state, $translate, projectSer ...@@ -323,30 +323,30 @@ function ($scope, $rootScope, $q, $log, $timeout, $state, $translate, projectSer
name: 'reductionData', state: 'reductionData', num: 3, name: 'reductionData', state: 'reductionData', num: 3,
permission: constant.vatPermission.dataManage.dataManageCode, url: '#/vat/reductionData' permission: constant.vatPermission.dataManage.dataManageCode, url: '#/vat/reductionData'
}); });
subMenus.push({ /* subMenus.push({
name: 'reductionData.accountMapping', state: 'reductionData.accountMapping', num: 3, name: 'reductionData.accountMapping', state: 'reductionData.accountMapping', num: 3,
permission: constant.vatPermission.dataManage.accountMappingCode, url: '#/vat/reductionData/accountMapping' permission: constant.vatPermission.dataManage.accountMappingCode, url: '#/vat/reductionData/accountMapping'
}); });*/
} }
else if (data[constant.vatPermission.dataManage.goodsMappingCode]) { else if (data[constant.vatPermission.dataManage.goodsMappingCode]) {
$scope.menus.push({ $scope.menus.push({
name: 'reductionData', state: 'reductionData', num: 3, name: 'reductionData', state: 'reductionData', num: 3,
permission: constant.vatPermission.dataManage.dataManageCode, url: '#/vat/reductionData' permission: constant.vatPermission.dataManage.dataManageCode, url: '#/vat/reductionData'
}); });
subMenus.push({ /* subMenus.push({
name: 'reductionData.goodsMapping', state: 'reductionData.goodsMapping', num: 3, name: 'reductionData.goodsMapping', state: 'reductionData.goodsMapping', num: 3,
permission: constant.vatPermission.dataManage.goodsMappingCode, url: '#/vat/reductionData/goodsMapping' permission: constant.vatPermission.dataManage.goodsMappingCode, url: '#/vat/reductionData/goodsMapping'
}); });*/
} }
else if (data[constant.vatPermission.dataManage.unbilledInvoiceCode]) { else if (data[constant.vatPermission.dataManage.unbilledInvoiceCode]) {
$scope.menus.push({ $scope.menus.push({
name: 'reductionData', state: 'reductionData', num: 3, name: 'reductionData', state: 'reductionData', num: 3,
permission: constant.vatPermission.dataManage.dataManageCode, url: '#/vat/reductionData' permission: constant.vatPermission.dataManage.dataManageCode, url: '#/vat/reductionData'
}); });
subMenus.push({ /*subMenus.push({
name: 'reductionData.unbilledInvoice', state: 'reductionData.unbilledInvoice', num: 3, name: 'reductionData.unbilledInvoice', state: 'reductionData.unbilledInvoice', num: 3,
permission: constant.vatPermission.dataManage.unbilledInvoiceCode, url: '#/vat/reductionData/unbilledInvoice' permission: constant.vatPermission.dataManage.unbilledInvoiceCode, url: '#/vat/reductionData/unbilledInvoice'
}); });*/
} }
if (data[constant.vatPermission.reportView.bsplCode] || data[constant.vatPermission.reportView.taxReturnCode]) { if (data[constant.vatPermission.reportView.bsplCode] || data[constant.vatPermission.reportView.taxReturnCode]) {
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment