姜永辉 1 年之前
父節點
當前提交
bdb1838dc5

+ 1 - 1
api/pages/sharesign/integral.js

@@ -10,7 +10,7 @@
 module.exports = {
 	integralService: { 
 		// 前缀
-		prefix: 'oauth-server/integral/',
+		prefix: 'oauth-server/oauth/integral/',
 	},
 	routeUrl: {
 		integral: {

+ 9 - 0
package-basic-data/pages/register/company-register/company-register.js

@@ -1,3 +1,12 @@
+/*******************************************************************************
+* Copyright(c) 2022 dongke All rights reserved. / Confidential
+* 类的信息:
+*		1.程序名称:
+*		2.功能描述:注册商户画面
+* 编辑履历:
+*		作者				日期					版本				修改内容
+*		姜永辉		  	2022-11-22			1.00		   	新建
+*******************************************************************************/
 const mixins = require('@/mixins/index.js')
 const util = require('@/utils/util.js')
 const Constants = require('@/utils/Constants.js');

+ 61 - 6
package-basic-data/pages/sign/sign.js

@@ -1,7 +1,15 @@
+/*******************************************************************************
+* Copyright(c) 2022 dongke All rights reserved. / Confidential
+* 类的信息:
+*		1.程序名称:
+*		2.功能描述:签到画面
+* 编辑履历:
+*		作者				日期					版本				修改内容
+*		姜永辉		  	2022-11-22			1.00		   	新建
+*******************************************************************************/
 const Constants = require('@/utils/Constants.js');
 const mixins = require('@/mixins/index.js');
 const app = getApp()
-
 Page({
     mixins: [mixins],
     /**
@@ -14,20 +22,35 @@ Page({
         versionName: '',
         // 路由
         routeObjName: 'sign',
-        integralTacticService: app.globalData['integralTacticService'],
+        // 策略
+        integralTacticItem: {},
+        // 积分
+        integral: 0,
+        // 优惠券
+        couponCount: 0,
     },
 
     /**
      * 生命周期函数--监听页面加载
      */
     onLoad(options) {
+        // 策略
         this.getIntegralTactic()
+        // 积分
+        this.getIntegral()
     },
 
     loadInit() {
+        // 版本
         this.setData({
             versionName: this.data.freeVersionFlag ? mixins.$t('standardVersion') : mixins.$t('professionalVersion')
         })
+
+        // 调用保存 签到接口
+
+        // 查询接口
+
+
     },
 
 
@@ -41,13 +64,45 @@ Page({
         let service = app.globalData['integralTacticService']
         this.excute(service, service.selectByCond, params).then(res => {
             if (res.data.code == Constants.SUCESS_CODE) {
-                console.log(res.data, "getIntegralTactic");
-                if (res.data && res.data.data) {
-                    let activityTable = res.data.data;
-
+                if (res.data && res.data.data.list && res.data.data.list.length > 0) {
+                    this.setData({
+                        integralTacticItem: res.data.data.list[0],
+                    })
                 }
             }
         });
     },
 
+    /**
+    * @desc : 公司积分
+    * @author : 姜永辉
+    * @date : 2024/4/1
+    */
+    getIntegral() {
+        let params = {}
+        let service = app.globalData['integralService']
+        // 10002024-0718-0000-0000-000005c0a01e app.globalData.company.cpId
+        this.excute(service, '10002024-0718-0000-0000-000005c0a01e', params).then(res => {
+            console.log(res.data);
+            if (res.data.code == Constants.SUCESS_CODE) {
+
+            }
+        });
+    },
+    /**
+    * @desc : 优惠券
+    * @author : 姜永辉
+    * @date : 2024/4/1
+    */
+    getCouponCount() {
+        let params = {}
+        let service = app.globalData['couponService'] 
+        this.excute(service, '10002024-0718-0000-0000-000005c0a01e', params).then(res => {
+            console.log(res.data);
+            if (res.data.code == Constants.SUCESS_CODE) {
+
+            }
+        });
+    },
+
 })

+ 2 - 2
package-basic-data/pages/sign/sign.wxml

@@ -18,10 +18,10 @@
 		<view class="integral-info">
 			<view class="integral-item">
 				<view class="item">
-					公司云币:<view class="number">10,000</view>个
+					公司云币:<view class="number">{{integral}}</view>个
 				</view>
 				<view class="item">
-					优惠券:<view class="number">1</view>张
+					优惠券:<view class="number">{{couponCount}}</view>张
 				</view>
 			</view>
 			<view class="rearmk-view">