KgMall B2B/C2C店铺卖家注册流程


 注册流程:
 
 1)创建系统会员,更新Member表,登记会员密码,帐号等基本信息
 2)—创建商城卖家会员,更新MallSaler表,登记店主注册时间,会员类型,电话等
3)开通默认店铺,更新MallShopDianpu表,登记店铺,公司介绍,联系方式,店铺模板,是否开通在线支付等。
 4)初始化店铺相关数据,如根据平台语言版本(中,英),设置店铺有关默认文章分类,简单介绍,相关文档及IM帐号,在线支付业务等。


java代码:

    //店铺业务类型
    
    public static final String ServiceType_B2B="B2B";
    public static final String ServiceType_C2C="C2C";
    public static final String ServiceType_B2B2C="B2B2C";
    public static final String ServiceType_O2O="O2O";
    public static final String ServiceType_ShopinShop="ShopinShop";


package mall.kgmall.mydianpu.init;

import dao.MallShopDianPu;
import service.entryService.MallShopDianPuEntryService;
import mall.kgmall.config.MallConfigUtil;
/*
 * 店铺初始化服务类
 */
public class DianPuInitServiceBean {
    
    
// 初始化店铺相关数据,如根据平台语言版本(中,英),设置店铺有关默认文章分类,简单介绍,相关文档及IM帐号,在线支付业务等。

public void initNewShop(dao.MallShopDianPu dpSaved){
    MallConfigUtil mc=new MallConfigUtil();
    dao.MallShopConfig config=mc.getDefaultMallConfig();    
    
    MallShopDianPuEntryService dpService=MallShopDianPuEntryService.getInstance();
    
    //通用商城店铺初始化
    boolean isopenpayService=config.getBdianpuOpenPayService_newshop();
    if(isopenpayService==true){
        dpSaved.setBopenOnliePay(true);
    }
    
    //更新店铺
    dpService.merge(dpSaved);
    
    
    //专用商城平台业务类型初始化
    
    dao.MallShopDianPu reloadDp=(MallShopDianPu) dpService.get(dpSaved.getDianPuId());
    
    MallShopInitIf shopInitIf=getInitImpl();

    shopInitIf.initShop(reloadDp);
    
}


public MallShopInitIf getInitImpl(){
    MallConfigUtil mc=new MallConfigUtil();
    dao.MallShopConfig config=mc.getDefaultMallConfig();

    //商城平台商业类型
    String serviceType=config.getServiceType();
    
    //
    

    MallShopInitIf shopInitIf=null;
    
    if(serviceType!=null&&serviceType.equals(mc.ServiceType_B2B2C)){
        //商城平台语言版本
        String lan=config.getDefaultLanguage();
        
        if(lan!=null&&lan.equals(mc.C_Lan_Zh_CN)){
            shopInitIf=new B2B2CCnInitUtil();
            
        }else if(lan!=null&&lan.equals(mc.C_Lan_Zh_En)){
            shopInitIf=new B2B2CEnInitUtil();
        }
    }else    if(serviceType!=null&&serviceType.equals(mc.ServiceType_B2B)){
        //商城平台语言版本
        String lan=config.getDefaultLanguage();
        
        if(lan!=null&&lan.equals(mc.C_Lan_Zh_CN)){
            shopInitIf=new B2BCnInitUtil();
            
        }else if(lan!=null&&lan.equals(mc.C_Lan_Zh_En)){
            shopInitIf=new B2BEnInitUtil();
        }
    }else    if(serviceType!=null&&serviceType.equals(mc.ServiceType_C2C)){
        //商城平台语言版本
        String lan=config.getDefaultLanguage();
        
        if(lan!=null&&lan.equals(mc.C_Lan_Zh_CN)){
            
            shopInitIf=new C2CCnInitUtil();
            
        }else if(lan!=null&&lan.equals(mc.C_Lan_Zh_En)){
            shopInitIf=new C2CEnInitUtil();
        }
    }else    if(serviceType!=null&&serviceType.equals(mc.ServiceType_ShopinShop)){
        //商城平台语言版本
        String lan=config.getDefaultLanguage();
        
        if(lan!=null&&lan.equals(mc.C_Lan_Zh_CN)){
            shopInitIf=new ShopinShopCnInitUtil();
            
        }else if(lan!=null&&lan.equals(mc.C_Lan_Zh_En)){
            shopInitIf=new ShopinShopEnInitUtil();
        }
    }else    if(serviceType!=null&&serviceType.equals(mc.ServiceType_O2O)){
        //商城平台语言版本
        String lan=config.getDefaultLanguage();
        
        if(lan!=null&&lan.equals(mc.C_Lan_Zh_CN)){
            shopInitIf=new O2OCnInitUtil();
        }else if(lan!=null&&lan.equals(mc.C_Lan_Zh_En)){
            shopInitIf=new O2OEnInitUtil();
        }
        
        
        
    }
    
    return shopInitIf;
    
    
}

}



转载于:https://my.oschina.net/u/206693/blog/210608

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值