平台商户
{ycddData.payment_operator_name}
diff --git a/src/pages/OperationCenter/OperationSales/CreditScoreMgm/index.scss b/src/pages/OperationCenter/OperationSales/CreditScoreMgm/index.scss
index 83f96d1..20af6c5 100644
--- a/src/pages/OperationCenter/OperationSales/CreditScoreMgm/index.scss
+++ b/src/pages/OperationCenter/OperationSales/CreditScoreMgm/index.scss
@@ -472,32 +472,68 @@
}
}
.pay-modal {
- .content {
- display: flex;
+ .addrule-btn {
+ display: inline-block;
+ margin: 0 5px;
+ width: 84px;
+ text-align: center;
+ height: 25px;
+ background: linear-gradient(180deg, #3aa9ff, #59b7ff);
+ border-radius: 4px;
+ margin-left: 20px;
+ cursor: pointer;
+ }
+ .pay-box {
+ border: 1px solid #777777;
+ margin-bottom: 16px;
+ padding: 10px;
+ .title {
+ display: inline-block;
+ margin-bottom: 20px;
+ }
+ .delrule-btn {
+ display: inline-block;
+ margin: 0 5px;
+ width: 84px;
+ text-align: center;
+ height: 25px;
+ background: linear-gradient(180deg, #3aa9ff, #59b7ff);
+ border-radius: 4px;
+ margin-left: 20px;
+ cursor: pointer;
+ }
+ .content {
+ display: flex;
- .row-box {
- .row-line {
- margin-bottom: 10px;
+ .row-box {
+ .row-line {
+ margin-bottom: 10px;
- .add-btn {
- display: inline-block;
- border: 1px solid;
- border-radius: 20px;
- font-size: 12px;
- width: 21px;
- text-align: center;
- margin-left: 10px;
- cursor: pointer;
- }
+ .row-select {
+ width: 200px;
+ }
- .del-btn {
- color: #fff;
- border: 1px solid red;
- background: red;
+ .add-btn {
+ display: inline-block;
+ border: 1px solid;
+ border-radius: 20px;
+ font-size: 12px;
+ width: 21px;
+ text-align: center;
+ margin-left: 10px;
+ cursor: pointer;
+ }
+
+ .del-btn {
+ color: #fff;
+ border: 1px solid red;
+ background: red;
+ }
}
- }
+ }
}
}
+
}
\ No newline at end of file
diff --git a/src/pages/OperationCenter/OperationSales/CreditScoreMgm/loadable.jsx b/src/pages/OperationCenter/OperationSales/CreditScoreMgm/loadable.jsx
index 0a10f61..143ae8d 100644
--- a/src/pages/OperationCenter/OperationSales/CreditScoreMgm/loadable.jsx
+++ b/src/pages/OperationCenter/OperationSales/CreditScoreMgm/loadable.jsx
@@ -23,6 +23,20 @@ function CreditScoreMgm() {
const [resultData, setResultData] = useState([])//列表数据
const [detailData, setDetailData] = useState([])//使用记录列表
const [saveData, setSaveData] = useState({})//积分规则配置保存
+ const [flag, setFlag] = useState(1)
+ const [payData, setPayData] = useState({})//充值规则配置
+ const [awardList, setAwardList] = useState([])//充值规则优惠券下拉
+ const [coupon, setCoupon] = useState([
+ {
+ "cid": "1",
+ "couponId": "1817399802436513369",
+ "num": 2
+ },
+ {
+ "cid": "2",
+ "couponId": "1817399802436513369",
+ "num": 5
+ }])//充值规则配置
const [redeemData, setRedeemData] = useState([])//积分兑换配置列表
const [addData, setAddData] = useState({})//积分兑换添加数据
const [awardId, setAwardId] = useState('')//奖品名称下拉数据默认值
@@ -393,6 +407,33 @@ function CreditScoreMgm() {
}
})
}
+ // 充值规则配置列表
+ const getRechargeRulesList = (e) => {
+ ajax.getRechargeRulesList(e).then((e) => {
+ if (e.status == 20000) {
+ setPayVisible(true)
+ setPayData(e.data)
+ }
+ })
+ };
+ // 充值规则配置修改
+ const getRechargeRulesUpdate = (e) => {
+ ajax.getRechargeRulesUpdate(e).then((e) => {
+ if (e.status == 20000) {
+ message.success(e.message)
+ return 1
+ }
+ })
+ };
+ // 充值规则配置移除
+ const getRechargeRulesDel = (e) => {
+ ajax.getRechargeRulesDel(e).then((e) => {
+ if (e.status == 20000) {
+ message.success(e.message)
+ return 1
+ }
+ })
+ };
// 获取下拉数据
const getSelectList = () => {
ajax.getCreditScoreAward().then((e) => {
@@ -402,25 +443,18 @@ function CreditScoreMgm() {
])
})
};
- const acf = () => {
- {
- fields?.map((item, index) => {
- return (
-
-
11
-
{
- let arr = fields
- arr.push(1)
- setFields(arr)
- }
- }>+
-
)
- }
- )
- }
- }
+ // 充值规则优惠券下拉
+ const getRechargeAwardList = () => {
+ ajax.getRechargeAwardList().then((e) => {
+ setAwardList([
+ //...searchSelectList,
+ ...e.data
+ ])
+ })
+ };
useEffect(() => {
getSelectList();
+ getRechargeAwardList();
}, []);
return (
@@ -441,8 +475,7 @@ function CreditScoreMgm() {
type="primary"
style={{ width: '116px' }}
onClick={() => {
- //getRule()
- setPayVisible(true)
+ getRechargeRulesList()
}}
>
充值规则配置
@@ -728,75 +761,139 @@ function CreditScoreMgm() {
+ 充值规则配置
+ {
+ let arr = payData
+ if (arr.list.length > 4) {
+ message.error('最多添加五条规则!')
+ return
+ }
+ arr.list[arr.list.length] =
+ {
+ "rid": "",
+ "recharge": '',
+ "children": [
+ {
+ "cid": "",
+ "couponId": "",
+ "num": ''
+ },
+ ]
+ }
+ setFlag(flag + 1)
+ setPayData(arr)
+ }}>添加规则
+ }
className="pay-modal"
onCancel={() => {
setPayVisible(false);
}}
- onOk={() => { }}
- >
-
+ }) : null
+ }
+ >
>
)
diff --git a/src/pages/OperationCenter/UserMgm/UserInfo/loadable.jsx b/src/pages/OperationCenter/UserMgm/UserInfo/loadable.jsx
index c5fccaa..5a88a10 100644
--- a/src/pages/OperationCenter/UserMgm/UserInfo/loadable.jsx
+++ b/src/pages/OperationCenter/UserMgm/UserInfo/loadable.jsx
@@ -1280,7 +1280,7 @@ function UserInfo() {