├── App ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── mipmap-hdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── drawable-xxhdpi │ │ │ │ ├── icon_scan.png │ │ │ │ ├── bg_me_header.png │ │ │ │ ├── icon_address.png │ │ │ │ ├── icon_order.png │ │ │ │ ├── icon_setting.png │ │ │ │ ├── icon_share.png │ │ │ │ ├── icon_special.png │ │ │ │ ├── home_container_bg.jpeg │ │ │ │ ├── icon_order_wait_pay.png │ │ │ │ ├── icon_order_completed.png │ │ │ │ └── icon_order_wait_confirm.png │ │ │ ├── mipmap-xhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── colors.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ │ ├── ic_launcher.xml │ │ │ │ └── ic_launcher_round.xml │ │ │ └── layout │ │ │ │ ├── activity_main.xml │ │ │ │ ├── activity_setting.xml │ │ │ │ └── layout_topic_item.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── kotlin │ │ │ │ └── mall │ │ │ │ ├── common │ │ │ │ └── MainApplication.kt │ │ │ │ └── ui │ │ │ │ ├── fragment │ │ │ │ └── MessageFragment.kt │ │ │ │ ├── activity │ │ │ │ └── SettingActivity.kt │ │ │ │ └── adapter │ │ │ │ └── TopicAdapter.kt │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── mall │ │ │ └── ExampleUnitTest.kt │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── mall │ │ └── ExampleInstrumentedTest.kt ├── proguard-rules.pro └── build.gradle ├── PaySDK ├── .gitignore ├── libs │ └── alipaySdk-20170725.jar ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── styles.xml │ │ │ └── drawable-xxhdpi │ │ │ │ ├── pay_type_bank.png │ │ │ │ ├── pay_type_alipay.png │ │ │ │ └── pay_type_weixin.png │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── pay │ │ │ ├── data │ │ │ ├── protocol │ │ │ │ ├── PayOrderReq.kt │ │ │ │ └── GetPaySignReq.kt │ │ │ ├── api │ │ │ │ └── PayApi.kt │ │ │ └── repository │ │ │ │ └── PayRepository.kt │ │ │ ├── c.kt │ │ │ ├── ui │ │ │ └── cc.kt │ │ │ ├── presenter │ │ │ ├── view │ │ │ │ └── PayView.kt │ │ │ └── PayPresenter.kt │ │ │ ├── service │ │ │ ├── PayService.kt │ │ │ └── impl │ │ │ │ └── PayServiceImpl.kt │ │ │ └── injection │ │ │ ├── module │ │ │ └── PayModule.kt │ │ │ └── component │ │ │ └── PayComponent.kt │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── pay │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── pay │ │ └── ExampleInstrumentedTest.java └── proguard-rules.pro ├── BaseLibrary ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ ├── ids.xml │ │ │ │ ├── attrs.xml │ │ │ │ ├── strings.xml │ │ │ │ ├── dimens.xml │ │ │ │ └── colors.xml │ │ │ ├── drawable-xxhdpi │ │ │ │ ├── icon_back.png │ │ │ │ ├── loading0.png │ │ │ │ ├── loading1.png │ │ │ │ ├── loading2.png │ │ │ │ ├── loading3.png │ │ │ │ ├── loading4.png │ │ │ │ ├── loading5.png │ │ │ │ ├── loading6.png │ │ │ │ ├── loading7.png │ │ │ │ ├── icon_arrow.png │ │ │ │ ├── icon_search.png │ │ │ │ ├── icon_box_nor.png │ │ │ │ ├── default_loading.png │ │ │ │ ├── icon_box_checked.png │ │ │ │ ├── icon_state_error.png │ │ │ │ ├── btn_nav_cart_normal.png │ │ │ │ ├── btn_nav_cart_press.png │ │ │ │ ├── btn_nav_home_normal.png │ │ │ │ ├── btn_nav_home_press.png │ │ │ │ ├── btn_nav_msg_normal.png │ │ │ │ ├── btn_nav_msg_press.png │ │ │ │ ├── btn_nav_user_normal.png │ │ │ │ ├── btn_nav_user_press.png │ │ │ │ ├── icon_default_user.png │ │ │ │ ├── icon_favorite_nor.png │ │ │ │ ├── icon_favorite_checked.png │ │ │ │ ├── btn_nav_category_normal.png │ │ │ │ ├── btn_nav_category_press.png │ │ │ │ ├── light_progress_loading1.png │ │ │ │ ├── light_progress_loading10.png │ │ │ │ ├── light_progress_loading11.png │ │ │ │ ├── light_progress_loading2.png │ │ │ │ ├── light_progress_loading3.png │ │ │ │ ├── light_progress_loading4.png │ │ │ │ ├── light_progress_loading5.png │ │ │ │ ├── light_progress_loading6.png │ │ │ │ ├── light_progress_loading7.png │ │ │ │ ├── light_progress_loading8.png │ │ │ │ └── light_progress_loading9.png │ │ │ ├── drawable │ │ │ │ ├── btn_common_nor.xml │ │ │ │ ├── btn_common_disable.xml │ │ │ │ ├── btn_common_pressed.xml │ │ │ │ ├── border_all.xml │ │ │ │ ├── border_corner_all.xml │ │ │ │ ├── border_corner_all_blue.xml │ │ │ │ ├── bottom_nav_text_selector.xml │ │ │ │ ├── corner_blue_white_bg.xml │ │ │ │ ├── corner_gray_white_bg.xml │ │ │ │ ├── tab_selector.xml │ │ │ │ ├── home_header_corner_bg.xml │ │ │ │ ├── progress_dialog_bg.xml │ │ │ │ ├── btn_common_selector.xml │ │ │ │ ├── common_check_selector.xml │ │ │ │ ├── border_top.xml │ │ │ │ ├── border_bottom.xml │ │ │ │ ├── border_bottom_gray.xml │ │ │ │ ├── collect_selector.xml │ │ │ │ ├── bottom_nav_cart_selector.xml │ │ │ │ ├── state_loading.xml │ │ │ │ └── progress_dialog_anim.xml │ │ │ ├── anim │ │ │ │ ├── push_bottom_in.xml │ │ │ │ └── push_bottom_out.xml │ │ │ └── layout │ │ │ │ ├── layout_state_empty.xml │ │ │ │ ├── progress_dialog.xml │ │ │ │ ├── layout_state_error.xml │ │ │ │ ├── layout_label_textview.xml │ │ │ │ ├── layout_state_loading.xml │ │ │ │ └── layout_header_bar.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── kotlin │ │ │ │ └── base │ │ │ │ ├── rx │ │ │ │ ├── BaseException.kt │ │ │ │ ├── BaseFunc.kt │ │ │ │ ├── BaseSubscriber.kt │ │ │ │ └── BaseFuncBoolean.kt │ │ │ │ ├── ui │ │ │ │ ├── fragment │ │ │ │ │ └── BaseFragment.kt │ │ │ │ ├── activity │ │ │ │ │ └── BaseActivity.kt │ │ │ │ └── adapter │ │ │ │ │ └── BaseRecyclerViewAdapter.kt │ │ │ │ ├── presenter │ │ │ │ ├── view │ │ │ │ │ └── BaseView.kt │ │ │ │ └── BasePresenter.kt │ │ │ │ ├── common │ │ │ │ ├── ResultCode.kt │ │ │ │ ├── BaseConstant.kt │ │ │ │ └── BaseApplication.kt │ │ │ │ ├── injection │ │ │ │ ├── ActivityScope.kt │ │ │ │ ├── PerComponentScope.kt │ │ │ │ ├── component │ │ │ │ │ ├── AppComponent.kt │ │ │ │ │ └── ActivityComponent.kt │ │ │ │ └── module │ │ │ │ │ ├── LifecycleProviderModule.kt │ │ │ │ │ ├── AppModule.kt │ │ │ │ │ └── ActivityModule.kt │ │ │ │ ├── data │ │ │ │ └── protocol │ │ │ │ │ └── BaseResp.kt │ │ │ │ ├── widgets │ │ │ │ ├── DefaultTextWatcher.kt │ │ │ │ ├── BannerImageLoader.kt │ │ │ │ └── LabelTextView.kt │ │ │ │ └── utils │ │ │ │ ├── NetWorkUtils.kt │ │ │ │ └── GlideUtils.kt │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── base │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── base │ │ └── ExampleInstrumentedTest.java └── proguard-rules.pro ├── GoodsCenter ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ └── strings.xml │ │ │ ├── drawable-xxhdpi │ │ │ │ ├── icon_gray_more.png │ │ │ │ ├── category_banner.png │ │ │ │ └── icon_search_history.png │ │ │ ├── drawable-xxxhdpi │ │ │ │ └── add_cart_pop_close.png │ │ │ ├── drawable │ │ │ │ ├── sku_text_selector.xml │ │ │ │ ├── top_category_bg_selector.xml │ │ │ │ ├── top_category_text_selector.xml │ │ │ │ └── sku_bg_selector.xml │ │ │ └── layout │ │ │ │ ├── activity_cart.xml │ │ │ │ ├── layout_top_category_item.xml │ │ │ │ ├── layout_search_history_item.xml │ │ │ │ ├── layout_second_category_item.xml │ │ │ │ ├── fragment_goods_detail_tab_two.xml │ │ │ │ ├── layout_sku_view.xml │ │ │ │ ├── layout_sku_item.xml │ │ │ │ ├── activity_goods.xml │ │ │ │ └── layout_goods_item.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── kotlin │ │ │ │ └── goods │ │ │ │ ├── event │ │ │ │ ├── AddCartEvent.kt │ │ │ │ ├── SkuChangedEvent.kt │ │ │ │ ├── UpdateCartSizeEvent.kt │ │ │ │ ├── UpdateTotalPriceEvent.kt │ │ │ │ ├── CartAllCheckedEvent.kt │ │ │ │ └── GoodsDetailImageEvent.kt │ │ │ │ ├── data │ │ │ │ ├── protocol │ │ │ │ │ ├── GetGoodsDetailReq.kt │ │ │ │ │ ├── GetCategoryReq.kt │ │ │ │ │ ├── GetGoodsListReq.kt │ │ │ │ │ ├── DeleteCartReq.kt │ │ │ │ │ ├── SubmitCartReq.kt │ │ │ │ │ ├── GetGoodsListByKeywordReq.kt │ │ │ │ │ ├── GoodsSku.kt │ │ │ │ │ ├── Category.kt │ │ │ │ │ ├── AddCartReq.kt │ │ │ │ │ ├── CartGoods.kt │ │ │ │ │ └── Goods.kt │ │ │ │ ├── a.kt │ │ │ │ ├── api │ │ │ │ │ ├── CategoryApi.kt │ │ │ │ │ ├── GoodsApi.kt │ │ │ │ │ └── CartApi.kt │ │ │ │ └── repository │ │ │ │ │ ├── CategoryRepository.kt │ │ │ │ │ └── GoodsRepository.kt │ │ │ │ ├── ui │ │ │ │ ├── a.kt │ │ │ │ ├── activity │ │ │ │ │ └── CartActivity.kt │ │ │ │ └── adapter │ │ │ │ │ ├── GoodsDetailVpAdapter.kt │ │ │ │ │ ├── SearchHistoryAdapter.kt │ │ │ │ │ ├── SecondCategoryAdapter.kt │ │ │ │ │ └── TopCategoryAdapter.kt │ │ │ │ ├── Ext.kt │ │ │ │ ├── service │ │ │ │ ├── CategoryService.kt │ │ │ │ ├── GoodsService.kt │ │ │ │ ├── impl │ │ │ │ │ ├── CategoryServiceImpl.kt │ │ │ │ │ └── GoodsServiceImpl.kt │ │ │ │ └── CartService.kt │ │ │ │ ├── presenter │ │ │ │ ├── view │ │ │ │ │ ├── GoodsListView.kt │ │ │ │ │ ├── CategoryView.kt │ │ │ │ │ ├── GoodsDetailView.kt │ │ │ │ │ └── CartListView.kt │ │ │ │ └── CategoryPresenter.kt │ │ │ │ ├── injection │ │ │ │ ├── module │ │ │ │ │ ├── GoodsModule.kt │ │ │ │ │ ├── CategoryModule.kt │ │ │ │ │ └── CartModule.kt │ │ │ │ └── component │ │ │ │ │ ├── CategoryComponent.kt │ │ │ │ │ ├── CartComponent.kt │ │ │ │ │ └── GoodsComponent.kt │ │ │ │ └── common │ │ │ │ └── GoodsConstant.kt │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── goods │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── goods │ │ └── ExampleInstrumentedTest.java └── proguard-rules.pro ├── OrderCenter ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── styles.xml │ │ │ ├── drawable-xxhdpi │ │ │ │ └── icon_shop.png │ │ │ └── layout │ │ │ │ ├── fragment_order.xml │ │ │ │ ├── activity_order.xml │ │ │ │ └── activity_address.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── kotlin │ │ │ │ └── order │ │ │ │ ├── data │ │ │ │ ├── protocol │ │ │ │ │ ├── CancelOrderReq.kt │ │ │ │ │ ├── SubmitOrderReq.kt │ │ │ │ │ ├── ConfirmOrderReq.kt │ │ │ │ │ ├── DeleteShipAddressReq.kt │ │ │ │ │ ├── GetOrderByIdReq.kt │ │ │ │ │ ├── GetOrderListReq.kt │ │ │ │ │ ├── AddShipAddressReq.kt │ │ │ │ │ ├── EditShipAddressReq.kt │ │ │ │ │ ├── Order.kt │ │ │ │ │ ├── OrderGoods.kt │ │ │ │ │ └── ShipAddress.kt │ │ │ │ └── api │ │ │ │ │ ├── OrderApi.kt │ │ │ │ │ └── ShipAddressApi.kt │ │ │ │ ├── a.kt │ │ │ │ ├── event │ │ │ │ └── SelectAddressEvent.kt │ │ │ │ ├── presenter │ │ │ │ ├── view │ │ │ │ │ ├── OrderDetailView.kt │ │ │ │ │ ├── OrderConfirmView.kt │ │ │ │ │ ├── EditShipAddressView.kt │ │ │ │ │ ├── OrderListView.kt │ │ │ │ │ └── ShipAddressView.kt │ │ │ │ └── OrderDetailPresenter.kt │ │ │ │ ├── common │ │ │ │ ├── OrderStatus.kt │ │ │ │ └── OrderConstant.kt │ │ │ │ ├── injection │ │ │ │ ├── module │ │ │ │ │ ├── OrderModule.kt │ │ │ │ │ └── ShipAddressModule.kt │ │ │ │ └── component │ │ │ │ │ ├── ShipAddressComponent.kt │ │ │ │ │ └── OrderComponent.kt │ │ │ │ ├── service │ │ │ │ ├── ShipAddressService.kt │ │ │ │ └── OrderService.kt │ │ │ │ └── ui │ │ │ │ ├── adapter │ │ │ │ └── OrderVpAdapter.kt │ │ │ │ └── activity │ │ │ │ └── OrderActivity.kt │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── order │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── order │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── Provider ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ └── values │ │ │ │ └── strings.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── provider │ │ │ ├── v.kt │ │ │ ├── common │ │ │ ├── ProviderConstant.kt │ │ │ └── CommonUtils.kt │ │ │ └── router │ │ │ └── RouterPath.kt │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── provider │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── provider │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── UserCenter ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── styles.xml │ │ │ ├── drawable-xxhdpi │ │ │ │ ├── icon_phone.png │ │ │ │ ├── icon_pwd.png │ │ │ │ ├── icon_user_name.png │ │ │ │ └── icon_verify_code.png │ │ │ └── drawable │ │ │ │ ├── gender_bg_selector.xml │ │ │ │ ├── gender_nor_bg.xml │ │ │ │ ├── gender_checked_bg.xml │ │ │ │ └── gender_text_selector.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── kotlin │ │ │ │ └── user │ │ │ │ ├── data │ │ │ │ ├── protocol │ │ │ │ │ ├── ResetPwdReq.kt │ │ │ │ │ ├── ForgetPwdReq.kt │ │ │ │ │ ├── LoginReq.kt │ │ │ │ │ ├── RegisterReq.kt │ │ │ │ │ ├── EditUserReq.kt │ │ │ │ │ └── UserInfo.kt │ │ │ │ ├── api │ │ │ │ │ ├── UploadApi.kt │ │ │ │ │ └── UserApi.kt │ │ │ │ └── respository │ │ │ │ │ └── UploadRepository.kt │ │ │ │ ├── test.java │ │ │ │ ├── ui │ │ │ │ └── a.java │ │ │ │ ├── service │ │ │ │ ├── UploadService.kt │ │ │ │ ├── impl │ │ │ │ │ └── UploadServiceImpl.kt │ │ │ │ └── UserService.kt │ │ │ │ ├── presenter │ │ │ │ ├── view │ │ │ │ │ ├── RegisterView.kt │ │ │ │ │ ├── ResetPwdView.kt │ │ │ │ │ ├── LoginView.kt │ │ │ │ │ ├── ForgetPwdView.kt │ │ │ │ │ └── UserInfoView.kt │ │ │ │ ├── ForgetPwdPresenter.kt │ │ │ │ ├── LoginPresenter.kt │ │ │ │ ├── ResetPwdPresenter.kt │ │ │ │ └── RegisterPresenter.kt │ │ │ │ ├── injection │ │ │ │ ├── module │ │ │ │ │ ├── UserModule.kt │ │ │ │ │ └── UploadModule.kt │ │ │ │ └── component │ │ │ │ │ └── UserComponent.kt │ │ │ │ └── utils │ │ │ │ └── UserPrefsUtils.kt │ │ └── AndroidManifest.xml │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── user │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── user │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── MessageCenter ├── .gitignore ├── src │ ├── main │ │ ├── res │ │ │ ├── values │ │ │ │ ├── strings.xml │ │ │ │ └── dimens.xml │ │ │ ├── drawable-xxhdpi │ │ │ │ └── icon_news.png │ │ │ ├── anim │ │ │ │ ├── news_bottom_out.xml │ │ │ │ └── news_bottom_in.xml │ │ │ ├── drawable │ │ │ │ └── corner_news_bg.xml │ │ │ └── layout │ │ │ │ └── layout_news_flipper.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── message │ │ │ └── a.kt │ ├── test │ │ └── java │ │ │ └── com │ │ │ └── kotlin │ │ │ └── message │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── com │ │ └── kotlin │ │ └── message │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── .idea ├── dictionaries │ └── guiyanbing.xml ├── runConfigurations.xml └── gradle.xml ├── settings.gradle ├── .gitignore └── gradle.properties /App/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /PaySDK/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /BaseLibrary/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /GoodsCenter/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /OrderCenter/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /Provider/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /UserCenter/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /MessageCenter/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/values/ids.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /PaySDK/libs/alipaySdk-20170725.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/PaySDK/libs/alipaySdk-20170725.jar -------------------------------------------------------------------------------- /PaySDK/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | PaySDK 3 | 4 | -------------------------------------------------------------------------------- /Provider/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Provider 3 | 4 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /UserCenter/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | UserCenter 3 | 4 | -------------------------------------------------------------------------------- /.idea/dictionaries/guiyanbing.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | GoodsCenter 3 | 4 | -------------------------------------------------------------------------------- /MessageCenter/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | MessageCenter 3 | 4 | -------------------------------------------------------------------------------- /OrderCenter/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | OrderCenter 3 | 4 | -------------------------------------------------------------------------------- /App/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /App/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':App', ':BaseLibrary', ':UserCenter', ':Provider', ':MessageCenter', ':OrderCenter', ':GoodsCenter', ':PaySDK' 2 | -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_scan.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_scan.png -------------------------------------------------------------------------------- /App/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /App/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/bg_me_header.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/bg_me_header.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_address.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_address.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_order.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_order.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_setting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_setting.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_share.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_share.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_special.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_special.png -------------------------------------------------------------------------------- /App/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /Provider/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | -------------------------------------------------------------------------------- /App/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /App/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /App/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/event/AddCartEvent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.event 2 | 3 | /* 4 | 加入购物车事件 5 | */ 6 | class AddCartEvent 7 | -------------------------------------------------------------------------------- /MessageCenter/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | -------------------------------------------------------------------------------- /App/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /App/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_back.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_back.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading0.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading1.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading2.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading3.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading4.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading5.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading6.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/loading7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/loading7.png -------------------------------------------------------------------------------- /OrderCenter/src/main/res/drawable-xxhdpi/icon_shop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/OrderCenter/src/main/res/drawable-xxhdpi/icon_shop.png -------------------------------------------------------------------------------- /PaySDK/src/main/res/drawable-xxhdpi/pay_type_bank.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/PaySDK/src/main/res/drawable-xxhdpi/pay_type_bank.png -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable-xxhdpi/icon_phone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/UserCenter/src/main/res/drawable-xxhdpi/icon_phone.png -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable-xxhdpi/icon_pwd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/UserCenter/src/main/res/drawable-xxhdpi/icon_pwd.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/home_container_bg.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/home_container_bg.jpeg -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_order_wait_pay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_order_wait_pay.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_arrow.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_search.png -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/event/SkuChangedEvent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.event 2 | 3 | /* 4 | SKU变化事件 5 | */ 6 | class SkuChangedEvent 7 | -------------------------------------------------------------------------------- /MessageCenter/src/main/res/drawable-xxhdpi/icon_news.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/MessageCenter/src/main/res/drawable-xxhdpi/icon_news.png -------------------------------------------------------------------------------- /PaySDK/src/main/res/drawable-xxhdpi/pay_type_alipay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/PaySDK/src/main/res/drawable-xxhdpi/pay_type_alipay.png -------------------------------------------------------------------------------- /PaySDK/src/main/res/drawable-xxhdpi/pay_type_weixin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/PaySDK/src/main/res/drawable-xxhdpi/pay_type_weixin.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_order_completed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_order_completed.png -------------------------------------------------------------------------------- /App/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | KotlinMall 3 | 登录/注册 4 | 5 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_box_nor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_box_nor.png -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable-xxhdpi/icon_gray_more.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/GoodsCenter/src/main/res/drawable-xxhdpi/icon_gray_more.png -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable-xxhdpi/icon_user_name.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/UserCenter/src/main/res/drawable-xxhdpi/icon_user_name.png -------------------------------------------------------------------------------- /App/src/main/res/drawable-xxhdpi/icon_order_wait_confirm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/App/src/main/res/drawable-xxhdpi/icon_order_wait_confirm.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/default_loading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/default_loading.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_box_checked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_box_checked.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_state_error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_state_error.png -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/event/UpdateCartSizeEvent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.event 2 | 3 | /* 4 | 更新购物车数量事件 5 | */ 6 | class UpdateCartSizeEvent 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/event/UpdateTotalPriceEvent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.event 2 | 3 | /* 4 | 更新总价事件 5 | */ 6 | class UpdateTotalPriceEvent 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable-xxhdpi/category_banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/GoodsCenter/src/main/res/drawable-xxhdpi/category_banner.png -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable-xxhdpi/icon_verify_code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/UserCenter/src/main/res/drawable-xxhdpi/icon_verify_code.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_cart_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_cart_normal.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_cart_press.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_cart_press.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_home_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_home_normal.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_home_press.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_home_press.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_msg_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_msg_normal.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_msg_press.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_msg_press.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_user_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_user_normal.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_user_press.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_user_press.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_default_user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_default_user.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_favorite_nor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_favorite_nor.png -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable-xxhdpi/icon_search_history.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/GoodsCenter/src/main/res/drawable-xxhdpi/icon_search_history.png -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable-xxxhdpi/add_cart_pop_close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/GoodsCenter/src/main/res/drawable-xxxhdpi/add_cart_pop_close.png -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/data/protocol/PayOrderReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.data.protocol 2 | 3 | /* 4 | 支付订单 5 | */ 6 | data class PayOrderReq(val orderId:Int) 7 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/icon_favorite_checked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/icon_favorite_checked.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_category_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_category_normal.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_category_press.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/btn_nav_category_press.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading1.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading10.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading11.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading2.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading3.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading4.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading5.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading6.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading7.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading8.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/guiyanbing/songster/HEAD/BaseLibrary/src/main/res/drawable-xxhdpi/light_progress_loading9.png -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/rx/BaseException.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.rx 2 | 3 | /* 4 | 定义通用异常 5 | */ 6 | class BaseException(val status:Int,val msg:String) :Throwable() 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/event/CartAllCheckedEvent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.event 2 | 3 | /* 4 | 购物车全选事件 5 | */ 6 | class CartAllCheckedEvent(val isAllChecked:Boolean) 7 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/CancelOrderReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 取消订单 5 | */ 6 | data class CancelOrderReq(val orderId:Int) 7 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/SubmitOrderReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 提交订单 5 | */ 6 | data class SubmitOrderReq(val order: Order) 7 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/c.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/22. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/ConfirmOrderReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 确认订单 5 | */ 6 | data class ConfirmOrderReq(val orderId:Int) 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/GetGoodsDetailReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 获取商品详情请求 5 | */ 6 | data class GetGoodsDetailReq(val goodsId: Int) 7 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/a.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/19. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/DeleteShipAddressReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 刪除收货地址 5 | */ 6 | data class DeleteShipAddressReq(val id: Int) 7 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/GetOrderByIdReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 根据ID查询订单 5 | */ 6 | data class GetOrderByIdReq(val orderId: Int) 7 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/ui/cc.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.ui 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/22. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/ui/a.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.ui 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/20. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/GetOrderListReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 根据订单状态查询查询订单列表 5 | */ 6 | data class GetOrderListReq(val orderStatus:Int) 7 | -------------------------------------------------------------------------------- /Provider/src/main/java/com/kotlin/provider/v.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.provider 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/19. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/protocol/ResetPwdReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.protocol 2 | 3 | /* 4 | 重围密码请求体 5 | */ 6 | data class ResetPwdReq(val mobile:String, val pwd:String) 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/a.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/20. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/data/protocol/GetPaySignReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.data.protocol 2 | 3 | /* 4 | 获取支付宝 支付签名 5 | */ 6 | data class GetPaySignReq(val orderId: Int, val totalPrice: Long) 7 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/protocol/ForgetPwdReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.protocol 2 | 3 | /* 4 | 忘记密码请求体 5 | */ 6 | data class ForgetPwdReq(val mobile:String, val verifyCode:String) 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/GetCategoryReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 获取分类列表请求,parentId为0是一级分类 5 | */ 6 | data class GetCategoryReq (val parentId: Int) 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/GetGoodsListReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 按分类搜索商品 5 | */ 6 | data class GetGoodsListReq(val categoryId: Int,val pageNo: Int) 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/event/GoodsDetailImageEvent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.event 2 | 3 | /* 4 | 商品详情Tab two 事件 5 | */ 6 | class GoodsDetailImageEvent(val imgOne:String,val imgTwo:String) 7 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/protocol/LoginReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.protocol 2 | 3 | /* 4 | 登录请求体 5 | */ 6 | data class LoginReq(val mobile:String, val pwd:String, val pushId:String) 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/DeleteCartReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 删除购物车商品请求 5 | */ 6 | data class DeleteCartReq(val cartIdList: List = arrayListOf()) 7 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/protocol/RegisterReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.protocol 2 | 3 | /* 4 | 注册请求体 5 | */ 6 | data class RegisterReq(val mobile:String,val pwd:String,val verifyCode:String) 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/SubmitCartReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 提交购物车 5 | */ 6 | data class SubmitCartReq(val goodsList: List,val totalPrice: Long) 7 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/caches/build_file_checksums.ser 5 | /.idea/libraries 6 | /.idea/modules.xml 7 | /.idea/workspace.xml 8 | .DS_Store 9 | /build 10 | /captures 11 | .externalNativeBuild 12 | -------------------------------------------------------------------------------- /MessageCenter/src/main/java/com/kotlin/message/a.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.message 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/19. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ 10 | class a { 11 | } -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/event/SelectAddressEvent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.event 2 | 3 | import com.kotlin.order.data.protocol.ShipAddress 4 | 5 | /* 6 | 选择收货人信息事件 7 | */ 8 | class SelectAddressEvent(val address:ShipAddress) 9 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/protocol/EditUserReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.protocol 2 | 3 | /* 4 | 修改用户资料请求体 5 | */ 6 | data class EditUserReq(val userIcon: String, val userName: String, val gender: String, val sign: String) 7 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/test.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.user; 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/15. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ 10 | public class test { 11 | } 12 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/ui/a.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.ui; 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/15. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ 10 | public class a { 11 | } 12 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /App/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #008577 4 | #00574B 5 | #D81B60 6 | 7 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/ui/fragment/BaseFragment.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.ui.fragment 2 | 3 | import com.trello.rxlifecycle.components.support.RxFragment 4 | 5 | /* 6 | Fragment基类,业务无关 7 | */ 8 | open class BaseFragment : RxFragment() 9 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/AddShipAddressReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 添加收货地址 5 | */ 6 | data class AddShipAddressReq(val shipUserName: String, val shipUserMobile: String, val shipAddress: String) 7 | -------------------------------------------------------------------------------- /MessageCenter/src/main/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 45dp 4 | 45dip 5 | 45dip 6 | 7 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/presenter/view/BaseView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.presenter.view 2 | 3 | /* 4 | MVP中视图回调 基类 5 | */ 6 | interface BaseView { 7 | fun showLoading() 8 | fun hideLoading() 9 | fun onError(text:String) 10 | } 11 | -------------------------------------------------------------------------------- /MessageCenter/src/main/res/anim/news_bottom_out.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/service/UploadService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.service 2 | 3 | import rx.Observable 4 | 5 | /* 6 | 上传业务接口 7 | */ 8 | interface UploadService { 9 | 10 | fun getUploadToken(): Observable 11 | 12 | } 13 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/GetGoodsListByKeywordReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 按关键字搜索商品 5 | */ 6 | data class GetGoodsListByKeywordReq( 7 | val keyword: String, 8 | val pageNo: Int 9 | ) 10 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/btn_common_nor.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /MessageCenter/src/main/res/anim/news_bottom_in.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/btn_common_disable.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/EditShipAddressReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 修改收货地址 5 | */ 6 | data class EditShipAddressReq(val id:Int,val shipUserName:String,val shipUserMobile:String,val shipAddress:String,val shipIsDefault:Int) 7 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/btn_common_pressed.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/anim/push_bottom_in.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/anim/push_bottom_out.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/presenter/view/RegisterView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | 5 | /* 6 | 用户注册 视图回调 7 | */ 8 | interface RegisterView:BaseView{ 9 | 10 | fun onRegisterResult(result:String) 11 | } 12 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/GoodsSku.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 商品SKU数据类 5 | */ 6 | data class GoodsSku( 7 | val id: Int, 8 | val skuTitle: String,//SKU标题 9 | val skuContent: List//SKU内容 10 | ) 11 | 12 | 13 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/border_all.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /App/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /App/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /App/src/main/java/com/kotlin/mall/common/MainApplication.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.mall.common 2 | 3 | import com.kotlin.base.common.BaseApplication 4 | 5 | /* 6 | 主工程 Application 7 | */ 8 | class MainApplication:BaseApplication() { 9 | override fun onCreate() { 10 | super.onCreate() 11 | 12 | } 13 | } 14 | 15 | 16 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/common/ResultCode.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.common 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/15. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description:网络响应码 9 | */ 10 | class ResultCode { 11 | companion object { 12 | const val SUCCESS = 0 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/injection/ActivityScope.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.injection 2 | 3 | import java.lang.annotation.Retention 4 | import java.lang.annotation.RetentionPolicy 5 | import javax.inject.Scope 6 | 7 | /* 8 | Activity级别 作用域 9 | */ 10 | @Scope 11 | @Retention(RetentionPolicy.RUNTIME) 12 | annotation class ActivityScope 13 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/Ext.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods 2 | 3 | import android.widget.EditText 4 | import org.jetbrains.anko.find 5 | import ren.qinc.numberbutton.NumberButton 6 | import ren.qinc.numberbutton.R 7 | 8 | /* 9 | 三方控件扩展 10 | */ 11 | fun NumberButton.getEditText():EditText{ 12 | return find(R.id.text_count) 13 | } 14 | -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable/gender_bg_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/injection/PerComponentScope.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.injection 2 | 3 | import java.lang.annotation.Retention 4 | import java.lang.annotation.RetentionPolicy 5 | import javax.inject.Scope 6 | 7 | /* 8 | 组件级别 作用域 9 | */ 10 | @Scope 11 | @Retention(RetentionPolicy.RUNTIME) 12 | annotation class PerComponentScope 13 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/presenter/view/OrderDetailView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.order.data.protocol.Order 5 | 6 | /* 7 | 订单详情页 视图回调 8 | */ 9 | interface OrderDetailView : BaseView { 10 | 11 | fun onGetOrderByIdResult(result: Order) 12 | } 13 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/presenter/view/PayView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | 5 | /* 6 | 支付 视图回调 7 | */ 8 | interface PayView : BaseView { 9 | 10 | //获取支付签名 11 | fun onGetSignResult(result: String) 12 | //同步支付成功状态 13 | fun onPayOrderResult(result: Boolean) 14 | 15 | } 16 | -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable/gender_nor_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable/gender_checked_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/border_corner_all.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/border_corner_all_blue.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/service/CategoryService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.service 2 | 3 | import com.kotlin.goods.data.protocol.Category 4 | import rx.Observable 5 | 6 | /* 7 | 商品分类 业务层 接口 8 | */ 9 | interface CategoryService { 10 | 11 | /* 12 | 获取分类 13 | */ 14 | fun getCategory(parentId:Int): Observable?> 15 | } 16 | -------------------------------------------------------------------------------- /UserCenter/src/main/res/drawable/gender_text_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/Category.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 商品分类 5 | */ 6 | data class Category( 7 | val id: Int, //分类ID 8 | val categoryName: String, //分类名称 9 | val categoryIcon: String = "", //分类图标 10 | val parentId: Int, //分类 父级ID 11 | var isSelected: Boolean = false//是否被选中 12 | ) 13 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/presenter/view/GoodsListView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.goods.data.protocol.Goods 5 | 6 | /* 7 | 商品列表 视图回调 8 | */ 9 | interface GoodsListView : BaseView { 10 | 11 | //获取商品列表 12 | fun onGetGoodsListResult(result: MutableList?) 13 | } 14 | -------------------------------------------------------------------------------- /MessageCenter/src/main/res/drawable/corner_news_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/bottom_nav_text_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/presenter/view/CategoryView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.goods.data.protocol.Category 5 | 6 | /* 7 | 商品分类 视图回调 8 | */ 9 | interface CategoryView : BaseView { 10 | 11 | //获取商品分类列表 12 | fun onGetCategoryResult(result: MutableList?) 13 | } 14 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/Order.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 订单数据类 5 | */ 6 | data class Order( 7 | val id: Int, 8 | val payType: Int, 9 | var shipAddress: ShipAddress?, 10 | val totalPrice: Long, 11 | var orderStatus: Int, 12 | val orderGoodsList: MutableList 13 | ) 14 | 15 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/data/protocol/BaseResp.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.data.protocol 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/15. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | * 能用响应对象 10 | @status:响应状态码 11 | @message:响应文字消息 12 | @data:具体响应业务对象 13 | */ 14 | data class BaseResp(val status:Int, val message:String, val data:T) -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/presenter/view/ResetPwdView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | 5 | /** 6 | * @author 桂雁彬 7 | * @date 2019/3/18. 8 | * GitHub: 9 | * email:yanbing.gui@zymobi.com 10 | * description: 11 | */ 12 | interface ResetPwdView : BaseView { 13 | 14 | fun onResetPwdResult(result:String) 15 | } 16 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable/sku_text_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/corner_blue_white_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/corner_gray_white_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable/top_category_bg_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/service/PayService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.service 2 | 3 | import rx.Observable 4 | 5 | /* 6 | 支付 业务接口 7 | */ 8 | interface PayService { 9 | 10 | /* 11 | 获取支付宝支付签名 12 | */ 13 | fun getPaySign(orderId: Int, totalPrice: Long): Observable 14 | 15 | /* 16 | 刷新订单状态已支付 17 | */ 18 | fun payOrder(orderId: Int): Observable 19 | } 20 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/tab_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/home_header_corner_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/progress_dialog_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 11 | 12 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/btn_common_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/AddCartReq.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 添加商品到购物车请求 5 | */ 6 | data class AddCartReq( 7 | val goodsId: Int, //商品ID 8 | val goodsDesc: String, //商品描述 9 | val goodsIcon: String, //商品图标 10 | val goodsPrice: Long, //商品价格 11 | val goodsCount: Int, //商品数量 12 | val goodsSku: String //商品SKU 13 | ) 14 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable/top_category_text_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/common/OrderStatus.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.common 2 | 3 | /* 4 | 订单状态 5 | */ 6 | class OrderStatus { 7 | companion object { 8 | const val ORDER_ALL = 0//全部 9 | const val ORDER_WAIT_PAY = 1//待支付 10 | const val ORDER_WAIT_CONFIRM = 2//待收货 11 | const val ORDER_COMPLETED = 3//已完成 12 | const val ORDER_CANCELED = 4//已取消 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/drawable/sku_bg_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/presenter/view/LoginView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.user.data.protocol.UserInfo 5 | 6 | /** 7 | * @author 桂雁彬 8 | * @date 2019/3/18. 9 | * GitHub: 10 | * email:yanbing.gui@zymobi.com 11 | * description: 12 | */ 13 | interface LoginView :BaseView { 14 | fun onLoginResult(result: UserInfo) 15 | } -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/presenter/view/GoodsDetailView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.goods.data.protocol.Goods 5 | 6 | /* 7 | 商品详情 视图回调 8 | */ 9 | interface GoodsDetailView : BaseView { 10 | 11 | //获取商品详情 12 | fun onGetGoodsDetailResult(result: Goods) 13 | //加入购物车 14 | fun onAddCartResult(result: Int) 15 | } 16 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/OrderGoods.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | /* 4 | 订单中的商品 5 | */ 6 | data class OrderGoods( 7 | val id: Int, 8 | var goodsId: Int, 9 | val goodsDesc: String, 10 | val goodsIcon: String, 11 | val goodsPrice: Long, 12 | val goodsCount: Int, 13 | val goodsSku: String, 14 | val orderId: Int 15 | ) 16 | 17 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/data/protocol/ShipAddress.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.data.protocol 2 | 3 | import android.os.Parcelable 4 | import java.io.Serializable 5 | 6 | /* 7 | 收货地址 8 | */ 9 | data class ShipAddress( 10 | val id: Int, 11 | var shipUserName: String, 12 | var shipUserMobile: String, 13 | var shipAddress: String, 14 | var shipIsDefault: Int 15 | ) : Serializable 16 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/presenter/view/OrderConfirmView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.order.data.protocol.Order 5 | 6 | /* 7 | 订单确认页 视图回调 8 | */ 9 | interface OrderConfirmView : BaseView { 10 | 11 | //获取订单回调 12 | fun onGetOrderByIdResult(result:Order) 13 | //提交订单回调 14 | fun onSubmitOrderResult(result:Boolean) 15 | } 16 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/presenter/view/ForgetPwdView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | 5 | /** 6 | * @author 桂雁彬 7 | * @date 2019/3/18. 8 | * GitHub: 9 | * email:yanbing.gui@zymobi.com 10 | * description: 11 | */ 12 | interface ForgetPwdView : BaseView { 13 | 14 | /* 15 | 忘记密码回调 16 | */ 17 | fun onForgetPwdResult(result:String) 18 | } 19 | -------------------------------------------------------------------------------- /App/src/test/java/com/kotlin/mall/ExampleUnitTest.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.mall 2 | 3 | import org.junit.Test 4 | 5 | import org.junit.Assert.* 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * See [testing documentation](http://d.android.com/tools/testing). 11 | */ 12 | class ExampleUnitTest { 13 | @Test 14 | fun addition_isCorrect() { 15 | assertEquals(4, 2 + 2) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/presenter/view/EditShipAddressView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.order.data.protocol.Order 5 | 6 | /* 7 | 编辑收货人信息 视图回调 8 | */ 9 | interface EditShipAddressView : BaseView { 10 | //添加收货人回调 11 | fun onAddShipAddressResult(result: Boolean) 12 | //修改收货人回调 13 | fun onEditShipAddressResult(result: Boolean) 14 | } 15 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/injection/component/AppComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.injection.component 2 | 3 | import android.content.Context 4 | import com.kotlin.base.injection.module.AppModule 5 | import dagger.Component 6 | import javax.inject.Singleton 7 | 8 | /* 9 | Application级别Component 10 | */ 11 | @Singleton 12 | @Component(modules = arrayOf(AppModule::class)) 13 | interface AppComponent { 14 | 15 | fun context():Context 16 | } 17 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/injection/module/PayModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.injection.module 2 | 3 | import com.kotlin.pay.service.PayService 4 | import com.kotlin.pay.service.impl.PayServiceImpl 5 | import dagger.Module 6 | import dagger.Provides 7 | 8 | /* 9 | 支付 Module 10 | */ 11 | @Module 12 | class PayModule { 13 | 14 | @Provides 15 | fun providePayService(payService: PayServiceImpl): PayService { 16 | return payService 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /PaySDK/src/test/java/com/kotlin/pay/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /UserCenter/src/test/java/com/kotlin/user/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.user; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /BaseLibrary/src/test/java/com/kotlin/base/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.base; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /GoodsCenter/src/test/java/com/kotlin/goods/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /OrderCenter/src/test/java/com/kotlin/order/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.order; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/presenter/view/UserInfoView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.user.data.protocol.UserInfo 5 | 6 | /* 7 | 编辑用户资料 视图回调 8 | */ 9 | interface UserInfoView : BaseView { 10 | 11 | /* 12 | 获取上传凭证回调 13 | */ 14 | fun onGetUploadTokenResult(result:String) 15 | 16 | /* 17 | 编辑用户资料回调 18 | */ 19 | fun onEditUserResult(result:UserInfo) 20 | } 21 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/common_check_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/CartGoods.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 购物车商品数据类 5 | */ 6 | data class CartGoods( 7 | val id: Int,//购物车单项商品ID 8 | val goodsId:Int,//具体商品ID 9 | val goodsDesc: String,//商品描述 10 | val goodsIcon: String,//商品图片 11 | val goodsPrice: Long,//商品价格 12 | var goodsCount: Int,//商品数量 13 | val goodsSku:String,//商品SKU 14 | var isSelected:Boolean//是否选中 15 | ) 16 | 17 | -------------------------------------------------------------------------------- /MessageCenter/src/test/java/com/kotlin/message/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.message; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /Provider/src/test/java/com/kotlin/provider/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.provider; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/protocol/UserInfo.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.protocol 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/18. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description:用户实体类 9 | */ 10 | data class UserInfo(val id:String, 11 | val userIcon:String, 12 | val userName:String, 13 | val userGender:String, 14 | val userMobile:String, 15 | val userSign:String) -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/injection/module/GoodsModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.injection.module 2 | 3 | import com.kotlin.goods.service.GoodsService 4 | import com.kotlin.goods.service.impl.GoodsServiceImpl 5 | import dagger.Module 6 | import dagger.Provides 7 | 8 | /* 9 | 商品Module 10 | */ 11 | @Module 12 | class GoodsModule { 13 | 14 | @Provides 15 | fun provideGoodservice(goodsService: GoodsServiceImpl): GoodsService { 16 | return goodsService 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/injection/module/OrderModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.injection.module 2 | 3 | import com.kotlin.order.service.OrderService 4 | import com.kotlin.order.service.impl.OrderServiceImpl 5 | import dagger.Module 6 | import dagger.Provides 7 | 8 | /* 9 | 订单Module 10 | */ 11 | @Module 12 | class OrderModule { 13 | 14 | @Provides 15 | fun provideOrderservice(orderService: OrderServiceImpl): OrderService { 16 | return orderService 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/api/UploadApi.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.api 2 | 3 | import com.kotlin.base.data.protocol.BaseResp 4 | import com.kotlin.user.data.protocol.* 5 | import retrofit2.http.Body 6 | import retrofit2.http.POST 7 | import rx.Observable 8 | 9 | /* 10 | 上传相关 接口 11 | */ 12 | interface UploadApi { 13 | 14 | /* 15 | 获取七牛云上传凭证 16 | */ 17 | @POST("Kotlin_war/common/getUploadToken") 18 | fun getUploadToken(): Observable> 19 | } 20 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/injection/module/LifecycleProviderModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.injection.module 2 | 3 | import com.trello.rxlifecycle.LifecycleProvider 4 | import dagger.Module 5 | import dagger.Provides 6 | 7 | /* 8 | Rx生命周期管理能用Module 9 | */ 10 | @Module 11 | class LifecycleProviderModule(private val lifecycleProvider: LifecycleProvider<*>) { 12 | 13 | @Provides 14 | fun provideLifecycleProvider(): LifecycleProvider<*> { 15 | return this.lifecycleProvider 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/presenter/view/OrderListView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.order.data.protocol.Order 5 | 6 | /* 7 | 订单列表 视图回调 8 | */ 9 | interface OrderListView : BaseView { 10 | 11 | //获取订单列表回调 12 | fun onGetOrderListResult(result:MutableList?) 13 | //确认订单回调 14 | fun onConfirmOrderResult(result:Boolean) 15 | //取消订单回调 16 | fun onCancelOrderResult(result:Boolean) 17 | 18 | } 19 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/injection/module/UserModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.injection.module 2 | 3 | import com.kotlin.user.service.UserService 4 | import com.kotlin.user.service.impl.UserServiceImpl 5 | import dagger.Module 6 | import dagger.Provides 7 | import javax.inject.Named 8 | 9 | /* 10 | 用户模块Module 11 | */ 12 | @Module 13 | class UserModule { 14 | 15 | @Provides 16 | fun provideUserService(userService: UserServiceImpl): UserService { 17 | return userService 18 | } 19 | 20 | } 21 | 22 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/injection/module/AppModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.injection.module 2 | 3 | import android.content.Context 4 | import com.kotlin.base.common.BaseApplication 5 | import dagger.Module 6 | import dagger.Provides 7 | import javax.inject.Singleton 8 | 9 | /* 10 | Application级别Module 11 | */ 12 | @Module 13 | class AppModule(private val context:BaseApplication) { 14 | 15 | @Singleton 16 | @Provides 17 | fun provideContext():Context{ 18 | return this.context 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/border_top.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/injection/module/CategoryModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.injection.module 2 | 3 | import com.kotlin.goods.service.CategoryService 4 | import com.kotlin.goods.service.impl.CategoryServiceImpl 5 | import dagger.Module 6 | import dagger.Provides 7 | 8 | /* 9 | 商品分类Module 10 | */ 11 | @Module 12 | class CategoryModule { 13 | 14 | @Provides 15 | fun provideCategoryService(categoryService: CategoryServiceImpl): CategoryService { 16 | return categoryService 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/border_bottom.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/border_bottom_gray.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/presenter/view/ShipAddressView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.order.data.protocol.ShipAddress 5 | 6 | /* 7 | 收货人列表 视图回调 8 | */ 9 | interface ShipAddressView : BaseView { 10 | 11 | //获取收货人列表回调 12 | fun onGetShipAddressResult(result: MutableList?) 13 | //设置默认收货人回调 14 | fun onSetDefaultResult(result: Boolean) 15 | //删除收货人回调 16 | fun onDeleteResult(result: Boolean) 17 | 18 | } 19 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/widgets/DefaultTextWatcher.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.widgets 2 | 3 | import android.text.Editable 4 | import android.text.TextWatcher 5 | 6 | /* 7 | 默认TextWatcher,空实现 8 | */ 9 | open class DefaultTextWatcher:TextWatcher{ 10 | override fun afterTextChanged(s: Editable?) { 11 | } 12 | 13 | override fun beforeTextChanged(s: CharSequence?, start: Int, count: Int, after: Int) { 14 | } 15 | 16 | override fun onTextChanged(s: CharSequence?, start: Int, before: Int, count: Int) { 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/injection/module/ShipAddressModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.injection.module 2 | 3 | import com.kotlin.order.service.ShipAddressService 4 | import com.kotlin.order.service.impl.ShipAddressServiceImpl 5 | import dagger.Module 6 | import dagger.Provides 7 | 8 | /* 9 | 收货人信息Module 10 | */ 11 | @Module 12 | class ShipAddressModule { 13 | 14 | @Provides 15 | fun provideShipAddressservice(shipAddressService: ShipAddressServiceImpl): ShipAddressService { 16 | return shipAddressService 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/presenter/view/CartListView.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.presenter.view 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import com.kotlin.goods.data.protocol.CartGoods 5 | import com.kotlin.goods.data.protocol.Category 6 | 7 | /* 8 | 购物车页面 视图回调 9 | */ 10 | interface CartListView : BaseView { 11 | 12 | //获取购物车列表 13 | fun onGetCartListResult(result: MutableList?) 14 | //删除购物车 15 | fun onDeleteCartListResult(result: Boolean) 16 | //提交购物车 17 | fun onSubmitCartListResult(result: Int) 18 | } 19 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/layout/activity_cart.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/rx/BaseFunc.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.rx 2 | 3 | import com.kotlin.base.common.ResultCode 4 | import com.kotlin.base.data.protocol.BaseResp 5 | import rx.Observable 6 | import rx.functions.Func1 7 | 8 | /* 9 | 通用数据类型转换封装 10 | */ 11 | class BaseFunc:Func1,Observable>{ 12 | override fun call(t: BaseResp): Observable { 13 | if (t.status != ResultCode.SUCCESS){ 14 | return Observable.error(BaseException(t.status,t.message)) 15 | } 16 | 17 | return Observable.just(t.data) 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/values/attrs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/layout/layout_top_category_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/layout/layout_state_empty.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 13 | 14 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/api/CategoryApi.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.api 2 | 3 | import com.kotlin.base.data.protocol.BaseResp 4 | import com.kotlin.goods.data.protocol.Category 5 | import com.kotlin.goods.data.protocol.GetCategoryReq 6 | import retrofit2.http.Body 7 | import retrofit2.http.POST 8 | import rx.Observable 9 | 10 | /* 11 | 商品分类接口 12 | */ 13 | interface CategoryApi { 14 | /* 15 | 获取商品分类列表 16 | */ 17 | @POST("Kotlin_war/category/getCategory") 18 | fun getCategory(@Body req: GetCategoryReq): Observable?>> 19 | } 20 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/injection/module/CartModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.injection.module 2 | 3 | import com.kotlin.goods.service.CartService 4 | import com.kotlin.goods.service.GoodsService 5 | import com.kotlin.goods.service.impl.CartServiceImpl 6 | import com.kotlin.goods.service.impl.GoodsServiceImpl 7 | import dagger.Module 8 | import dagger.Provides 9 | 10 | /* 11 | 购物车Module 12 | */ 13 | @Module 14 | class CartModule { 15 | 16 | @Provides 17 | fun provideCartservice(cartService: CartServiceImpl): CartService { 18 | return cartService 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/rx/BaseSubscriber.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.rx 2 | 3 | import com.kotlin.base.presenter.view.BaseView 4 | import rx.Subscriber 5 | 6 | /* 7 | Rx订阅者默认实现 8 | */ 9 | open class BaseSubscriber(val baseView:BaseView):Subscriber() { 10 | 11 | override fun onCompleted() { 12 | baseView.hideLoading() 13 | } 14 | 15 | override fun onNext(t: T) { 16 | } 17 | 18 | override fun onError(e: Throwable?) { 19 | baseView.hideLoading() 20 | if (e is BaseException){ 21 | baseView.onError(e.msg) 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/injection/module/UploadModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.injection.module 2 | 3 | import com.kotlin.user.service.UploadService 4 | import com.kotlin.user.service.UserService 5 | import com.kotlin.user.service.impl.UploadServiceImpl 6 | import com.kotlin.user.service.impl.UserServiceImpl 7 | import dagger.Module 8 | import dagger.Provides 9 | 10 | /* 11 | 上传Module 12 | */ 13 | @Module 14 | class UploadModule { 15 | 16 | @Provides 17 | fun provideUploadService(uploadService: UploadServiceImpl): UploadService { 18 | return uploadService 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/layout/progress_dialog.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /OrderCenter/src/main/res/layout/fragment_order.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 8 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/rx/BaseFuncBoolean.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.rx 2 | 3 | import com.kotlin.base.common.ResultCode 4 | import com.kotlin.base.data.protocol.BaseResp 5 | import rx.Observable 6 | import rx.functions.Func1 7 | 8 | /* 9 | Boolean类型转换封装 10 | */ 11 | class BaseFuncBoolean: Func1, Observable> { 12 | override fun call(t: BaseResp): Observable { 13 | if (t.status != ResultCode.SUCCESS){ 14 | return Observable.error(BaseException(t.status, t.message)) 15 | } 16 | 17 | return Observable.just(true) 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/widgets/BannerImageLoader.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.widgets 2 | 3 | import android.content.Context 4 | import android.widget.ImageView 5 | import com.kotlin.base.utils.GlideUtils 6 | import com.youth.banner.loader.ImageLoader 7 | 8 | /** 9 | * @author 桂雁彬 10 | * @date 2019/3/19. 11 | * GitHub: 12 | * email:yanbing.gui@zymobi.com 13 | * description: 14 | */ 15 | class BannerImageLoader : ImageLoader() { 16 | override fun displayImage(context: Context, path: Any, imageView: ImageView) { 17 | GlideUtils.loadUrlImage(context, path.toString(), imageView) 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/injection/component/PayComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.injection.component 2 | 3 | import com.kotlin.base.injection.PerComponentScope 4 | import com.kotlin.base.injection.component.ActivityComponent 5 | import com.kotlin.pay.injection.module.PayModule 6 | import com.kotlin.pay.ui.activity.CashRegisterActivity 7 | import dagger.Component 8 | 9 | /* 10 | 支付Component 11 | */ 12 | @PerComponentScope 13 | @Component(dependencies = arrayOf(ActivityComponent::class),modules = arrayOf(PayModule::class)) 14 | interface PayComponent { 15 | fun inject(activity: CashRegisterActivity) 16 | } 17 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/injection/module/ActivityModule.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.injection.module 2 | 3 | import android.app.Activity 4 | import android.content.Context 5 | import com.kotlin.base.common.BaseApplication 6 | import com.kotlin.base.injection.ActivityScope 7 | import dagger.Module 8 | import dagger.Provides 9 | import javax.inject.Singleton 10 | 11 | /* 12 | Activity级别Module 13 | */ 14 | @Module 15 | class ActivityModule(private val activity: Activity) { 16 | 17 | @ActivityScope 18 | @Provides 19 | fun provideActivity(): Activity { 20 | return this.activity 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/service/impl/UploadServiceImpl.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.service.impl 2 | 3 | import com.kotlin.base.ext.convert 4 | import com.kotlin.user.data.respository.UploadRepository 5 | import com.kotlin.user.service.UploadService 6 | import rx.Observable 7 | import javax.inject.Inject 8 | 9 | /* 10 | 上传业务实现类 11 | */ 12 | class UploadServiceImpl @Inject constructor(): UploadService { 13 | 14 | @Inject 15 | lateinit var repository: UploadRepository 16 | 17 | override fun getUploadToken(): Observable { 18 | return repository.getUploadToken().convert() 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/layout/layout_state_error.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 9 | 14 | 15 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/service/GoodsService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.service 2 | 3 | import com.kotlin.goods.data.protocol.Goods 4 | import rx.Observable 5 | 6 | /* 7 | 商品 业务层 接口 8 | */ 9 | interface GoodsService { 10 | 11 | /* 12 | 获取商品列表 13 | */ 14 | fun getGoodsList(categoryId: Int, pageNo: Int): Observable?> 15 | 16 | /* 17 | 根据关键字查询商品 18 | */ 19 | fun getGoodsListByKeyword(keyword: String, pageNo: Int): Observable?> 20 | 21 | /* 22 | 获取商品详情 23 | */ 24 | fun getGoodsDetail(goodsId: Int): Observable 25 | } 26 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/common/BaseConstant.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.common 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/15. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description:基础常量 9 | */ 10 | class BaseConstant{ 11 | companion object { 12 | //七牛服务地址 13 | const val IMAGE_SERVER_ADDRESS = "http://osea2fxp7.bkt.clouddn.com/" 14 | //本地服务器地址 15 | const val SERVER_ADDRESS = "http://192.168.1.150:8080" 16 | 17 | 18 | 19 | //SP表名 20 | const val TABLE_PREFS = "Kotlin_mall" 21 | //Token Key 22 | const val KEY_SP_TOKEN = "token" 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/injection/component/CategoryComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.injection.component 2 | 3 | import com.kotlin.base.injection.PerComponentScope 4 | import com.kotlin.base.injection.component.ActivityComponent 5 | import com.kotlin.goods.injection.module.CategoryModule 6 | import com.kotlin.goods.ui.fragment.CategoryFragment 7 | import dagger.Component 8 | 9 | /* 10 | 商品分类Component 11 | */ 12 | @PerComponentScope 13 | @Component(dependencies = arrayOf(ActivityComponent::class),modules = arrayOf(CategoryModule::class)) 14 | interface CategoryComponent { 15 | fun inject(fragment: CategoryFragment) 16 | } 17 | -------------------------------------------------------------------------------- /App/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 12 | 13 | 14 | 19 | 20 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 7 | 8 | 9 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /OrderCenter/src/main/res/layout/activity_order.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 11 | 14 | 15 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/ui/activity/CartActivity.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.ui.activity 2 | 3 | import android.os.Bundle 4 | import com.kotlin.base.ui.activity.BaseActivity 5 | import com.kotlin.goods.R 6 | import com.kotlin.goods.ui.fragment.CartFragment 7 | 8 | /* 9 | 购物车Activity 10 | 只是Fragment一个壳 11 | */ 12 | class CartActivity:BaseActivity() { 13 | override fun onCreate(savedInstanceState: Bundle?) { 14 | super.onCreate(savedInstanceState) 15 | setContentView(R.layout.activity_cart) 16 | 17 | val fragment = supportFragmentManager.findFragmentById(R.id.fragment_cart) 18 | (fragment as CartFragment).setBackVisible(true) 19 | 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /OrderCenter/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 5 | 6 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/collect_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/bottom_nav_cart_selector.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/data/respository/UploadRepository.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.data.respository 2 | 3 | import com.kotlin.base.data.net.RetrofitFactory 4 | import com.kotlin.base.data.protocol.BaseResp 5 | import com.kotlin.user.data.api.UploadApi 6 | import com.kotlin.user.data.api.UserApi 7 | import com.kotlin.user.data.protocol.* 8 | import rx.Observable 9 | import javax.inject.Inject 10 | 11 | /* 12 | 上传相关 数据层 13 | */ 14 | class UploadRepository @Inject constructor(){ 15 | /* 16 | 获取七牛云上传凭证 17 | */ 18 | fun getUploadToken(): Observable> { 19 | return RetrofitFactory.instance.create(UploadApi::class.java).getUploadToken() 20 | } 21 | 22 | 23 | } 24 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/data/api/PayApi.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.data.api 2 | 3 | import com.kotlin.base.data.protocol.BaseResp 4 | import com.kotlin.pay.data.protocol.GetPaySignReq 5 | import com.kotlin.pay.data.protocol.PayOrderReq 6 | import retrofit2.http.Body 7 | import retrofit2.http.POST 8 | import rx.Observable 9 | 10 | 11 | /* 12 | 支付 接口 13 | */ 14 | interface PayApi { 15 | 16 | /* 17 | 获取支付宝支付签名 18 | */ 19 | @POST("Kotlin_war/pay/getPaySign") 20 | fun getPaySign(@Body req: GetPaySignReq): Observable> 21 | 22 | /* 23 | 刷新订单状态,已支付 24 | */ 25 | @POST("Kotlin_war/order/pay") 26 | fun payOrder(@Body req: PayOrderReq): Observable> 27 | 28 | } 29 | -------------------------------------------------------------------------------- /Provider/src/main/java/com/kotlin/provider/common/ProviderConstant.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.provider.common 2 | 3 | /* 4 | 业务常量 5 | */ 6 | class ProviderConstant { 7 | companion object { 8 | //用户名称 9 | const val KEY_SP_USER_NAME = "sp_user_name" 10 | //用户电话 11 | const val KEY_SP_USER_MOBILE = "sp_user_mobile" 12 | //用户头像 13 | const val KEY_SP_USER_ICON = "sp_user_icon" 14 | //用户性别 15 | const val KEY_SP_USER_GENDER = "sp_user_gender" 16 | //用户签名 17 | const val KEY_SP_USER_SIGN = "sp_user_sign" 18 | 19 | //订单ID 20 | const val KEY_ORDER_ID = "order_id" 21 | //订单价格 22 | const val KEY_ORDER_PRICE = "order_price" 23 | } 24 | 25 | 26 | } 27 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/service/ShipAddressService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.service 2 | 3 | import com.kotlin.order.data.protocol.ShipAddress 4 | import rx.Observable 5 | 6 | /* 7 | 收货人信息 业务接口 8 | */ 9 | interface ShipAddressService { 10 | 11 | /* 12 | 添加收货地址 13 | */ 14 | fun addShipAddress(shipUserName: String, shipUserMobile: String, shipAddress: String): Observable 15 | 16 | /* 17 | 获取收货地址列表 18 | */ 19 | fun getShipAddressList(): Observable?> 20 | 21 | /* 22 | 修改收货地址 23 | */ 24 | fun editShipAddress(address:ShipAddress): Observable 25 | 26 | /* 27 | 删除收货地址 28 | */ 29 | fun deleteShipAddress(id: Int): Observable 30 | 31 | } 32 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | BaseLibrary 3 | 4 | 敬请期待~~~ 5 | 完成 6 | 确认 7 | 编辑 8 | 删除 9 | 下一步 10 | 保存 11 | 暂无数据~~~ 12 | 13 | 主页 14 | 分类 15 | 购物车 16 | 消息 17 | 我的 18 | 19 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/layout/layout_search_history_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 10 | 15 | 16 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/layout/layout_second_category_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 9 | 15 | 16 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/protocol/Goods.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.protocol 2 | 3 | /* 4 | 商品数据类 5 | */ 6 | data class Goods( 7 | val id: Int,//商品ID 8 | val categoryId: Int,//分类ID 9 | val goodsDesc: String,//商品描述 10 | val goodsDefaultIcon: String,//默认图标 11 | val goodsDefaultPrice: Long,//默认价格 12 | val goodsDetailOne: String,//商品详情一图 13 | val goodsDetailTwo: String,//商品详情二图 14 | val goodsSalesCount: Int,//商品销量 15 | val goodsStockCount: Int,//商品剩余量 16 | val goodsCode: String,//商品编号 17 | val goodsDefaultSku: String,//默认SKU 18 | val goodsBanner: String,//商品banner图 19 | val goodsSku:List,//商品SKU 20 | val maxPage:Int//最大页码 21 | ) 22 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/layout/fragment_goods_detail_tab_two.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 10 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/service/OrderService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.service 2 | 3 | import com.kotlin.order.data.protocol.Order 4 | import rx.Observable 5 | 6 | /* 7 | 订单业务 接口 8 | */ 9 | interface OrderService { 10 | 11 | /* 12 | 根据ID查询订单 13 | */ 14 | fun getOrderById(orderId: Int): Observable 15 | 16 | /* 17 | 提交订单 18 | */ 19 | fun submitOrder(order: Order): Observable 20 | 21 | /* 22 | 根据状态查询订单列表 23 | */ 24 | fun getOrderList(orderStatus: Int): Observable?> 25 | 26 | /* 27 | 取消订单 28 | */ 29 | fun cancelOrder(orderId: Int): Observable 30 | 31 | /* 32 | 确认订单 33 | */ 34 | fun confirmOrder(orderId: Int): Observable 35 | } 36 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/service/impl/CategoryServiceImpl.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.service.impl 2 | 3 | import com.kotlin.base.ext.convert 4 | import com.kotlin.goods.data.protocol.Category 5 | import com.kotlin.goods.data.repository.CategoryRepository 6 | import com.kotlin.goods.service.CategoryService 7 | import rx.Observable 8 | import javax.inject.Inject 9 | 10 | /* 11 | 商品分类 业务层 实现类 12 | */ 13 | class CategoryServiceImpl @Inject constructor(): CategoryService{ 14 | @Inject 15 | lateinit var repository: CategoryRepository 16 | 17 | /* 18 | 获取商品分类列表 19 | */ 20 | override fun getCategory(parentId: Int): Observable?> { 21 | return repository.getCategory(parentId).convert() 22 | } 23 | 24 | 25 | } 26 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/injection/component/ShipAddressComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.injection.component 2 | 3 | import com.kotlin.base.injection.PerComponentScope 4 | import com.kotlin.base.injection.component.ActivityComponent 5 | import com.kotlin.order.injection.module.ShipAddressModule 6 | import com.kotlin.order.ui.activity.ShipAddressActivity 7 | import com.kotlin.order.ui.activity.ShipAddressEditActivity 8 | import dagger.Component 9 | 10 | /* 11 | 收货人信息Component 12 | */ 13 | @PerComponentScope 14 | @Component(dependencies = arrayOf(ActivityComponent::class),modules = arrayOf(ShipAddressModule::class)) 15 | interface ShipAddressComponent { 16 | fun inject(activity: ShipAddressEditActivity) 17 | fun inject(activity: ShipAddressActivity) 18 | } 19 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/service/UserService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.service 2 | 3 | import com.kotlin.user.data.protocol.UserInfo 4 | import rx.Observable 5 | 6 | /* 7 | 用户模块 业务接口 8 | */ 9 | interface UserService { 10 | 11 | //用户注册 12 | fun register(mobile:String,pwd:String,verifyCode:String):Observable 13 | 14 | //用户登录 15 | fun login(mobile:String,pwd:String,pushId:String):Observable 16 | 17 | //忘记密码 18 | fun forgetPwd(mobile:String,verifyCode:String):Observable 19 | 20 | //重置密码 21 | fun resetPwd(mobile:String,pwd:String):Observable 22 | 23 | //编辑用户资料 24 | fun editUser(userIcon:String,userName:String,userGender:String,userSign:String):Observable 25 | } 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | 15 | -------------------------------------------------------------------------------- /App/src/androidTest/java/com/kotlin/mall/ExampleInstrumentedTest.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.mall 2 | 3 | import android.support.test.InstrumentationRegistry 4 | import android.support.test.runner.AndroidJUnit4 5 | 6 | import org.junit.Test 7 | import org.junit.runner.RunWith 8 | 9 | import org.junit.Assert.* 10 | 11 | /** 12 | * Instrumented test, which will execute on an Android device. 13 | * 14 | * See [testing documentation](http://d.android.com/tools/testing). 15 | */ 16 | @RunWith(AndroidJUnit4::class) 17 | class ExampleInstrumentedTest { 18 | @Test 19 | fun useAppContext() { 20 | // Context of the app under test. 21 | val appContext = InstrumentationRegistry.getTargetContext() 22 | assertEquals("com.kotlin.mall", appContext.packageName) 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/repository/CategoryRepository.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.repository 2 | 3 | import com.kotlin.base.data.net.RetrofitFactory 4 | import com.kotlin.base.data.protocol.BaseResp 5 | import com.kotlin.goods.data.api.CategoryApi 6 | import com.kotlin.goods.data.protocol.Category 7 | import com.kotlin.goods.data.protocol.GetCategoryReq 8 | import rx.Observable 9 | import javax.inject.Inject 10 | 11 | /* 12 | 商品分类 数据层 13 | */ 14 | class CategoryRepository @Inject constructor(){ 15 | /* 16 | 获取商品分类 17 | */ 18 | fun getCategory(parentId: Int): Observable?>> { 19 | return RetrofitFactory.instance.create(CategoryApi::class.java).getCategory(GetCategoryReq(parentId)) 20 | } 21 | 22 | } 23 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/common/OrderConstant.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.common 2 | 3 | /* 4 | 订单常量 5 | */ 6 | class OrderConstant { 7 | companion object { 8 | //订单状态 9 | const val KEY_ORDER_STATUS = "order_status" 10 | //收货地址 11 | const val KEY_SHIP_ADDRESS = "ship_address" 12 | //选择收货地址请求码 13 | const val REQ_SELECT_ADDRESS = 1001 14 | //是否选择收货地址 15 | const val KEY_IS_SELECT_ADDRESS = "is_select_address" 16 | //是否编辑地址 17 | const val KEY_ADDRESS_IS_EDIT = "address_is_edit" 18 | //支付订单操作 19 | const val OPT_ORDER_PAY = 1 20 | //确认订单操作 21 | const val OPT_ORDER_CONFIRM = 2 22 | //取消订单操作 23 | const val OPT_ORDER_CANCEL = 3 24 | } 25 | 26 | 27 | } 28 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/injection/component/CartComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.injection.component 2 | 3 | import com.kotlin.base.injection.PerComponentScope 4 | import com.kotlin.base.injection.component.ActivityComponent 5 | import com.kotlin.goods.injection.module.CartModule 6 | import com.kotlin.goods.injection.module.GoodsModule 7 | import com.kotlin.goods.ui.activity.GoodsActivity 8 | import com.kotlin.goods.ui.fragment.CartFragment 9 | import com.kotlin.goods.ui.fragment.GoodsDetailTabOneFragment 10 | import dagger.Component 11 | 12 | /* 13 | 购物车Component 14 | */ 15 | @PerComponentScope 16 | @Component(dependencies = arrayOf(ActivityComponent::class),modules = arrayOf(CartModule::class)) 17 | interface CartComponent { 18 | fun inject(fragment: CartFragment) 19 | } 20 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/layout/layout_label_textview.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 12 | 14 | 15 | -------------------------------------------------------------------------------- /PaySDK/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 14 | 15 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/service/CartService.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.service 2 | 3 | import com.kotlin.goods.data.protocol.CartGoods 4 | import rx.Observable 5 | 6 | /* 7 | 购物车 业务 接口 8 | */ 9 | interface CartService { 10 | /* 11 | 添加商品到购物车 12 | */ 13 | fun addCart(goodsId: Int, goodsDesc: String, goodsIcon: String, goodsPrice: Long, 14 | goodsCount: Int, goodsSku: String): Observable 15 | 16 | /* 17 | 获取购物车列表 18 | */ 19 | fun getCartList(): Observable?> 20 | 21 | /* 22 | 删除购物车商品 23 | */ 24 | fun deleteCartList(list: List): Observable 25 | 26 | /* 27 | 购物车结算 28 | */ 29 | fun submitCart(list: MutableList, totalPrice: Long): Observable 30 | } 31 | -------------------------------------------------------------------------------- /UserCenter/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/drawable/state_loading.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/layout/layout_sku_view.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 12 | 16 | 17 | -------------------------------------------------------------------------------- /App/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /PaySDK/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /BaseLibrary/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /GoodsCenter/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/res/layout/layout_sku_item.xml: -------------------------------------------------------------------------------- 1 | 2 | 15 | 16 | -------------------------------------------------------------------------------- /OrderCenter/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /Provider/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /UserCenter/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /MessageCenter/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /OrderCenter/src/main/java/com/kotlin/order/injection/component/OrderComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.order.injection.component 2 | 3 | import com.kotlin.base.injection.PerComponentScope 4 | import com.kotlin.base.injection.component.ActivityComponent 5 | import com.kotlin.order.injection.module.OrderModule 6 | import com.kotlin.order.ui.activity.OrderConfirmActivity 7 | import com.kotlin.order.ui.activity.OrderDetailActivity 8 | import com.kotlin.order.ui.fragment.OrderFragment 9 | import dagger.Component 10 | 11 | /* 12 | 订单Component 13 | */ 14 | @PerComponentScope 15 | @Component(dependencies = arrayOf(ActivityComponent::class),modules = arrayOf(OrderModule::class)) 16 | interface OrderComponent { 17 | fun inject(activity: OrderConfirmActivity) 18 | fun inject(fragment: OrderFragment) 19 | 20 | fun inject(activity: OrderDetailActivity) 21 | } 22 | -------------------------------------------------------------------------------- /Provider/src/main/java/com/kotlin/provider/common/CommonUtils.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.provider.common 2 | 3 | import com.alibaba.android.arouter.launcher.ARouter 4 | import com.kotlin.base.common.BaseConstant 5 | import com.kotlin.base.utils.AppPrefsUtils 6 | import com.kotlin.provider.router.RouterPath 7 | 8 | /** 9 | * @author 桂雁彬 10 | * @date 2019/3/19. 11 | * GitHub: 12 | * email:yanbing.gui@zymobi.com 13 | * description: 14 | */ 15 | 16 | /** 17 | * 判断是否登录 18 | */ 19 | fun isLogined():Boolean{ 20 | return AppPrefsUtils.getString(BaseConstant.KEY_SP_TOKEN).isNotEmpty() 21 | } 22 | /* 23 | 如果已经登录,进行传入的方法处理 24 | 如果没有登录,进入登录界面 25 | */ 26 | fun afterLogin(method:()->Unit){ 27 | if (isLogined()){ 28 | method() 29 | }else{ 30 | ARouter.getInstance().build(RouterPath.UserCenter.PATH_LOGIN).navigation() 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/common/GoodsConstant.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.common 2 | 3 | /* 4 | 商品模块 常量 5 | */ 6 | class GoodsConstant { 7 | companion object { 8 | //搜索历史 本地存储 9 | const val SP_SEARCH_HISTORY = "search_history" 10 | //搜索商品类型 11 | const val KEY_SEARCH_GOODS_TYPE = "search_goods_type" 12 | //按分类搜索 13 | const val SEARCH_GOODS_TYPE_CATEGORY = 0 14 | //按关键字搜索 15 | const val SEARCH_GOODS_TYPE_KEYWORD = 1 16 | //商品分类ID 17 | const val KEY_CATEGORY_ID = "category_id" 18 | //商品关键字 19 | const val KEY_GOODS_KEYWORD = "goods_keyword" 20 | //商品ID 21 | const val KEY_GOODS_ID = "goods_id" 22 | //sku分隔标识 23 | const val SKU_SEPARATOR = "," 24 | //购物车数量 25 | const val SP_CART_SIZE = "cart_size" 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/presenter/BasePresenter.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.presenter 2 | 3 | import android.content.Context 4 | import com.kotlin.base.presenter.view.BaseView 5 | import com.kotlin.base.utils.NetWorkUtils 6 | import com.trello.rxlifecycle.LifecycleProvider 7 | import javax.inject.Inject 8 | 9 | /* 10 | MVP中P层 基类 11 | */ 12 | open class BasePresenter{ 13 | 14 | lateinit var mView:T 15 | 16 | //Dagger注入,Rx生命周期管理 17 | @Inject 18 | lateinit var lifecycleProvider: LifecycleProvider<*> 19 | 20 | 21 | @Inject 22 | lateinit var context:Context 23 | 24 | /* 25 | 检查网络是否可用 26 | */ 27 | fun checkNetWork():Boolean{ 28 | if(NetWorkUtils.isNetWorkAvailable(context)){ 29 | return true 30 | } 31 | mView.onError("网络不可用") 32 | return false 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/injection/component/UserComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.injection.component 2 | 3 | import com.kotlin.base.injection.PerComponentScope 4 | import com.kotlin.base.injection.component.ActivityComponent 5 | import com.kotlin.user.injection.module.UploadModule 6 | import com.kotlin.user.injection.module.UserModule 7 | import com.kotlin.user.ui.activity.* 8 | import dagger.Component 9 | 10 | /* 11 | 用户模块Component 12 | */ 13 | @PerComponentScope 14 | @Component(dependencies = arrayOf(ActivityComponent::class),modules = arrayOf(UserModule::class, UploadModule::class)) 15 | interface UserComponent { 16 | fun inject(activity:RegisterActivity) 17 | fun inject(activity:LoginActivity) 18 | fun inject(activity:ForgetPwdActivity) 19 | fun inject(activity:ResetPwdActivity) 20 | fun inject(activity:UserInfoActivity) 21 | 22 | 23 | } 24 | -------------------------------------------------------------------------------- /PaySDK/src/androidTest/java/com/kotlin/pay/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.kotlin.pay.test", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /BaseLibrary/src/androidTest/java/com/kotlin/base/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.base; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.kotlin.base.test", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /UserCenter/src/androidTest/java/com/kotlin/user/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.user; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.kotlin.user.test", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/injection/component/ActivityComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.injection.component 2 | 3 | import android.app.Activity 4 | import android.content.Context 5 | import com.kotlin.base.injection.ActivityScope 6 | import com.kotlin.base.injection.module.ActivityModule 7 | import com.kotlin.base.injection.module.LifecycleProviderModule 8 | import com.trello.rxlifecycle.LifecycleProvider 9 | import dagger.Component 10 | 11 | /** 12 | * @author 桂雁彬 13 | * @date 2019/3/15. 14 | * GitHub: 15 | * email:yanbing.gui@zymobi.com 16 | * description: 17 | */ 18 | @ActivityScope 19 | @Component(dependencies = arrayOf(AppComponent::class),modules = arrayOf(ActivityModule::class, LifecycleProviderModule::class)) 20 | interface ActivityComponent { 21 | fun activity(): Activity 22 | fun context(): Context 23 | fun lifecycleProvider(): LifecycleProvider<*> 24 | } 25 | -------------------------------------------------------------------------------- /GoodsCenter/src/androidTest/java/com/kotlin/goods/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.kotlin.goods.test", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /OrderCenter/src/androidTest/java/com/kotlin/order/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.order; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.kotlin.order.test", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /MessageCenter/src/androidTest/java/com/kotlin/message/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.message; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.kotlin.message.test", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Provider/src/androidTest/java/com/kotlin/provider/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.kotlin.provider; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("com.kotlin.provider.test", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/api/GoodsApi.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.api 2 | 3 | import com.kotlin.base.data.protocol.BaseResp 4 | import com.kotlin.goods.data.protocol.* 5 | import retrofit2.http.Body 6 | import retrofit2.http.POST 7 | import rx.Observable 8 | 9 | /* 10 | 商品接口 11 | */ 12 | interface GoodsApi { 13 | /* 14 | 获取商品列表 15 | */ 16 | @POST("Kotlin_war/goods/getGoodsList") 17 | fun getGoodsList(@Body req: GetGoodsListReq): Observable?>> 18 | 19 | /* 20 | 获取商品列表 21 | */ 22 | @POST("Kotlin_war/goods/getGoodsListByKeyword") 23 | fun getGoodsListByKeyword(@Body req: GetGoodsListByKeywordReq): Observable?>> 24 | 25 | /* 26 | 获取商品详情 27 | */ 28 | @POST("Kotlin_war/goods/getGoodsDetail") 29 | fun getGoodsDetail(@Body req: GetGoodsDetailReq): Observable> 30 | } 31 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/service/impl/PayServiceImpl.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.service.impl 2 | 3 | import com.kotlin.base.ext.convert 4 | import com.kotlin.base.ext.convertBoolean 5 | import com.kotlin.pay.data.repository.PayRepository 6 | import com.kotlin.pay.service.PayService 7 | import rx.Observable 8 | import javax.inject.Inject 9 | 10 | /* 11 | 支付 业务实现类 12 | */ 13 | class PayServiceImpl @Inject constructor(): PayService{ 14 | 15 | @Inject 16 | lateinit var repository: PayRepository 17 | 18 | /* 19 | 获取支付签名 20 | */ 21 | override fun getPaySign(orderId: Int, totalPrice: Long): Observable { 22 | return repository.getPaySign(orderId,totalPrice).convert() 23 | } 24 | 25 | /* 26 | 支付订单,同步订单状态 27 | */ 28 | override fun payOrder(orderId: Int): Observable { 29 | return repository.payOrder(orderId).convertBoolean() 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/injection/component/GoodsComponent.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.injection.component 2 | 3 | import com.kotlin.base.injection.PerComponentScope 4 | import com.kotlin.base.injection.component.ActivityComponent 5 | import com.kotlin.goods.injection.module.CartModule 6 | import com.kotlin.goods.injection.module.CategoryModule 7 | import com.kotlin.goods.injection.module.GoodsModule 8 | import com.kotlin.goods.ui.activity.GoodsActivity 9 | import com.kotlin.goods.ui.fragment.CategoryFragment 10 | import com.kotlin.goods.ui.fragment.GoodsDetailTabOneFragment 11 | import dagger.Component 12 | 13 | /* 14 | 商品Component 15 | */ 16 | @PerComponentScope 17 | @Component(dependencies = arrayOf(ActivityComponent::class),modules = arrayOf(GoodsModule::class, CartModule::class)) 18 | interface GoodsComponent { 19 | fun inject(activity: GoodsActivity) 20 | fun inject(fragment: GoodsDetailTabOneFragment) 21 | } 22 | -------------------------------------------------------------------------------- /App/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /Provider/src/main/java/com/kotlin/provider/router/RouterPath.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.provider.router 2 | 3 | /** 4 | * @author 桂雁彬 5 | * @date 2019/3/22. 6 | * GitHub: 7 | * email:yanbing.gui@zymobi.com 8 | * description: 9 | */ 10 | 11 | object RouterPath{ 12 | //用户模块 13 | class UserCenter{ 14 | companion object { 15 | const val PATH_LOGIN = "/userCenter/login" 16 | } 17 | } 18 | 19 | //订单模块 20 | class OrderCenter{ 21 | companion object { 22 | const val PATH_ORDER_CONFIRM = "/orderCenter/confirm" 23 | } 24 | } 25 | 26 | //支付模块 27 | class PaySDK{ 28 | companion object { 29 | const val PATH_PAY = "/paySDK/pay" 30 | } 31 | } 32 | 33 | //消息模块 34 | class MessageCenter{ 35 | companion object { 36 | const val PATH_MESSAGE_PUSH = "/messageCenter/push" 37 | const val PATH_MESSAGE_ORDER = "/messageCenter/order" 38 | } 39 | } 40 | } -------------------------------------------------------------------------------- /BaseLibrary/src/main/res/layout/layout_state_loading.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 13 | 19 | 20 | -------------------------------------------------------------------------------- /GoodsCenter/src/main/java/com/kotlin/goods/data/api/CartApi.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.goods.data.api 2 | 3 | import com.kotlin.base.data.protocol.BaseResp 4 | import com.kotlin.goods.data.protocol.* 5 | import retrofit2.http.Body 6 | import retrofit2.http.POST 7 | import rx.Observable 8 | 9 | /* 10 | 购物车 接口 11 | */ 12 | interface CartApi { 13 | /* 14 | 获取购物车列表 15 | */ 16 | @POST("Kotlin_war/cart/getList") 17 | fun getCartList(): Observable?>> 18 | 19 | /* 20 | 添加商品到购物车 21 | */ 22 | @POST("Kotlin_war/cart/add") 23 | fun addCart(@Body req: AddCartReq): Observable> 24 | 25 | /* 26 | 删除购物车商品 27 | */ 28 | @POST("Kotlin_war/cart/delete") 29 | fun deleteCartList(@Body req: DeleteCartReq): Observable> 30 | 31 | /* 32 | 提交购物车商品 33 | */ 34 | @POST("Kotlin_war/cart/submit") 35 | fun submitCart(@Body req: SubmitCartReq): Observable> 36 | } 37 | -------------------------------------------------------------------------------- /App/src/main/java/com/kotlin/mall/ui/fragment/MessageFragment.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.mall.ui.fragment 2 | 3 | import android.os.Bundle 4 | import android.view.LayoutInflater 5 | import android.view.View 6 | import android.view.ViewGroup 7 | import com.kotlin.base.ui.fragment.BaseFragment 8 | import com.kotlin.mall.R 9 | 10 | /** 11 | * @author 桂雁彬 12 | * @date 2019/3/19. 13 | * GitHub: 14 | * email:yanbing.gui@zymobi.com 15 | * description: 16 | */ 17 | class MessageFragment :BaseFragment(),View.OnClickListener { 18 | override fun onClick(v: View?) { 19 | } 20 | 21 | override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? { 22 | super.onCreateView(inflater, container, savedInstanceState) 23 | return inflater.inflate(R.layout.fragment_me, null) 24 | 25 | } 26 | 27 | override fun onViewCreated(view: View, savedInstanceState: Bundle?) { 28 | super.onViewCreated(view, savedInstanceState) 29 | } 30 | 31 | 32 | } -------------------------------------------------------------------------------- /BaseLibrary/src/main/java/com/kotlin/base/ui/activity/BaseActivity.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.base.ui.activity 2 | 3 | import android.os.Bundle 4 | import android.view.View 5 | import android.widget.FrameLayout 6 | import com.kotlin.base.R 7 | import com.kotlin.base.common.AppManager 8 | import com.trello.rxlifecycle.components.support.RxAppCompatActivity 9 | import org.jetbrains.anko.find 10 | 11 | /* 12 | Activity基类,业务无关 13 | */ 14 | open class BaseActivity:RxAppCompatActivity() { 15 | 16 | override fun onCreate(savedInstanceState: Bundle?) { 17 | super.onCreate(savedInstanceState) 18 | 19 | AppManager.instance.addActivity(this) 20 | } 21 | 22 | override fun onDestroy() { 23 | super.onDestroy() 24 | AppManager.instance.finishActivity(this) 25 | } 26 | 27 | //获取Window中视图content 28 | val contentView:View 29 | get() { 30 | val content = find(android.R.id.content) 31 | return content.getChildAt(0) 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /PaySDK/src/main/java/com/kotlin/pay/data/repository/PayRepository.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.pay.data.repository 2 | 3 | 4 | import com.kotlin.base.data.net.RetrofitFactory 5 | import com.kotlin.base.data.protocol.BaseResp 6 | import com.kotlin.pay.data.api.PayApi 7 | import com.kotlin.pay.data.protocol.GetPaySignReq 8 | import com.kotlin.pay.data.protocol.PayOrderReq 9 | import rx.Observable 10 | import javax.inject.Inject 11 | 12 | 13 | /* 14 | 支付数据层 15 | */ 16 | class PayRepository @Inject constructor() { 17 | 18 | /* 19 | 获取支付宝支付签名 20 | */ 21 | fun getPaySign(orderId: Int, totalPrice: Long): Observable> { 22 | return RetrofitFactory.instance.create(PayApi::class.java).getPaySign(GetPaySignReq(orderId, totalPrice)) 23 | } 24 | 25 | /* 26 | 刷新订单状态已支付 27 | */ 28 | fun payOrder(orderId: Int): Observable> { 29 | return RetrofitFactory.instance.create(PayApi::class.java).payOrder(PayOrderReq(orderId)) 30 | } 31 | 32 | 33 | } 34 | -------------------------------------------------------------------------------- /UserCenter/src/main/java/com/kotlin/user/utils/UserPrefsUtils.kt: -------------------------------------------------------------------------------- 1 | package com.kotlin.user.utils 2 | 3 | import com.kotlin.base.common.BaseConstant 4 | import com.kotlin.provider.common.ProviderConstant 5 | import com.kotlin.base.utils.AppPrefsUtils 6 | import com.kotlin.user.data.protocol.UserInfo 7 | 8 | /* 9 | 本地存储用户相关信息 10 | */ 11 | object UserPrefsUtils { 12 | 13 | /* 14 | 退出登录时,传入null,清空存储 15 | */ 16 | fun putUserInfo(userInfo: UserInfo?) { 17 | AppPrefsUtils.putString(BaseConstant.KEY_SP_TOKEN, userInfo?.id ?: "") 18 | AppPrefsUtils.putString(ProviderConstant.KEY_SP_USER_ICON, userInfo?.userIcon ?: "") 19 | AppPrefsUtils.putString(ProviderConstant.KEY_SP_USER_NAME, userInfo?.userName ?: "") 20 | AppPrefsUtils.putString(ProviderConstant.KEY_SP_USER_MOBILE, userInfo?.userMobile ?: "") 21 | AppPrefsUtils.putString(ProviderConstant.KEY_SP_USER_GENDER, userInfo?.userGender ?: "") 22 | AppPrefsUtils.putString(ProviderConstant.KEY_SP_USER_SIGN, userInfo?.userSign ?: "") 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /App/src/main/res/layout/activity_setting.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 12 | 16 | 20 |