Handy_Cao před 3 roky
rodič
revize
5619b817aa

+ 3 - 3
public/proto/thj.proto

@@ -333,7 +333,7 @@ message t2bBankSignReq {
 		optional string MobilePhone = 31; // 移动电话
 		optional string IdentifyCode = 32; // 验证码
 		optional string email = 33; // 电子邮箱
-		optional string extend_info = 34; // 扩展信息(JSON串,参考配置要求进行填充)
+		optional string Extend_Info = 34; // 扩展信息(JSON串,参考配置要求进行填充)
 }
 
 // 签约应答
@@ -410,7 +410,7 @@ message t2bBankWithdrawReq {
 		optional string Desc = 16; // 备注
 		optional string IdentifyCode = 17; // 验证码
 		optional string BranchBankName = 18; // 收款支行名称
-		optional string extend_info = 19; // 扩展信息(JSON串,参考配置要求进行填充)
+		optional string Extend_Info = 19; // 扩展信息(JSON串,参考配置要求进行填充)
 		optional string Remark = 20; // 备注
 		optional string ExchTicket = 21; // 交易所流水号
 }
@@ -451,7 +451,7 @@ message t2bBankDepositReq {
 		optional string OpenCardBankId = 15; // 银行卡行号
 		optional string BankAccoutNum = 16; // 银行卡号
 		optional string BankAccoutName = 17; // 银行卡户名
-		optional string extend_info = 18; // 扩展信息(JSON串,参考配置要求进行填充)
+		optional string Extend_Info = 18; // 扩展信息(JSON串,参考配置要求进行填充)
 }
 
 // 入金应答

+ 4 - 4
src/business/bank/index.ts

