boluo-app-main/src/store/reducers/partner.ts
2025-05-15 01:02:00 +08:00

23 lines
503 B
TypeScript

import { Action } from 'redux';
import { PartnerInfo } from '@/types/partner';
import { SET_INVITE_CODE } from '../constants';
const INIT_STATE: Partial<PartnerInfo> = {};
const partnerInfo = (state: Partial<PartnerInfo> = INIT_STATE, action: Action): Partial<PartnerInfo> => {
const { type, value } = action as BL.Anything;
switch (type) {
case SET_INVITE_CODE: {
return {
inviteCode: value,
};
}
default:
return state;
}
};
export default partnerInfo;