diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/FutureBaseInforController.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/FutureBaseInforController.java new file mode 100644 index 0000000..c261706 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/FutureBaseInforController.java @@ -0,0 +1,109 @@ +package com.intc.invest.controller; + +import com.intc.common.core.utils.poi.ExcelUtil; +import com.intc.common.core.web.controller.BaseController; +import com.intc.common.core.web.domain.AjaxResult; +import com.intc.common.core.web.page.TableDataInfo; +import com.intc.common.log.annotation.Log; +import com.intc.common.log.enums.BusinessType; +import com.intc.common.security.annotation.RequiresPermissions; +import com.intc.invest.domain.FutureBaseInfor; +import com.intc.invest.domain.dto.FutureBaseInforDto; +import com.intc.invest.domain.vo.FutureBaseInforVo; +import com.intc.invest.service.IFutureBaseInforService; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; +import java.util.List; + +/** + * 期货基本合约Controller + * + * @author tianyongbao + * @date 2025-03-28 + */ +@Api(tags=" 期货基本合约") +@RestController +@RequestMapping("/futureBaseInfor") +public class FutureBaseInforController extends BaseController +{ + @Resource + private IFutureBaseInforService investFutureBaseInforService; + + /** + * 查询期货基本合约列表 + */ + @ApiOperation(value="查询期货基本合约列表",response = FutureBaseInforVo.class) + @RequiresPermissions("invest:futureBaseInfor:list") + @GetMapping("/list") + public TableDataInfo list(FutureBaseInforDto futureBaseInforDto) + { + startPage(); + List list = investFutureBaseInforService.selectFutureBaseInforList(futureBaseInforDto); + return getDataTable(list); + } + + /** + * 导出期货基本合约列表 + */ + @ApiOperation(value="导出期货基本合约列表") + @RequiresPermissions("invest:futureBaseInfor:export") + @Log(title = "期货基本合约", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, FutureBaseInforDto futureBaseInforDto) + { + List list = investFutureBaseInforService.selectFutureBaseInforList(futureBaseInforDto); + ExcelUtil util = new ExcelUtil(FutureBaseInforVo.class); + util.exportExcel(response, list, "期货基本合约数据"); + } + + /** + * 获取期货基本合约详细信息 + */ + @ApiOperation(value="获取期货基本合约详细信息") + @RequiresPermissions("invest:futureBaseInfor:query") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) + { + return success(investFutureBaseInforService.selectFutureBaseInforById(id)); + } + + /** + * 新增期货基本合约 + */ + @ApiOperation(value="新增期货基本合约") + @RequiresPermissions("invest:futureBaseInfor:add") + @Log(title = "期货基本合约", businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody FutureBaseInfor futureBaseInfor) + { + return toAjax(investFutureBaseInforService.insertFutureBaseInfor(futureBaseInfor)); + } + + /** + * 修改期货基本合约 + */ + @ApiOperation(value="修改期货基本合约") + @RequiresPermissions("invest:futureBaseInfor:edit") + @Log(title = "期货基本合约", businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody FutureBaseInfor futureBaseInfor) + { + return toAjax(investFutureBaseInforService.updateFutureBaseInfor(futureBaseInfor)); + } + + /** + * 删除期货基本合约 + */ + @ApiOperation(value="删除期货基本合约") + @RequiresPermissions("invest:futureBaseInfor:remove") + @Log(title = "期货基本合约", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) + { + return toAjax(investFutureBaseInforService.deleteFutureBaseInforByIds(ids)); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/FutureStandardInforController.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/FutureStandardInforController.java new file mode 100644 index 0000000..0b9ba48 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/FutureStandardInforController.java @@ -0,0 +1,109 @@ +package com.intc.invest.controller; + +import com.intc.common.core.utils.poi.ExcelUtil; +import com.intc.common.core.web.controller.BaseController; +import com.intc.common.core.web.domain.AjaxResult; +import com.intc.common.core.web.page.TableDataInfo; +import com.intc.common.log.annotation.Log; +import com.intc.common.log.enums.BusinessType; +import com.intc.common.security.annotation.RequiresPermissions; +import com.intc.invest.domain.FutureStandardInfor; +import com.intc.invest.domain.dto.FutureStandardInforDto; +import com.intc.invest.domain.vo.FutureStandardInforVo; +import com.intc.invest.service.IFutureStandardInforService; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; +import java.util.List; + +/** + * 期货品种标准合约Controller + * + * @author tianyongbao + * @date 2025-03-27 + */ +@Api(tags=" 期货品种标准合约") +@RestController +@RequestMapping("/futureStandardInfor") +public class FutureStandardInforController extends BaseController +{ + @Resource + private IFutureStandardInforService futureStandardInforService; + + /** + * 查询期货品种标准合约列表 + */ + @ApiOperation(value="查询期货品种标准合约列表",response = FutureStandardInforVo.class) + @RequiresPermissions("invest:futureStandardInfor:list") + @GetMapping("/list") + public TableDataInfo list(FutureStandardInforDto futureStandardInforDto) + { + startPage(); + List list = futureStandardInforService.selectFutureStandardInforList(futureStandardInforDto); + return getDataTable(list); + } + + /** + * 导出期货品种标准合约列表 + */ + @ApiOperation(value="导出期货品种标准合约列表") + @RequiresPermissions("invest:futureStandardInfor:export") + @Log(title = "期货品种标准合约", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, FutureStandardInforDto futureStandardInforDto) + { + List list = futureStandardInforService.selectFutureStandardInforList(futureStandardInforDto); + ExcelUtil util = new ExcelUtil(FutureStandardInforVo.class); + util.exportExcel(response, list, "期货品种标准合约数据"); + } + + /** + * 获取期货品种标准合约详细信息 + */ + @ApiOperation(value="获取期货品种标准合约详细信息") + @RequiresPermissions("invest:futureStandardInfor:query") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) + { + return success(futureStandardInforService.selectFutureStandardInforById(id)); + } + + /** + * 新增期货品种标准合约 + */ + @ApiOperation(value="新增期货品种标准合约") + @RequiresPermissions("invest:futureStandardInfor:add") + @Log(title = "期货品种标准合约", businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody FutureStandardInfor futureStandardInfor) + { + return toAjax(futureStandardInforService.insertFutureStandardInfor(futureStandardInfor)); + } + + /** + * 修改期货品种标准合约 + */ + @ApiOperation(value="修改期货品种标准合约") + @RequiresPermissions("invest:futureStandardInfor:edit") + @Log(title = "期货品种标准合约", businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody FutureStandardInfor futureStandardInfor) + { + return toAjax(futureStandardInforService.updateFutureStandardInfor(futureStandardInfor)); + } + + /** + * 删除期货品种标准合约 + */ + @ApiOperation(value="删除期货品种标准合约") + @RequiresPermissions("invest:futureStandardInfor:remove") + @Log(title = "期货品种标准合约", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) + { + return toAjax(futureStandardInforService.deleteFutureStandardInforByIds(ids)); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/InvestExchangeController.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/InvestExchangeController.java new file mode 100644 index 0000000..da06637 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/InvestExchangeController.java @@ -0,0 +1,115 @@ +package com.intc.invest.controller; + +import java.util.List; +import javax.servlet.http.HttpServletResponse; +import javax.annotation.Resource; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.intc.common.log.annotation.Log; +import com.intc.common.log.enums.BusinessType; +import com.intc.common.security.annotation.RequiresPermissions; +import com.intc.invest.domain.InvestExchange; +import com.intc.invest.domain.vo.InvestExchangeVo; +import com.intc.invest.domain.dto.InvestExchangeDto; +import com.intc.invest.service.IInvestExchangeService; +import com.intc.common.core.web.controller.BaseController; +import com.intc.common.core.web.domain.AjaxResult; +import com.intc.common.core.utils.poi.ExcelUtil; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import com.intc.common.core.web.page.TableDataInfo; + +/** + * 交易所基础信息Controller + * + * @author tianyongbao + * @date 2025-03-27 + */ +@Api(tags=" 交易所基础信息") +@RestController +@RequestMapping("/exchange") +public class InvestExchangeController extends BaseController +{ + @Resource + private IInvestExchangeService investExchangeService; + + /** + * 查询交易所基础信息列表 + */ + @ApiOperation(value="查询交易所基础信息列表",response = InvestExchangeVo.class) + @RequiresPermissions("invest:exchange:list") + @GetMapping("/list") + public TableDataInfo list(InvestExchangeDto investExchangeDto) + { + startPage(); + List list = investExchangeService.selectInvestExchangeList(investExchangeDto); + return getDataTable(list); + } + + /** + * 导出交易所基础信息列表 + */ + @ApiOperation(value="导出交易所基础信息列表") + @RequiresPermissions("invest:exchange:export") + @Log(title = "交易所基础信息", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, InvestExchangeDto investExchangeDto) + { + List list = investExchangeService.selectInvestExchangeList(investExchangeDto); + ExcelUtil util = new ExcelUtil(InvestExchangeVo.class); + util.exportExcel(response, list, "交易所基础信息数据"); + } + + /** + * 获取交易所基础信息详细信息 + */ + @ApiOperation(value="获取交易所基础信息详细信息") + @RequiresPermissions("invest:exchange:query") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) + { + return success(investExchangeService.selectInvestExchangeById(id)); + } + + /** + * 新增交易所基础信息 + */ + @ApiOperation(value="新增交易所基础信息") + @RequiresPermissions("invest:exchange:add") + @Log(title = "交易所基础信息", businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody InvestExchange investExchange) + { + return toAjax(investExchangeService.insertInvestExchange(investExchange)); + } + + /** + * 修改交易所基础信息 + */ + @ApiOperation(value="修改交易所基础信息") + @RequiresPermissions("invest:exchange:edit") + @Log(title = "交易所基础信息", businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody InvestExchange investExchange) + { + return toAjax(investExchangeService.updateInvestExchange(investExchange)); + } + + /** + * 删除交易所基础信息 + */ + @ApiOperation(value="删除交易所基础信息") + @RequiresPermissions("invest:exchange:remove") + @Log(title = "交易所基础信息", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) + { + return toAjax(investExchangeService.deleteInvestExchangeByIds(ids)); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/StockBaseInforController.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/StockBaseInforController.java new file mode 100644 index 0000000..ff903f2 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/controller/StockBaseInforController.java @@ -0,0 +1,116 @@ +package com.intc.invest.controller; + +import java.util.List; +import java.io.IOException; +import javax.servlet.http.HttpServletResponse; +import javax.annotation.Resource; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.intc.common.log.annotation.Log; +import com.intc.common.log.enums.BusinessType; +import com.intc.common.security.annotation.RequiresPermissions; +import com.intc.invest.domain.StockBaseInfor; +import com.intc.invest.domain.vo.StockBaseInforVo; +import com.intc.invest.domain.dto.StockBaseInforDto; +import com.intc.invest.service.IStockBaseInforService; +import com.intc.common.core.web.controller.BaseController; +import com.intc.common.core.web.domain.AjaxResult; +import com.intc.common.core.utils.poi.ExcelUtil; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import com.intc.common.core.web.page.TableDataInfo; + +/** + * 股票基础信息Controller + * + * @author tianyongbao + * @date 2025-03-27 + */ +@Api(tags=" 股票基础信息") +@RestController +@RequestMapping("/stockBaseInfor") +public class StockBaseInforController extends BaseController +{ + @Resource + private IStockBaseInforService stockBaseInforService; + + /** + * 查询股票基础信息列表 + */ + @ApiOperation(value="查询股票基础信息列表",response = StockBaseInforVo.class) + @RequiresPermissions("invest:stockBaseInfor:list") + @GetMapping("/list") + public TableDataInfo list(StockBaseInforDto stockBaseInforDto) + { + startPage(); + List list = stockBaseInforService.selectStockBaseInforList(stockBaseInforDto); + return getDataTable(list); + } + + /** + * 导出股票基础信息列表 + */ + @ApiOperation(value="导出股票基础信息列表") + @RequiresPermissions("invest:stockBaseInfor:export") + @Log(title = "股票基础信息", businessType = BusinessType.EXPORT) + @PostMapping("/export") + public void export(HttpServletResponse response, StockBaseInforDto stockBaseInforDto) + { + List list = stockBaseInforService.selectStockBaseInforList(stockBaseInforDto); + ExcelUtil util = new ExcelUtil(StockBaseInforVo.class); + util.exportExcel(response, list, "股票基础信息数据"); + } + + /** + * 获取股票基础信息详细信息 + */ + @ApiOperation(value="获取股票基础信息详细信息") + @RequiresPermissions("invest:stockBaseInfor:query") + @GetMapping(value = "/{id}") + public AjaxResult getInfo(@PathVariable("id") Long id) + { + return success(stockBaseInforService.selectStockBaseInforById(id)); + } + + /** + * 新增股票基础信息 + */ + @ApiOperation(value="新增股票基础信息") + @RequiresPermissions("invest:stockBaseInfor:add") + @Log(title = "股票基础信息", businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody StockBaseInfor stockBaseInfor) + { + return toAjax(stockBaseInforService.insertStockBaseInfor(stockBaseInfor)); + } + + /** + * 修改股票基础信息 + */ + @ApiOperation(value="修改股票基础信息") + @RequiresPermissions("invest:stockBaseInfor:edit") + @Log(title = "股票基础信息", businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody StockBaseInfor stockBaseInfor) + { + return toAjax(stockBaseInforService.updateStockBaseInfor(stockBaseInfor)); + } + + /** + * 删除股票基础信息 + */ + @ApiOperation(value="删除股票基础信息") + @RequiresPermissions("invest:stockBaseInfor:remove") + @Log(title = "股票基础信息", businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) + { + return toAjax(stockBaseInforService.deleteStockBaseInforByIds(ids)); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/FutureBaseInfor.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/FutureBaseInfor.java new file mode 100644 index 0000000..ec5ac91 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/FutureBaseInfor.java @@ -0,0 +1,113 @@ +package com.intc.invest.domain; + +import com.fasterxml.jackson.annotation.JsonFormat; +import com.intc.common.core.annotation.Excel; +import com.intc.common.core.web.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +import java.util.Date; + +/** + * 期货基本合约对象 invest_future_base_infor + * + * @author tianyongbao + * @date 2025-03-28 + */ +@ApiModel("期货基本合约对象") +@Data +public class FutureBaseInfor extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private Long id; + + /** 名称 */ + @ApiModelProperty(value="名称") + @Excel(name = "名称") + private String name; + + /** 代码 */ + @ApiModelProperty(value="代码") + @Excel(name = "代码") + private String code; + + /** 标准合约id */ + @ApiModelProperty(value="标准合约id") + @Excel(name = "标准合约id") + private Long standardId; + + /** 上市基准价 */ + @ApiModelProperty(value="上市基准价") + @Excel(name = "上市基准价") + private Double referencePrice; + + /** 交易乘数 */ + private Double tradingMultiplier; + + /** 涨跌副限制 */ + @ApiModelProperty(value="涨跌副限制") + @Excel(name = "涨跌副限制") + private Double priceLimit; + + /** 交割月份 */ + @JsonFormat(pattern = "yyyy-MM") + private String deliveryMonth; + + /** 保证金比例 */ + @ApiModelProperty(value="保证金比例") + @Excel(name = "保证金比例") + private Double marginRatio; + + /** 最后交易日 */ + @ApiModelProperty(value="最后交易日") + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "最后交易日", width = 30, dateFormat = "yyyy-MM-dd") + private Date lastTradingDay; + + /** 合约上市日 */ + @ApiModelProperty(value="合约上市日") + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "合约上市日", width = 30, dateFormat = "yyyy-MM-dd") + private Date listingDate; + + + + /** 最后交割日 */ + @ApiModelProperty(value="最后交割日") + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "最后交割日", width = 30, dateFormat = "yyyy-MM-dd") + private Date deliveryDate; + + /** 删除标志(0代表存在 1代表删除) */ + private String delFlag; + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("code", getCode()) + .append("standardId", getStandardId()) + .append("referencePrice", getReferencePrice()) + .append("tradingMultiplier", getTradingMultiplier()) + .append("priceLimit", getPriceLimit()) + .append("deliveryMonth", getDeliveryMonth()) + .append("marginRatio", getMarginRatio()) + .append("lastTradingDay", getLastTradingDay()) + .append("deliveryDate", getDeliveryDate()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .append("listingDate", getListingDate()) + + .toString(); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/FutureStandardInfor.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/FutureStandardInfor.java new file mode 100644 index 0000000..7d12321 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/FutureStandardInfor.java @@ -0,0 +1,119 @@ +package com.intc.invest.domain; + +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.intc.common.core.annotation.Excel; +import com.intc.common.core.web.domain.BaseEntity; +import lombok.Data; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import javax.validation.constraints.*; +/** + * 期货品种标准合约对象 invest_future_base_infor + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("期货品种标准合约对象") +@Data +public class FutureStandardInfor extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private Long id; + + /** 交易品种 */ + @ApiModelProperty(value="交易品种)") + @NotNull(message="交易品种不能为空") + @Excel(name = "交易品种") + private String name; + + /** 类型 */ + @ApiModelProperty(value="类型)") + @NotNull(message="类型不能为空") + @Excel(name = "类型") + private String type; + + /** 交易代码 */ + @ApiModelProperty(value="交易代码)") + @NotNull(message="交易代码不能为空") + @Excel(name = "交易代码") + private String code; + + /** 上市交易所 */ + @ApiModelProperty(value="上市交易所)") + @NotNull(message="上市交易所不能为空") + @Excel(name = "上市交易所") + private Long exchangeId; + + /** 交易单位 */ + private String tradingUnit; + + /** 最小变动价位 */ + private String minimumPriceFluctuation; + + /** 交易时间 */ + @ApiModelProperty(value="交易时间") + @Excel(name = "交易时间") + private String tradingTime; + + /** 涨跌停板限制 */ + @ApiModelProperty(value="涨跌停板限制") + @Excel(name = "涨跌停板限制") + private String priceLimit; + + /** 交割月份 */ + private String deliveryMonth; + + /** 交割方式 */ + private String deliveryMethod; + + /** 交割地点 */ + private String deliveryLocation; + + /** 保证金比例 */ + @ApiModelProperty(value="保证金比例") + @Excel(name = "保证金比例") + private String marginRatio; + + /** 报价单位 */ + private String pricingUnit; + + /** 最后交易日 */ + private String lastTradingDay; + + /** 交割日期 */ + private String deliveryDate; + + /** 删除标志(0代表存在 1代表删除) */ + private String delFlag; + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("type", getType()) + .append("code", getCode()) + .append("exchangeId", getExchangeId()) + .append("tradingUnit", getTradingUnit()) + .append("minimumPriceFluctuation", getMinimumPriceFluctuation()) + .append("tradingTime", getTradingTime()) + .append("priceLimit", getPriceLimit()) + .append("deliveryMonth", getDeliveryMonth()) + .append("deliveryMethod", getDeliveryMethod()) + .append("deliveryLocation", getDeliveryLocation()) + .append("marginRatio", getMarginRatio()) + .append("pricingUnit", getPricingUnit()) + .append("lastTradingDay", getLastTradingDay()) + .append("deliveryDate", getDeliveryDate()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .toString(); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/InvestExchange.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/InvestExchange.java new file mode 100644 index 0000000..3887730 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/InvestExchange.java @@ -0,0 +1,78 @@ +package com.intc.invest.domain; + +import com.fasterxml.jackson.annotation.JsonFormat; +import com.intc.common.core.annotation.Excel; +import com.intc.common.core.web.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; + +import javax.validation.constraints.NotNull; +import java.util.Date; +/** + * 交易所基础信息对象 invest_exchange + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("交易所基础信息对象") +@Data +public class InvestExchange extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private Long id; + + /** 全称 */ + @ApiModelProperty(value="全称)") + @NotNull(message="全称不能为空") + @Excel(name = "全称") + private String name; + + /** 类型,1期货,2股票 */ + private String type; + + /** 编号 */ + @ApiModelProperty(value="编号)") + @NotNull(message="编号不能为空") + @Excel(name = "编号") + private String code; + + /** 简称 */ + @ApiModelProperty(value="简称)") + @NotNull(message="简称不能为空") + @Excel(name = "简称") + private String shortName; + + /** 成立时间 */ + @JsonFormat(pattern = "yyyy-MM-dd") + private Date foundingTime; + + /** 删除标志(0代表存在 1代表删除) */ + private String delFlag; + + /** 简介 */ + private String introduce; + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("type", getType()) + .append("code", getCode()) + .append("shortName", getShortName()) + .append("foundingTime", getFoundingTime()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .append("introduce", getIntroduce()) + .toString(); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/StockBaseInfor.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/StockBaseInfor.java new file mode 100644 index 0000000..d1c975e --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/StockBaseInfor.java @@ -0,0 +1,106 @@ +package com.intc.invest.domain; + +import com.fasterxml.jackson.annotation.JsonFormat; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.intc.common.core.annotation.Excel; +import com.intc.common.core.web.domain.BaseEntity; +import lombok.Data; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import javax.validation.constraints.*; +import java.util.Date; + +/** + * 股票基础信息对象 invest_stock_base_infor + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("股票基础信息对象") +@Data +public class StockBaseInfor extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键 */ + private Long id; + + /** 公司名称 */ + @ApiModelProperty(value="公司名称)") + @NotNull(message="公司名称不能为空") + @Excel(name = "公司名称") + private String name; + + /** 类型 */ + private String type; + + /** 股票代码 */ + @ApiModelProperty(value="股票代码)") + @NotNull(message="股票代码不能为空") + @Excel(name = "股票代码") + private String code; + + /** 上市交易所 */ + @ApiModelProperty(value="上市交易所)") + @NotNull(message="上市交易所不能为空") + @Excel(name = "上市交易所") + private Long exchangeId; + + /** 行业分类 */ + @ApiModelProperty(value="行业分类") + @Excel(name = "行业分类") + private String industryClassification; + + /** 主营业务 */ + @ApiModelProperty(value="主营业务") + @Excel(name = "主营业务") + private String mainBusiness; + + /** 上市日期 */ + @ApiModelProperty(value="上市日期)") + @NotNull(message="上市日期不能为空") + /** 成立时间 */ + @JsonFormat(pattern = "yyyy-MM-dd") + private Date listingDate; + + /** 删除标志(0代表存在 1代表删除) */ + private String delFlag; + + /** 公司简介 */ + private String introduce; + + /** 所属区域 */ + @ApiModelProperty(value="所属区域") + @Excel(name = "所属区域") + private String region; + + /** 简称 */ + @ApiModelProperty(value="简称)") + @NotNull(message="简称不能为空") + @Excel(name = "简称") + private String shortName; + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("name", getName()) + .append("type", getType()) + .append("code", getCode()) + .append("exchangeId", getExchangeId()) + .append("industryClassification", getIndustryClassification()) + .append("mainBusiness", getMainBusiness()) + .append("listingDate", getListingDate()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .append("introduce", getIntroduce()) + .append("region", getRegion()) + .append("shortName", getShortName()) + .toString(); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/FutureBaseInforDto.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/FutureBaseInforDto.java new file mode 100644 index 0000000..c423282 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/FutureBaseInforDto.java @@ -0,0 +1,32 @@ +package com.intc.invest.domain.dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.io.Serializable; +/** + * 期货基本合约Dto对象 invest_future_base_infor + * + * @author tianyongbao + * @date 2025-03-28 + */ +@ApiModel("期货基本合约Dto对象") +@Data +public class FutureBaseInforDto implements Serializable +{ + private static final long serialVersionUID = 1L; + + /** 名称 */ + @ApiModelProperty(value="名称") + private String name; + + /** 代码 */ + @ApiModelProperty(value="代码") + private String code; + + /** 标准合约id */ + @ApiModelProperty(value="标准合约id") + private Long standardId; + +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/FutureStandardInforDto.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/FutureStandardInforDto.java new file mode 100644 index 0000000..ae3fa9b --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/FutureStandardInforDto.java @@ -0,0 +1,36 @@ +package com.intc.invest.domain.dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.io.Serializable; +/** + * 期货品种标准合约Dto对象 invest_future_base_infor + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("期货品种标准合约Dto对象") +@Data +public class FutureStandardInforDto implements Serializable +{ + private static final long serialVersionUID = 1L; + + /** 交易品种 */ + @ApiModelProperty(value="交易品种") + private String name; + + /** 类型 */ + @ApiModelProperty(value="类型") + private String type; + + /** 交易代码 */ + @ApiModelProperty(value="交易代码") + private String code; + + /** 上市交易所 */ + @ApiModelProperty(value="上市交易所") + private Long exchangeId; + +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/InvestExchangeDto.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/InvestExchangeDto.java new file mode 100644 index 0000000..131a2c6 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/InvestExchangeDto.java @@ -0,0 +1,37 @@ +package com.intc.invest.domain.dto; + +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import lombok.Data; +import java.io.Serializable; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +/** + * 交易所基础信息Dto对象 invest_exchange + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("交易所基础信息Dto对象") +@Data +public class InvestExchangeDto implements Serializable +{ + private static final long serialVersionUID = 1L; + + /** 全称 */ + @ApiModelProperty(value="全称") + private String name; + + /** 类型,1期货,2股票 */ + @ApiModelProperty(value="类型,1期货,2股票") + private String type; + + /** 编号 */ + @ApiModelProperty(value="编号") + private String code; + + /** 简称 */ + @ApiModelProperty(value="简称") + private String shortName; + +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/StockBaseInforDto.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/StockBaseInforDto.java new file mode 100644 index 0000000..e6f5aad --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/dto/StockBaseInforDto.java @@ -0,0 +1,43 @@ +package com.intc.invest.domain.dto; + +import lombok.Data; +import java.io.Serializable; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +/** + * 股票基础信息Dto对象 invest_stock_base_infor + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("股票基础信息Dto对象") +@Data +public class StockBaseInforDto implements Serializable +{ + private static final long serialVersionUID = 1L; + + /** 公司名称 */ + @ApiModelProperty(value="公司名称") + private String name; + + /** 类型 */ + @ApiModelProperty(value="类型") + private String type; + + /** 股票代码 */ + @ApiModelProperty(value="股票代码") + private String code; + + /** 上市交易所 */ + @ApiModelProperty(value="上市交易所") + private Long exchangeId; + + /** 行业分类 */ + @ApiModelProperty(value="行业分类") + private String industryClassification; + + /** 简称 */ + @ApiModelProperty(value="简称") + private String shortName; + +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/FutureBaseInforVo.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/FutureBaseInforVo.java new file mode 100644 index 0000000..d122e8f --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/FutureBaseInforVo.java @@ -0,0 +1,23 @@ +package com.intc.invest.domain.vo; + +import com.intc.invest.domain.FutureBaseInfor; +import lombok.Data; +import io.swagger.annotations.ApiModel; +/** + * 期货基本合约Vo对象 invest_future_base_infor + * + * @author tianyongbao + * @date 2025-03-28 + */ +@ApiModel("期货基本合约Vo对象") +@Data +public class FutureBaseInforVo extends FutureBaseInfor +{ + + private String exchangeName; + + private String tradingTimeName; + + private String standardName; + +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/FutureStandardInforVo.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/FutureStandardInforVo.java new file mode 100644 index 0000000..37d8f57 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/FutureStandardInforVo.java @@ -0,0 +1,21 @@ +package com.intc.invest.domain.vo; + +import com.intc.invest.domain.FutureStandardInfor; +import lombok.Data; +import io.swagger.annotations.ApiModel; +/** + * 期货品种标准合约Vo对象 invest_future_base_infor + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("期货品种标准合约Vo对象") +@Data +public class FutureStandardInforVo extends FutureStandardInfor +{ + private String exchangeName; + + private String tradingTimeName; + + private String deliveryMonthName; +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/InvestExchangeVo.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/InvestExchangeVo.java new file mode 100644 index 0000000..6ed86e8 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/InvestExchangeVo.java @@ -0,0 +1,17 @@ +package com.intc.invest.domain.vo; + +import com.intc.invest.domain.InvestExchange; +import lombok.Data; +import io.swagger.annotations.ApiModel; +/** + * 交易所基础信息Vo对象 invest_exchange + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("交易所基础信息Vo对象") +@Data +public class InvestExchangeVo extends InvestExchange +{ + +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/StockBaseInforVo.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/StockBaseInforVo.java new file mode 100644 index 0000000..f0520d6 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/domain/vo/StockBaseInforVo.java @@ -0,0 +1,18 @@ +package com.intc.invest.domain.vo; + +import com.intc.invest.domain.StockBaseInfor; +import lombok.Data; +import io.swagger.annotations.ApiModel; +/** + * 股票基础信息Vo对象 invest_stock_base_infor + * + * @author tianyongbao + * @date 2025-03-27 + */ +@ApiModel("股票基础信息Vo对象") +@Data +public class StockBaseInforVo extends StockBaseInfor +{ + private String exchangeName; + +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/FutureBaseInforMapper.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/FutureBaseInforMapper.java new file mode 100644 index 0000000..cb003dc --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/FutureBaseInforMapper.java @@ -0,0 +1,80 @@ +package com.intc.invest.mapper; + +import com.intc.invest.domain.FutureBaseInfor; +import com.intc.invest.domain.dto.FutureBaseInforDto; +import com.intc.invest.domain.vo.FutureBaseInforVo; + +import java.util.List; + +/** + * 期货基本合约Mapper接口 + * + * @author tianyongbao + * @date 2025-03-28 + */ +public interface FutureBaseInforMapper +{ + /** + * 查询期货基本合约 + * + * @param id 期货基本合约主键 + * @return 期货基本合约 + */ + public FutureBaseInforVo selectFutureBaseInforById(Long id); + + /** + * 查询期货基本合约列表 + * + * @param futureBaseInforDto 期货基本合约 + * @return 期货基本合约集合 + */ + public List selectFutureBaseInforList(FutureBaseInforDto futureBaseInforDto); + + /** + * 新增期货基本合约 + * + * @param futureBaseInfor 期货基本合约 + * @return 结果 + */ + public int insertFutureBaseInfor(FutureBaseInfor futureBaseInfor); + + /** + * 修改期货基本合约 + * + * @param futureBaseInfor 期货基本合约 + * @return 结果 + */ + public int updateFutureBaseInfor(FutureBaseInfor futureBaseInfor); + + /** + * 删除期货基本合约 + * + * @param id 期货基本合约主键 + * @return 结果 + */ + public int deleteFutureBaseInforById(Long id); + + /** + * 批量删除期货基本合约 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteFutureBaseInforByIds(Long[] ids); + + /** + * 逻辑删除期货基本合约 + * + * @param id 期货基本合约主键 + * @return 结果 + */ + public int removeFutureBaseInforById(Long id); + + /** + * 批量逻辑删除期货基本合约 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int removeFutureBaseInforByIds(Long[] ids); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/FutureStandardInforMapper.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/FutureStandardInforMapper.java new file mode 100644 index 0000000..b9690e0 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/FutureStandardInforMapper.java @@ -0,0 +1,80 @@ +package com.intc.invest.mapper; + +import com.intc.invest.domain.FutureStandardInfor; +import com.intc.invest.domain.dto.FutureStandardInforDto; +import com.intc.invest.domain.vo.FutureStandardInforVo; + +import java.util.List; + +/** + * 期货品种标准合约Mapper接口 + * + * @author tianyongbao + * @date 2025-03-27 + */ +public interface FutureStandardInforMapper +{ + /** + * 查询期货品种标准合约 + * + * @param id 期货品种标准合约主键 + * @return 期货品种标准合约 + */ + public FutureStandardInforVo selectFutureStandardInforById(Long id); + + /** + * 查询期货品种标准合约列表 + * + * @param futureStandardInforDto 期货品种标准合约 + * @return 期货品种标准合约集合 + */ + public List selectFutureStandardInforList(FutureStandardInforDto futureStandardInforDto); + + /** + * 新增期货品种标准合约 + * + * @param futureStandardInfor 期货品种标准合约 + * @return 结果 + */ + public int insertFutureStandardInfor(FutureStandardInfor futureStandardInfor); + + /** + * 修改期货品种标准合约 + * + * @param futureStandardInfor 期货品种标准合约 + * @return 结果 + */ + public int updateFutureStandardInfor(FutureStandardInfor futureStandardInfor); + + /** + * 删除期货品种标准合约 + * + * @param id 期货品种标准合约主键 + * @return 结果 + */ + public int deleteFutureStandardInforById(Long id); + + /** + * 批量删除期货品种标准合约 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteFutureStandardInforByIds(Long[] ids); + + /** + * 逻辑删除期货品种标准合约 + * + * @param id 期货品种标准合约主键 + * @return 结果 + */ + public int removeFutureStandardInforById(Long id); + + /** + * 批量逻辑删除期货品种标准合约 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int removeFutureStandardInforByIds(Long[] ids); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/InvestExchangeMapper.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/InvestExchangeMapper.java new file mode 100644 index 0000000..c65689e --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/InvestExchangeMapper.java @@ -0,0 +1,79 @@ +package com.intc.invest.mapper; + +import java.util.List; +import com.intc.invest.domain.InvestExchange; +import com.intc.invest.domain.dto.InvestExchangeDto; +import com.intc.invest.domain.vo.InvestExchangeVo; + +/** + * 交易所基础信息Mapper接口 + * + * @author tianyongbao + * @date 2025-03-27 + */ +public interface InvestExchangeMapper +{ + /** + * 查询交易所基础信息 + * + * @param id 交易所基础信息主键 + * @return 交易所基础信息 + */ + public InvestExchangeVo selectInvestExchangeById(Long id); + + /** + * 查询交易所基础信息列表 + * + * @param investExchangeDto 交易所基础信息 + * @return 交易所基础信息集合 + */ + public List selectInvestExchangeList(InvestExchangeDto investExchangeDto); + + /** + * 新增交易所基础信息 + * + * @param investExchange 交易所基础信息 + * @return 结果 + */ + public int insertInvestExchange(InvestExchange investExchange); + + /** + * 修改交易所基础信息 + * + * @param investExchange 交易所基础信息 + * @return 结果 + */ + public int updateInvestExchange(InvestExchange investExchange); + + /** + * 删除交易所基础信息 + * + * @param id 交易所基础信息主键 + * @return 结果 + */ + public int deleteInvestExchangeById(Long id); + + /** + * 批量删除交易所基础信息 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteInvestExchangeByIds(Long[] ids); + + /** + * 逻辑删除交易所基础信息 + * + * @param id 交易所基础信息主键 + * @return 结果 + */ + public int removeInvestExchangeById(Long id); + + /** + * 批量逻辑删除交易所基础信息 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int removeInvestExchangeByIds(Long[] ids); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/StockBaseInforMapper.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/StockBaseInforMapper.java new file mode 100644 index 0000000..c7cd1cb --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/mapper/StockBaseInforMapper.java @@ -0,0 +1,79 @@ +package com.intc.invest.mapper; + +import java.util.List; +import com.intc.invest.domain.StockBaseInfor; +import com.intc.invest.domain.dto.StockBaseInforDto; +import com.intc.invest.domain.vo.StockBaseInforVo; + +/** + * 股票基础信息Mapper接口 + * + * @author tianyongbao + * @date 2025-03-27 + */ +public interface StockBaseInforMapper +{ + /** + * 查询股票基础信息 + * + * @param id 股票基础信息主键 + * @return 股票基础信息 + */ + public StockBaseInforVo selectStockBaseInforById(Long id); + + /** + * 查询股票基础信息列表 + * + * @param stockBaseInforDto 股票基础信息 + * @return 股票基础信息集合 + */ + public List selectStockBaseInforList(StockBaseInforDto stockBaseInforDto); + + /** + * 新增股票基础信息 + * + * @param stockBaseInfor 股票基础信息 + * @return 结果 + */ + public int insertStockBaseInfor(StockBaseInfor stockBaseInfor); + + /** + * 修改股票基础信息 + * + * @param stockBaseInfor 股票基础信息 + * @return 结果 + */ + public int updateStockBaseInfor(StockBaseInfor stockBaseInfor); + + /** + * 删除股票基础信息 + * + * @param id 股票基础信息主键 + * @return 结果 + */ + public int deleteStockBaseInforById(Long id); + + /** + * 批量删除股票基础信息 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteStockBaseInforByIds(Long[] ids); + + /** + * 逻辑删除股票基础信息 + * + * @param id 股票基础信息主键 + * @return 结果 + */ + public int removeStockBaseInforById(Long id); + + /** + * 批量逻辑删除股票基础信息 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int removeStockBaseInforByIds(Long[] ids); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IFutureBaseInforService.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IFutureBaseInforService.java new file mode 100644 index 0000000..7e1c99d --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IFutureBaseInforService.java @@ -0,0 +1,64 @@ +package com.intc.invest.service; + +import com.intc.invest.domain.FutureBaseInfor; +import com.intc.invest.domain.dto.FutureBaseInforDto; +import com.intc.invest.domain.vo.FutureBaseInforVo; + +import java.util.List; + +/** + * 期货基本合约Service接口 + * + * @author tianyongbao + * @date 2025-03-28 + */ +public interface IFutureBaseInforService +{ + /** + * 查询期货基本合约 + * + * @param id 期货基本合约主键 + * @return 期货基本合约 + */ + public FutureBaseInforVo selectFutureBaseInforById(Long id); + + /** + * 查询期货基本合约列表 + * + * @param futureBaseInforDto 期货基本合约 + * @return 期货基本合约集合 + */ + public List selectFutureBaseInforList(FutureBaseInforDto futureBaseInforDto); + + /** + * 新增期货基本合约 + * + * @param futureBaseInfor 期货基本合约 + * @return 结果 + */ + public int insertFutureBaseInfor(FutureBaseInfor futureBaseInfor); + + /** + * 修改期货基本合约 + * + * @param futureBaseInfor 期货基本合约 + * @return 结果 + */ + public int updateFutureBaseInfor(FutureBaseInfor futureBaseInfor); + + /** + * 批量删除期货基本合约 + * + * @param ids 需要删除的期货基本合约主键集合 + * @return 结果 + */ + public int deleteFutureBaseInforByIds(Long[] ids); + + /** + * 删除期货基本合约信息 + * + * @param id 期货基本合约主键 + * @return 结果 + */ + public int deleteFutureBaseInforById(Long id); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IFutureStandardInforService.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IFutureStandardInforService.java new file mode 100644 index 0000000..8910b9f --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IFutureStandardInforService.java @@ -0,0 +1,64 @@ +package com.intc.invest.service; + +import com.intc.invest.domain.FutureStandardInfor; +import com.intc.invest.domain.dto.FutureStandardInforDto; +import com.intc.invest.domain.vo.FutureStandardInforVo; + +import java.util.List; + +/** + * 期货品种标准合约Service接口 + * + * @author tianyongbao + * @date 2025-03-27 + */ +public interface IFutureStandardInforService +{ + /** + * 查询期货品种标准合约 + * + * @param id 期货品种标准合约主键 + * @return 期货品种标准合约 + */ + public FutureStandardInforVo selectFutureStandardInforById(Long id); + + /** + * 查询期货品种标准合约列表 + * + * @param futureStandardInforDto 期货品种标准合约 + * @return 期货品种标准合约集合 + */ + public List selectFutureStandardInforList(FutureStandardInforDto futureStandardInforDto); + + /** + * 新增期货品种标准合约 + * + * @param futureStandardInfor 期货品种标准合约 + * @return 结果 + */ + public int insertFutureStandardInfor(FutureStandardInfor futureStandardInfor); + + /** + * 修改期货品种标准合约 + * + * @param futureStandardInfor 期货品种标准合约 + * @return 结果 + */ + public int updateFutureStandardInfor(FutureStandardInfor futureStandardInfor); + + /** + * 批量删除期货品种标准合约 + * + * @param ids 需要删除的期货品种标准合约主键集合 + * @return 结果 + */ + public int deleteFutureStandardInforByIds(Long[] ids); + + /** + * 删除期货品种标准合约信息 + * + * @param id 期货品种标准合约主键 + * @return 结果 + */ + public int deleteFutureStandardInforById(Long id); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IInvestExchangeService.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IInvestExchangeService.java new file mode 100644 index 0000000..67c8246 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IInvestExchangeService.java @@ -0,0 +1,63 @@ +package com.intc.invest.service; + +import java.util.List; +import com.intc.invest.domain.InvestExchange; +import com.intc.invest.domain.dto.InvestExchangeDto; +import com.intc.invest.domain.vo.InvestExchangeVo; + +/** + * 交易所基础信息Service接口 + * + * @author tianyongbao + * @date 2025-03-27 + */ +public interface IInvestExchangeService +{ + /** + * 查询交易所基础信息 + * + * @param id 交易所基础信息主键 + * @return 交易所基础信息 + */ + public InvestExchangeVo selectInvestExchangeById(Long id); + + /** + * 查询交易所基础信息列表 + * + * @param investExchangeDto 交易所基础信息 + * @return 交易所基础信息集合 + */ + public List selectInvestExchangeList(InvestExchangeDto investExchangeDto); + + /** + * 新增交易所基础信息 + * + * @param investExchange 交易所基础信息 + * @return 结果 + */ + public int insertInvestExchange(InvestExchange investExchange); + + /** + * 修改交易所基础信息 + * + * @param investExchange 交易所基础信息 + * @return 结果 + */ + public int updateInvestExchange(InvestExchange investExchange); + + /** + * 批量删除交易所基础信息 + * + * @param ids 需要删除的交易所基础信息主键集合 + * @return 结果 + */ + public int deleteInvestExchangeByIds(Long[] ids); + + /** + * 删除交易所基础信息信息 + * + * @param id 交易所基础信息主键 + * @return 结果 + */ + public int deleteInvestExchangeById(Long id); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IStockBaseInforService.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IStockBaseInforService.java new file mode 100644 index 0000000..defbf51 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/IStockBaseInforService.java @@ -0,0 +1,63 @@ +package com.intc.invest.service; + +import java.util.List; +import com.intc.invest.domain.StockBaseInfor; +import com.intc.invest.domain.dto.StockBaseInforDto; +import com.intc.invest.domain.vo.StockBaseInforVo; + +/** + * 股票基础信息Service接口 + * + * @author tianyongbao + * @date 2025-03-27 + */ +public interface IStockBaseInforService +{ + /** + * 查询股票基础信息 + * + * @param id 股票基础信息主键 + * @return 股票基础信息 + */ + public StockBaseInforVo selectStockBaseInforById(Long id); + + /** + * 查询股票基础信息列表 + * + * @param stockBaseInforDto 股票基础信息 + * @return 股票基础信息集合 + */ + public List selectStockBaseInforList(StockBaseInforDto stockBaseInforDto); + + /** + * 新增股票基础信息 + * + * @param stockBaseInfor 股票基础信息 + * @return 结果 + */ + public int insertStockBaseInfor(StockBaseInfor stockBaseInfor); + + /** + * 修改股票基础信息 + * + * @param stockBaseInfor 股票基础信息 + * @return 结果 + */ + public int updateStockBaseInfor(StockBaseInfor stockBaseInfor); + + /** + * 批量删除股票基础信息 + * + * @param ids 需要删除的股票基础信息主键集合 + * @return 结果 + */ + public int deleteStockBaseInforByIds(Long[] ids); + + /** + * 删除股票基础信息信息 + * + * @param id 股票基础信息主键 + * @return 结果 + */ + public int deleteStockBaseInforById(Long id); +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/FutureBaseInforServiceImpl.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/FutureBaseInforServiceImpl.java new file mode 100644 index 0000000..d2d5d48 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/FutureBaseInforServiceImpl.java @@ -0,0 +1,119 @@ +package com.intc.invest.service.impl; + +import com.intc.common.core.utils.DateUtils; +import com.intc.common.core.utils.IdWorker; +import com.intc.common.security.utils.DictUtils; +import com.intc.common.security.utils.SecurityUtils; +import com.intc.invest.domain.FutureBaseInfor; +import com.intc.invest.domain.dto.FutureBaseInforDto; +import com.intc.invest.domain.vo.FutureBaseInforVo; +import com.intc.invest.mapper.FutureBaseInforMapper; +import com.intc.invest.service.IFutureBaseInforService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +/** + * 期货基本合约Service业务层处理 + * + * @author tianyongbao + * @date 2025-03-28 + */ +@Service +public class FutureBaseInforServiceImpl implements IFutureBaseInforService +{ + @Resource + private FutureBaseInforMapper futureBaseInforMapper; + + /** + * 查询期货基本合约 + * + * @param id 期货基本合约主键 + * @return 期货基本合约 + */ + @Override + public FutureBaseInforVo selectFutureBaseInforById(Long id) + { + return futureBaseInforMapper.selectFutureBaseInforById(id); + } + + /** + * 查询期货基本合约列表 + * + * @param futureBaseInforDto 期货基本合约 + * @return 期货基本合约 + */ + @Override + public List selectFutureBaseInforList(FutureBaseInforDto futureBaseInforDto) + { + List list=futureBaseInforMapper.selectFutureBaseInforList(futureBaseInforDto); + //修改名称加卡号 + for (FutureBaseInforVo base : list) { + String[] tradingTimeNames = base.getTradingTimeName().split("@"); + + String tradingTimeName = ""; + for (String itemId : tradingTimeNames) { + String label= DictUtils.getDictLabel("trading_time",itemId); + tradingTimeName+=label+"、"; + } + base.setTradingTimeName(tradingTimeName.substring(0,tradingTimeName.length()-1)); + + + } + return list; + } + + /** + * 新增期货基本合约 + * + * @param futureBaseInfor 期货基本合约 + * @return 结果 + */ + @Override + public int insertFutureBaseInfor(FutureBaseInfor futureBaseInfor) + { + futureBaseInfor.setCreateBy(SecurityUtils.getUsername()); + futureBaseInfor.setCreateTime(DateUtils.getNowDate()); + futureBaseInfor.setId(IdWorker.getId()); + return futureBaseInforMapper.insertFutureBaseInfor(futureBaseInfor); + } + + /** + * 修改期货基本合约 + * + * @param futureBaseInfor 期货基本合约 + * @return 结果 + */ + @Override + public int updateFutureBaseInfor(FutureBaseInfor futureBaseInfor) + { + futureBaseInfor.setUpdateBy(SecurityUtils.getUsername()); + futureBaseInfor.setUpdateTime(DateUtils.getNowDate()); + return futureBaseInforMapper.updateFutureBaseInfor(futureBaseInfor); + } + + /** + * 批量删除期货基本合约 + * + * @param ids 需要删除的期货基本合约主键 + * @return 结果 + */ + @Override + public int deleteFutureBaseInforByIds(Long[] ids) + { + return futureBaseInforMapper.removeFutureBaseInforByIds(ids); + } + + /** + * 删除期货基本合约信息 + * + * @param id 期货基本合约主键 + * @return 结果 + */ + @Override + public int deleteFutureBaseInforById(Long id) + { + return futureBaseInforMapper.removeFutureBaseInforById(id); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/FutureStandardInforServiceImpl.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/FutureStandardInforServiceImpl.java new file mode 100644 index 0000000..1652938 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/FutureStandardInforServiceImpl.java @@ -0,0 +1,126 @@ +package com.intc.invest.service.impl; + +import com.intc.common.core.utils.DateUtils; +import com.intc.common.core.utils.IdWorker; +import com.intc.common.security.utils.DictUtils; +import com.intc.common.security.utils.SecurityUtils; +import com.intc.invest.domain.FutureStandardInfor; +import com.intc.invest.domain.dto.FutureStandardInforDto; +import com.intc.invest.domain.vo.FutureStandardInforVo; +import com.intc.invest.mapper.FutureStandardInforMapper; +import com.intc.invest.service.IFutureStandardInforService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +/** + * 期货品种标准合约Service业务层处理 + * + * @author tianyongbao + * @date 2025-03-27 + */ +@Service +public class FutureStandardInforServiceImpl implements IFutureStandardInforService +{ + @Resource + private FutureStandardInforMapper futureStandardInforMapper; + + /** + * 查询期货品种标准合约 + * + * @param id 期货品种标准合约主键 + * @return 期货品种标准合约 + */ + @Override + public FutureStandardInforVo selectFutureStandardInforById(Long id) + { + return futureStandardInforMapper.selectFutureStandardInforById(id); + } + + /** + * 查询期货品种标准合约列表 + * + * @param futureStandardInforDto 期货品种标准合约 + * @return 期货品种标准合约 + */ + @Override + public List selectFutureStandardInforList(FutureStandardInforDto futureStandardInforDto) + { + List list=futureStandardInforMapper.selectFutureStandardInforList(futureStandardInforDto); + //修改名称加卡号 + for (FutureStandardInforVo base : list) { + String[] tradingTimeNames = base.getTradingTime().split("@"); + + String tradingTimeName = ""; + for (String itemId : tradingTimeNames) { + String label=DictUtils.getDictLabel("trading_time",itemId); + tradingTimeName+=label+"、"; + } + base.setTradingTimeName(tradingTimeName.substring(0,tradingTimeName.length()-1)); + String[] deliveryMonthNames = base.getDeliveryMonth().split("、"); + + String deliveryMonthName = ""; + for (String itemId : deliveryMonthNames) { + deliveryMonthName+=itemId+"月、"; + } + base.setDeliveryMonthName(deliveryMonthName.substring(0,deliveryMonthName.length()-1)); + + } + + return list; + } + + /** + * 新增期货品种标准合约 + * + * @param futureStandardInfor 期货品种标准合约 + * @return 结果 + */ + @Override + public int insertFutureStandardInfor(FutureStandardInfor futureStandardInfor) + { + futureStandardInfor.setCreateBy(SecurityUtils.getUsername()); + futureStandardInfor.setCreateTime(DateUtils.getNowDate()); + futureStandardInfor.setId(IdWorker.getId()); + return futureStandardInforMapper.insertFutureStandardInfor(futureStandardInfor); + } + + /** + * 修改期货品种标准合约 + * + * @param futureStandardInfor 期货品种标准合约 + * @return 结果 + */ + @Override + public int updateFutureStandardInfor(FutureStandardInfor futureStandardInfor) + { + futureStandardInfor.setUpdateBy(SecurityUtils.getUsername()); + futureStandardInfor.setUpdateTime(DateUtils.getNowDate()); + return futureStandardInforMapper.updateFutureStandardInfor(futureStandardInfor); + } + + /** + * 批量删除期货品种标准合约 + * + * @param ids 需要删除的期货品种标准合约主键 + * @return 结果 + */ + @Override + public int deleteFutureStandardInforByIds(Long[] ids) + { + return futureStandardInforMapper.removeFutureStandardInforByIds(ids); + } + + /** + * 删除期货品种标准合约信息 + * + * @param id 期货品种标准合约主键 + * @return 结果 + */ + @Override + public int deleteFutureStandardInforById(Long id) + { + return futureStandardInforMapper.removeFutureStandardInforById(id); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/InvestExchangeServiceImpl.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/InvestExchangeServiceImpl.java new file mode 100644 index 0000000..1df41e5 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/InvestExchangeServiceImpl.java @@ -0,0 +1,104 @@ +package com.intc.invest.service.impl; + +import com.intc.common.core.utils.DateUtils; +import com.intc.common.core.utils.IdWorker; +import com.intc.common.security.utils.SecurityUtils; +import com.intc.invest.domain.InvestExchange; +import com.intc.invest.domain.dto.InvestExchangeDto; +import com.intc.invest.domain.vo.InvestExchangeVo; +import com.intc.invest.mapper.InvestExchangeMapper; +import com.intc.invest.service.IInvestExchangeService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +/** + * 交易所基础信息Service业务层处理 + * + * @author tianyongbao + * @date 2025-03-27 + */ +@Service +public class InvestExchangeServiceImpl implements IInvestExchangeService +{ + @Resource + private InvestExchangeMapper investExchangeMapper; + + /** + * 查询交易所基础信息 + * + * @param id 交易所基础信息主键 + * @return 交易所基础信息 + */ + @Override + public InvestExchangeVo selectInvestExchangeById(Long id) + { + return investExchangeMapper.selectInvestExchangeById(id); + } + + /** + * 查询交易所基础信息列表 + * + * @param investExchangeDto 交易所基础信息 + * @return 交易所基础信息 + */ + @Override + public List selectInvestExchangeList(InvestExchangeDto investExchangeDto) + { + return investExchangeMapper.selectInvestExchangeList(investExchangeDto); + } + + /** + * 新增交易所基础信息 + * + * @param investExchange 交易所基础信息 + * @return 结果 + */ + @Override + public int insertInvestExchange(InvestExchange investExchange) + { + investExchange.setCreateBy(SecurityUtils.getUsername()); + investExchange.setCreateTime(DateUtils.getNowDate()); + investExchange.setId(IdWorker.getId()); + return investExchangeMapper.insertInvestExchange(investExchange); + } + + /** + * 修改交易所基础信息 + * + * @param investExchange 交易所基础信息 + * @return 结果 + */ + @Override + public int updateInvestExchange(InvestExchange investExchange) + { + investExchange.setUpdateBy(SecurityUtils.getUsername()); + investExchange.setUpdateTime(DateUtils.getNowDate()); + return investExchangeMapper.updateInvestExchange(investExchange); + } + + /** + * 批量删除交易所基础信息 + * + * @param ids 需要删除的交易所基础信息主键 + * @return 结果 + */ + @Override + public int deleteInvestExchangeByIds(Long[] ids) + { + return investExchangeMapper.removeInvestExchangeByIds(ids); + } + + /** + * 删除交易所基础信息信息 + * + * @param id 交易所基础信息主键 + * @return 结果 + */ + @Override + public int deleteInvestExchangeById(Long id) + { + return investExchangeMapper.removeInvestExchangeById(id); + } +} diff --git a/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/StockBaseInforServiceImpl.java b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/StockBaseInforServiceImpl.java new file mode 100644 index 0000000..ff0bf70 --- /dev/null +++ b/intc-modules/intc-invest/src/main/java/com/intc/invest/service/impl/StockBaseInforServiceImpl.java @@ -0,0 +1,104 @@ +package com.intc.invest.service.impl; + +import com.intc.common.core.utils.DateUtils; +import com.intc.common.core.utils.IdWorker; +import com.intc.common.security.utils.SecurityUtils; +import com.intc.invest.domain.StockBaseInfor; +import com.intc.invest.domain.dto.StockBaseInforDto; +import com.intc.invest.domain.vo.StockBaseInforVo; +import com.intc.invest.mapper.StockBaseInforMapper; +import com.intc.invest.service.IStockBaseInforService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.List; + +/** + * 股票基础信息Service业务层处理 + * + * @author tianyongbao + * @date 2025-03-27 + */ +@Service +public class StockBaseInforServiceImpl implements IStockBaseInforService +{ + @Resource + private StockBaseInforMapper stockBaseInforMapper; + + /** + * 查询股票基础信息 + * + * @param id 股票基础信息主键 + * @return 股票基础信息 + */ + @Override + public StockBaseInforVo selectStockBaseInforById(Long id) + { + return stockBaseInforMapper.selectStockBaseInforById(id); + } + + /** + * 查询股票基础信息列表 + * + * @param stockBaseInforDto 股票基础信息 + * @return 股票基础信息 + */ + @Override + public List selectStockBaseInforList(StockBaseInforDto stockBaseInforDto) + { + return stockBaseInforMapper.selectStockBaseInforList(stockBaseInforDto); + } + + /** + * 新增股票基础信息 + * + * @param stockBaseInfor 股票基础信息 + * @return 结果 + */ + @Override + public int insertStockBaseInfor(StockBaseInfor stockBaseInfor) + { + stockBaseInfor.setCreateBy(SecurityUtils.getUsername()); + stockBaseInfor.setCreateTime(DateUtils.getNowDate()); + stockBaseInfor.setId(IdWorker.getId()); + return stockBaseInforMapper.insertStockBaseInfor(stockBaseInfor); + } + + /** + * 修改股票基础信息 + * + * @param stockBaseInfor 股票基础信息 + * @return 结果 + */ + @Override + public int updateStockBaseInfor(StockBaseInfor stockBaseInfor) + { + stockBaseInfor.setUpdateBy(SecurityUtils.getUsername()); + stockBaseInfor.setUpdateTime(DateUtils.getNowDate()); + return stockBaseInforMapper.updateStockBaseInfor(stockBaseInfor); + } + + /** + * 批量删除股票基础信息 + * + * @param ids 需要删除的股票基础信息主键 + * @return 结果 + */ + @Override + public int deleteStockBaseInforByIds(Long[] ids) + { + return stockBaseInforMapper.removeStockBaseInforByIds(ids); + } + + /** + * 删除股票基础信息信息 + * + * @param id 股票基础信息主键 + * @return 结果 + */ + @Override + public int deleteStockBaseInforById(Long id) + { + return stockBaseInforMapper.removeStockBaseInforById(id); + } +} diff --git a/intc-modules/intc-invest/src/main/resources/mapper/invest/FutureBaseInforMapper.xml b/intc-modules/intc-invest/src/main/resources/mapper/invest/FutureBaseInforMapper.xml new file mode 100644 index 0000000..d1295a7 --- /dev/null +++ b/intc-modules/intc-invest/src/main/resources/mapper/invest/FutureBaseInforMapper.xml @@ -0,0 +1,165 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + select + a.id, + a.name, + a.code, + a.standard_id, + a.reference_price, + a.trading_multiplier, + a.price_limit, + a.delivery_month, + a.margin_ratio, + a.last_trading_day, + a.delivery_date, + a.create_by, + a.create_time, + a.update_by, + a.update_time, + a.del_flag, + a.remark, + a.listing_date, + ie."name" as exchange_name, + ifsi."name" as standard_name, + ifsi.trading_time + from + invest_future_base_infor a + left join invest_future_standard_infor ifsi on ifsi.id =a.standard_id + left join invest_exchange ie on ie.id =ifsi.exchange_id + + + + + + + + + insert into invest_future_base_infor + + id, + name, + code, + standard_id, + reference_price, + trading_multiplier, + price_limit, + delivery_month, + margin_ratio, + last_trading_day, + delivery_date, + create_by, + create_time, + update_by, + update_time, + del_flag, + remark, + listing_date, + + + #{id}, + #{name}, + #{code}, + #{standardId}, + #{referencePrice}, + #{tradingMultiplier}, + #{priceLimit}, + #{deliveryMonth}, + #{marginRatio}, + #{lastTradingDay}, + #{deliveryDate}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + #{listingDate}, + + + + + update invest_future_base_infor + + name = #{name}, + code = #{code}, + standard_id = #{standardId}, + reference_price = #{referencePrice}, + trading_multiplier = #{tradingMultiplier}, + price_limit = #{priceLimit}, + delivery_month = #{deliveryMonth}, + margin_ratio = #{marginRatio}, + last_trading_day = #{lastTradingDay}, + delivery_date = #{deliveryDate}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + listing_date = #{listingDate}, + + where id = #{id} + + + + delete from invest_future_base_infor where id = #{id} + + + + delete from invest_future_base_infor where id in + + #{id} + + + + update invest_future_base_infor set del_flag='1' where id = #{id} + + + + update invest_future_base_infor set del_flag='1' where id in + + #{id} + + + diff --git a/intc-modules/intc-invest/src/main/resources/mapper/invest/FutureStandardInforMapper.xml b/intc-modules/intc-invest/src/main/resources/mapper/invest/FutureStandardInforMapper.xml new file mode 100644 index 0000000..6044e20 --- /dev/null +++ b/intc-modules/intc-invest/src/main/resources/mapper/invest/FutureStandardInforMapper.xml @@ -0,0 +1,181 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + select + a.id, + a.name, + a.type, + a.code, + a.exchange_id, + a.trading_unit, + a.minimum_price_fluctuation, + a.trading_time, + a.price_limit, + a.delivery_month, + a.delivery_method, + a.delivery_location, + a.margin_ratio, + a.pricing_unit, + a.last_trading_day, + a.delivery_date, + a.create_by, + a.create_time, + a.update_by, + a.update_time, + a.del_flag, + a.remark, + ie."name" as exchange_name + from + invest_future_standard_infor a + left join invest_exchange ie on ie.id =a.exchange_id + + + + + + + + + insert into invest_future_standard_infor + + id, + name, + type, + code, + exchange_id, + trading_unit, + minimum_price_fluctuation, + trading_time, + price_limit, + delivery_month, + delivery_method, + delivery_location, + margin_ratio, + pricing_unit, + last_trading_day, + delivery_date, + create_by, + create_time, + update_by, + update_time, + del_flag, + remark, + + + #{id}, + #{name}, + #{type}, + #{code}, + #{exchangeId}, + #{tradingUnit}, + #{minimumPriceFluctuation}, + #{tradingTime}, + #{priceLimit}, + #{deliveryMonth}, + #{deliveryMethod}, + #{deliveryLocation}, + #{marginRatio}, + #{pricingUnit}, + #{lastTradingDay}, + #{deliveryDate}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + + + + + update invest_future_standard_infor + + name = #{name}, + type = #{type}, + code = #{code}, + exchange_id = #{exchangeId}, + trading_unit = #{tradingUnit}, + minimum_price_fluctuation = #{minimumPriceFluctuation}, + trading_time = #{tradingTime}, + price_limit = #{priceLimit}, + delivery_month = #{deliveryMonth}, + delivery_method = #{deliveryMethod}, + delivery_location = #{deliveryLocation}, + margin_ratio = #{marginRatio}, + pricing_unit = #{pricingUnit}, + last_trading_day = #{lastTradingDay}, + delivery_date = #{deliveryDate}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + + where id = #{id} + + + + delete from invest_future_standard_infor where id = #{id} + + + + delete from invest_future_standard_infor where id in + + #{id} + + + + update invest_future_standard_infor set del_flag='1' where id = #{id} + + + + update invest_future_standard_infor set del_flag='1' where id in + + #{id} + + + diff --git a/intc-modules/intc-invest/src/main/resources/mapper/invest/InvestExchangeMapper.xml b/intc-modules/intc-invest/src/main/resources/mapper/invest/InvestExchangeMapper.xml new file mode 100644 index 0000000..684767b --- /dev/null +++ b/intc-modules/intc-invest/src/main/resources/mapper/invest/InvestExchangeMapper.xml @@ -0,0 +1,116 @@ + + + + + + + + + + + + + + + + + + + + + + select a.id, a.name, a.type, a.code, a.short_name, a.founding_time, a.create_by, a.create_time, a.update_by, a.update_time, a.del_flag, a.remark, a.introduce from invest_exchange a + + + + + + + + insert into invest_exchange + + id, + name, + type, + code, + short_name, + founding_time, + create_by, + create_time, + update_by, + update_time, + del_flag, + remark, + introduce, + + + #{id}, + #{name}, + #{type}, + #{code}, + #{shortName}, + #{foundingTime}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + #{introduce}, + + + + + update invest_exchange + + name = #{name}, + type = #{type}, + code = #{code}, + short_name = #{shortName}, + founding_time = #{foundingTime}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + introduce = #{introduce}, + + where id = #{id} + + + + delete from invest_exchange where id = #{id} + + + + delete from invest_exchange where id in + + #{id} + + + + update invest_exchange set del_flag='1' where id = #{id} + + + + update invest_exchange set del_flag='1' where id in + + #{id} + + + diff --git a/intc-modules/intc-invest/src/main/resources/mapper/invest/StockBaseInforMapper.xml b/intc-modules/intc-invest/src/main/resources/mapper/invest/StockBaseInforMapper.xml new file mode 100644 index 0000000..5f6667b --- /dev/null +++ b/intc-modules/intc-invest/src/main/resources/mapper/invest/StockBaseInforMapper.xml @@ -0,0 +1,158 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + select + a.id, + a.name, + a.type, + a.code, + a.exchange_id, + a.industry_classification, + a.main_business, + a.listing_date, + a.create_by, + a.create_time, + a.update_by, + a.update_time, + a.del_flag, + a.remark, + a.introduce, + a.region, + a.short_name, + ie."name" as exchange_name + from + invest_stock_base_infor a + left join invest_exchange ie on + ie.id = a.exchange_id + + + + + + + + insert into invest_stock_base_infor + + id, + name, + type, + code, + exchange_id, + industry_classification, + main_business, + listing_date, + create_by, + create_time, + update_by, + update_time, + del_flag, + remark, + introduce, + region, + short_name, + + + #{id}, + #{name}, + #{type}, + #{code}, + #{exchangeId}, + #{industryClassification}, + #{mainBusiness}, + #{listingDate}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + #{introduce}, + #{region}, + #{shortName}, + + + + + update invest_stock_base_infor + + name = #{name}, + type = #{type}, + code = #{code}, + exchange_id = #{exchangeId}, + industry_classification = #{industryClassification}, + main_business = #{mainBusiness}, + listing_date = #{listingDate}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + introduce = #{introduce}, + region = #{region}, + short_name = #{shortName}, + + where id = #{id} + + + + delete from invest_stock_base_infor where id = #{id} + + + + delete from invest_stock_base_infor where id in + + #{id} + + + + update invest_stock_base_infor set del_flag='1' where id = #{id} + + + + update invest_stock_base_infor set del_flag='1' where id in + + #{id} + + +