@@ -213,7 +213,7 @@ export function useDoWithdraw() {
     const formData = reactive<Partial<Proto.t2bBankWithdrawReq>>({
         AccountType: 0,
         AppDateTime: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
-        extend_info: JSON.stringify({ "sex": 1 })
+        Extend_Info: JSON.stringify({ "sex": 1 })
     })
 
     const onSubmit = async () => {
@@ -247,7 +247,7 @@ export function useDoDeposit() {
     /// 获取当前是否已签约
     const sign = shallowRef<Model.BankAccountSignRsp[]>([])
     /// 常量信息
-    const extendInfo = { certificate_photo_url: '', sex: 1 }
+    const extendInfo = { certificate_photo_url: '' }
     /// formData
     const formData = reactive<Partial<Proto.t2bBankDepositReq>>({})
 
@@ -276,7 +276,7 @@ export function useDoDeposit() {
             data: {
                 ...formData,
                 ExtOperatorID: new Date().getTime(),
-                extend_info: JSON.stringify(extendInfo)
+                Extend_Info: JSON.stringify(extendInfo)
             },
             complete: () => {
                 loading.value = false
@@ -343,7 +343,7 @@ export function useDoBankSign() {
         AgentCertType: 0,
         BankCardType: 0,
         BankAccountType: 1,
-        extend_info: JSON.stringify({ "sex": 1 }),
+        Extend_Info: JSON.stringify({ "sex": 1 }),
         AccountCode: getFirstAccountId().toString(),
         CertID: decryptAES(getUserInfo()?.cardnum ?? ''),
         CertType: getUserInfo()?.cardtypeid.toString(),

+ 33 - 1
src/business/goods/index.ts

@@ -1,6 +1,6 @@
 import { shallowRef } from 'vue'
 import { useDataTable } from '@/hooks/datatable'
-import { queryTHJWrstandard, queryTHJWrstandardDetail, addUserFavoriteGoods, removeUserFavoriteGoods, queryTHJProduct, queryTHJTradeData, querySpotGoodsPrice } from '@/services/api/goods'
+import { queryTHJWrstandard, queryTHJWrstandardDetail, addUserFavoriteGoods, removeUserFavoriteGoods, queryTHJProduct, queryMarketRun, queryTHJTradeData, querySpotGoodsPrice } from '@/services/api/goods'
 import { useLoginStore } from '@/stores'
 
 // 采购列表
@@ -198,3 +198,35 @@ export function useQuerySpotGoodsPriceLists() {
         getQuerySpotGoodsPriceLists,
     }
 }
+
+// 查询市场运行信息
+export function useQueryMarketRunLists() {
+    const { dataList, total, pageIndex, pageSize, pageCount } = useDataTable<Model.MarketRunRsp>()
+    const loading = shallowRef(false)
+
+    const getQueryMarketRunLists = (marketid?: number) => {
+        loading.value = true
+        return queryMarketRun({
+            data: {
+                marketID: marketid
+            },
+            success: (res) => {
+                total.value = res.total
+                dataList.value = res.data
+            }, 
+            complete: () => {
+                loading.value = false
+            }
+        })
+    }
+
+    return {
+        loading,
+        dataList,
+        total,
+        pageIndex,
+        pageSize,
+        pageCount,
+        getQueryMarketRunLists,
+    }
+}

+ 1 - 1
src/packages/mobile/views/bank/wallet/components/deposit/index.vue

@@ -12,7 +12,7 @@
             </CellGroup>
         </Form>
         <div class="g-form__time">
-            <label>提现时间:{{start}}-{{end}}</label>
+            <label>充值提现时间:{{start}}-{{end}}</label>
         </div>
         <template #footer>
             <div class="g-form__footer">

+ 1 - 1
src/packages/mobile/views/bank/wallet/components/withdraw/index.vue

@@ -31,7 +31,7 @@
             </CellGroup>
         </Form>
         <div class="g-form__time">
-            <label>提现时间:{{start}}-{{end}}</label>
+            <label>充值提现时间:{{start}}-{{end}}</label>
         </div>
         <template #footer>
             <div class="g-form__footer">

+ 6 - 0
src/packages/mobile/views/home/components/main/index.less

@@ -81,6 +81,8 @@
         background-color: #fff;
         margin-bottom   : .2rem;
         padding         : .16rem;
+        border-top      : 5px solid #f0f0f0;
+        border-bottom   : 5px solid #f0f0f0;
 
         .left {
             display        : flex;
@@ -89,6 +91,7 @@
             align-items    : center;
             padding        : .24rem;
             border-right   : 1px solid #eee;
+            width: 33%;
 
             h2 {
                 font-size: .36rem;
@@ -104,6 +107,7 @@
         .right {
             flex   : 1;
             padding: 0 .24rem;
+            
 
             table {
                 width    : 100%;
@@ -112,6 +116,8 @@
                 tr {
                     td {
                         line-height: .4rem;
+                        width: 25%;
+                        text-align: center;
                     }
                 }
             }

+ 29 - 17
src/packages/mobile/views/home/components/main/index.vue

@@ -35,31 +35,31 @@
           </li>
         </ul>
       </div>
-      <div class="home-main__banner home-main__banner--body">
-        <Swipe :autoplay="3000" indicator-color="white" lazy-render>
-          <SwipeItem v-for="(item, index) in bodyBanners" :key="index">
-            <img :src="getImageUrl(item.imagepath)" />
-          </SwipeItem>
-        </Swipe>
-      </div>
-      <!-- <div class="home-main__market">
+      <div class="home-main__market">
         <div class="left">
           <h2>合金指数</h2>
-          <span>2022-10-24</span>
+          <span>{{ formatDate(marketRun.tradedate, "YYYY-MM-DD") }}</span>
         </div>
         <div class="right">
           <table cellspacing="0" cellpadding="0">
             <tbody>
-              <tr v-for="i in 3" :key="i">
-                <td>硅锰</td>
-                <td>7000</td>
-                <td>7120</td>
-                <td>2.03%</td>
+              <tr v-for="(item, index) in dataList" :key="index">
+                <td>{{ item.wrstandardname }}</td>
+                <td>{{ item.prespotgoodsprice }}</td>
+                <td>{{ item.todayspotgoodsprice }}</td>
+                <td>{{ item.chg }}</td>
               </tr>
             </tbody>
           </table>
         </div>
-      </div> -->
+      </div>
+      <div class="home-main__banner home-main__banner--body">
+        <Swipe :autoplay="3000" indicator-color="white" lazy-render>
+          <SwipeItem v-for="(item, index) in bodyBanners" :key="index">
+            <img :src="getImageUrl(item.imagepath)" />
+          </SwipeItem>
+        </Swipe>
+      </div>
       <div class="home-main__news">
         <Cell class="titlebar" title-class="titlebar-title" value-class="titlebar-more" title="市场资讯" value="更多资讯"
           :to="{ name: 'news-list' }" is-link />
@@ -82,13 +82,19 @@ import { getImageUrl, formatDate } from '@/filters'
 import { useNavigation } from '@/hooks/navigation'
 import { queryImageConfigs } from '@/services/api/common'
 import { querySiteColumnDetail } from '@/services/api/news'
+import { useQuerySpotGoodsPriceLists } from '@/business/goods'
+import { queryMarketRun } from '@/services/api/goods'
 import AppIconfont from '@mobile/components/base/iconfont/index.vue'
 
 const { routerTo } = useNavigation()
 const refreshing = shallowRef(false) // 是否处于加载中状态
-const topBanners = shallowRef<Model.ImageConfigsRsp[]>([]) // 轮播图列表
-const bodyBanners = shallowRef<Model.ImageConfigsRsp[]>([]) // 轮播图列表
+const topBanners = shallowRef<Model.ImageConfigsRsp[]>([])   // 轮播图列表
+const bodyBanners = shallowRef<Model.ImageConfigsRsp[]>([])  // 轮播图列表
 const newsList = shallowRef<Model.SiteColumnDetailRsp[]>([]) // 资讯列表
+const marketRun = shallowRef<Model.MarketRunRsp>({}) // 资讯列表
+
+const {dataList, getQuerySpotGoodsPriceLists} = useQuerySpotGoodsPriceLists()
+getQuerySpotGoodsPriceLists()
 
 // 下拉刷新
 const onRefresh = () => {
@@ -124,6 +130,12 @@ queryImageConfigs({
   }
 })
 
+queryMarketRun({
+  success: (res) => {
+    marketRun.value = res.data[0]
+  }
+})
+
 onRefresh()
 </script>
 

+ 7 - 0
src/services/api/goods/index.ts

@@ -55,4 +55,11 @@ export function queryTHJWrstandardDetail(params: HttpParams<{ req: Model.THJWrst
  */
  export function querySpotGoodsPrice(params: HttpParams<{ req: Model.SpotGoodsPriceReq, rsp: Model.SpotGoodsPriceRsp[] }>) {
     return httpRequest('/Ferroalloy/GetSpotGoodsPrice', 'get', params);
+}
+
+/**
+ * 查询市场运行信息
+ */
+ export function queryMarketRun(params: HttpParams<{ req: Model.MarketRunReq, rsp: Model.MarketRunRsp[] }>) {
+    return httpRequest('/Market/QueryMarketRun', 'get', params);
 }

+ 38 - 0
src/types/model/goods.d.ts

@@ -241,4 +241,42 @@ declare namespace Model {
         /// 昨价
         ystspotgoodsprice: number
     }
+
+    /** 市场运行信息 响应 */
+    interface MarketRunReq {
+        /// 市场ID,不传返回所有
+        marketID?: number
+    }
+
+    /** 市场运行信息 响应 */
+    interface MarketRunRsp {
+        /// 下下交易日
+        afternexttradedate: string
+        /// 行情清盘标志- 1:未发送 2:已发送 3:已回复
+        clearquoteflag: number
+        /// 最新交易日(结算成功)
+        lastreckondate: string
+        /// 机器时间
+        machinedate: string
+        /// 手动开市标志- 0:否 1:是 (市场为手动时,是否触发了手动开市标志)
+        manualflag: number
+        /// 市场ID
+        marketid: number
+        /// 下一交易日
+        nexttradedate: string
+        /// 上一交易日
+        pretradedate: string
+        /// 结算标识 - 0: 停止结算 1: 正常(管理端控制此字段,交易服务根据此字段判断是否做结算)
+        reckonflag: number
+        /// 运行状态 - 0:初始化 1:待开市 2:开市 3:休市 4:手工休市 5:闭市 6:确认行权开始 7:确认行权结束 10:日终处理开始 11:日终处理成功 12:日终处理失败 13基础服务结算开始 14基础服务结算成功 23.资金结算开始 24.资金结算成功 25.资金结算失败 26.系统结算成功 27.系统结算失败 28.盘中处理开始 29.盘中处理成功 30.盘中处理失败 31.资金结算开始(内) 32.资金结算成功(内) 33.资金结算失败(内) 40.签到开始 41.签到成功 42.签到部份成功 43.签到失败 44.签退开始 45.签退成功 46.签退部份成功 47.签退失败 48.对账开始 49.对账成功 50.对账失败 51.清算开始 52.清算成功 53.清算失败 54.清算部分成功 55. 系统结算开始 62.今日免清算
+        runstatus: number
+        /// 时间段号[多时段时用]
+        sectionid: number
+        /// 当前交易日(服务) 资金结算完成即变更,供交易服务使用
+        tradedate: string
+        /// 当前交易日(行情) 在第一个市场待开市时变更为TradeDate,供行情及终端系统使用
+        tradedate2: string
+        /// 更新时间
+        updatetime: string
+    }
 }

+ 3 - 3
src/types/proto/bank.d.ts

@@ -38,7 +38,7 @@ declare global {
             MobilePhone: string; // 移动电话
             IdentifyCode: string; // 验证码
             email: string; // 电子邮箱
-            extend_info: string; // 扩展信息(JSON串,参考配置要求进行填充)
+            Extend_Info: string; // 扩展信息(JSON串,参考配置要求进行填充)
         }
 
         /** 签约应答 */
@@ -115,7 +115,7 @@ declare global {
             Desc: string; // 备注
             IdentifyCode: string; // 验证码
             BranchBankName: string; // 收款支行名称
-            extend_info: string; // 扩展信息(JSON串,参考配置要求进行填充)
+            Extend_Info: string; // 扩展信息(JSON串,参考配置要求进行填充)
             Remark: string; // 备注
             ExchTicket: string; // 交易所流水号
         }
@@ -156,7 +156,7 @@ declare global {
             OpenCardBankId: string; // 银行卡行号
             BankAccoutNum: string; // 银行卡号
             BankAccoutName: string; // 银行卡户名
-            extend_info: string; // 扩展信息(JSON串,参考配置要求进行填充)
+            Extend_Info: string; // 扩展信息(JSON串,参考配置要求进行填充)
         }
 
         /** 入金应答 */