xiongzhu 4 лет назад
Родитель
Сommit
bb5c0e4155
31 измененных файлов с 115 добавлено и 89 удалено
  1. 0 7
      src/main/comos/.env.app
  2. 0 7
      src/main/comos/.env.app_test
  3. 1 1
      src/main/comos/.env.development
  4. 2 2
      src/main/comos/.env.production
  5. 1 1
      src/main/comos/src/components/PageBar.vue
  6. 1 1
      src/main/comos/src/main.js
  7. 42 42
      src/main/comos/src/router/index.js
  8. 2 1
      src/main/comos/src/views/Home.vue
  9. 1 1
      src/main/comos/src/views/account/Connect.vue
  10. 2 2
      src/main/comos/src/views/account/Introduction.vue
  11. 1 1
      src/main/comos/src/views/account/Question.vue
  12. 4 4
      src/main/comos/src/views/asset/Detail.vue
  13. 4 4
      src/main/comos/src/views/product/Detail.vue
  14. 1 1
      src/main/comos/src/views/user/Follows.vue
  15. 4 0
      src/main/java/com/izouma/nineth/domain/Asset.java
  16. 2 0
      src/main/java/com/izouma/nineth/domain/Banner.java
  17. 2 0
      src/main/java/com/izouma/nineth/domain/BlindBoxItem.java
  18. 2 0
      src/main/java/com/izouma/nineth/domain/Collection.java
  19. 2 0
      src/main/java/com/izouma/nineth/domain/Order.java
  20. 2 0
      src/main/java/com/izouma/nineth/domain/Recommend.java
  21. 3 3
      src/main/java/com/izouma/nineth/repo/CollectionRepo.java
  22. 2 0
      src/main/java/com/izouma/nineth/service/AssetService.java
  23. 1 0
      src/main/java/com/izouma/nineth/service/CollectionService.java
  24. 1 0
      src/main/java/com/izouma/nineth/service/OrderService.java
  25. 2 2
      src/main/java/com/izouma/nineth/web/CollectionController.java
  26. 1 1
      src/main/nine-space/src/store/index.js
  27. 4 5
      src/main/resources/application.yaml
  28. 6 0
      src/main/vue/src/mixins/pageableTable.js
  29. 6 1
      src/main/vue/src/store.js
  30. 9 1
      src/main/vue/src/views/Admin.vue
  31. 4 1
      src/main/vue/src/views/CollectionList.vue

+ 0 - 7
src/main/comos/.env.app

@@ -1,7 +0,0 @@
-VUE_APP_BASE_URL=https://nft.9space.vip/
-NODE_ENV=production
-PUBLIC_PATH=./
-ASSETS_PATH=raex
-TITLE=Comos
-VUE_APP_CORDOVA=true
-VUE_APP_PAGE_TYPE=raex

+ 0 - 7
src/main/comos/.env.app_test

@@ -1,7 +0,0 @@
-VUE_APP_BASE_URL=https://test.raex.vip
-NODE_ENV=production
-PUBLIC_PATH=./
-ASSETS_PATH=raex
-TITLE=Comos
-VUE_APP_CORDOVA=true
-VUE_APP_PAGE_TYPE=raex

+ 1 - 1
src/main/comos/.env.development

@@ -2,5 +2,5 @@ VUE_APP_BASE_URL=https://nfttest.9space.vip/
 NODE_ENV=development
 PUBLIC_PATH=/
 ASSETS_PATH=raex
-TITLE=Comos
+TITLE=Cosmos Art
 VUE_APP_PAGE_TYPE=raex

+ 2 - 2
src/main/comos/.env.production

@@ -1,6 +1,6 @@
 VUE_APP_BASE_URL=/
 NODE_ENV=production
-PUBLIC_PATH=/9th/
+PUBLIC_PATH=/cosmos/
 ASSETS_PATH=raex
-TITLE=Comos
+TITLE=Cosmos Art
 VUE_APP_PAGE_TYPE=raex

+ 1 - 1
src/main/comos/src/components/PageBar.vue

@@ -2,7 +2,7 @@
     <div class="bar">
         <div>
             <div class="text1">
-                <slot>第九空间</slot>
+                <slot>Cosmos Art</slot>
             </div>
             <div class="text2">
                 <span> <slot name="sub"></slot></span>

+ 1 - 1
src/main/comos/src/main.js

@@ -71,7 +71,7 @@ if (query.code) {
     });
 } else {
     if (/micromessenger/i.test(navigator.userAgent) && !/localhost|(192\.168)/i.test(location.host)) {
-        // document.location.replace(location.origin + '/wx/redirect?redirectUrl=' + location.href);
+        document.location.replace('https://nft.9space.vip/wx/redirect?redirectUrl=' + location.href);
     }
 }
 if (query.invitor) {

+ 42 - 42
src/main/comos/src/router/index.js

@@ -35,14 +35,14 @@ function jsapiSign() {
                     });
                     wx.ready(function () {
                         wx.updateAppMessageShareData({
-                            title: '第九空间',
-                            desc: '全球首个基于区块链的游戏资产集换中心',
-                            link: location.origin + '/9th',
+                            title: 'Cosmos Art',
+                            desc: 'Cosmos Art',
+                            link: location.origin + '/cosmos',
                             imgUrl: 'https://9space-2021.oss-cn-shenzhen.aliyuncs.com/nft/2021-11-05-15-58-30YwqLzMjy.jpg'
                         });
                         wx.updateTimelineShareData({
-                            title: '第九空间-全球首个基于区块链的游戏资产集换中心',
-                            link: location.origin + '/9th',
+                            title: 'Cosmos Art',
+                            link: location.origin + '/cosmos',
                             imgUrl: 'https://9space-2021.oss-cn-shenzhen.aliyuncs.com/nft/2021-11-05-15-58-30YwqLzMjy.jpg'
                         });
                     });
@@ -69,7 +69,7 @@ const routes = [
                 meta: {
                     pageType: Page.Every,
                     menuPage: true,
-                    title: '第九空间'
+                    title: 'Cosmos Art'
                 }
             },
             {
@@ -79,7 +79,7 @@ const routes = [
                 meta: {
                     pageType: Page.Every,
                     menuPage: true,
-                    title: '第九空间'
+                    title: 'Cosmos Art'
                 }
             },
             {
@@ -89,7 +89,7 @@ const routes = [
                 meta: {
                     pageType: Page.Every,
                     menuPage: true,
-                    title: '第九空间'
+                    title: 'Cosmos Art'
                 }
             },
             {
@@ -99,7 +99,7 @@ const routes = [
                 meta: {
                     pageType: Page.Every,
                     menuPage: true,
-                    title: '第九空间'
+                    title: 'Cosmos Art'
                 }
             },
             {
@@ -109,7 +109,7 @@ const routes = [
                 meta: {
                     pageType: Page.Every,
                     menuPage: true,
-                    title: '第九空间'
+                    title: 'Cosmos Art'
                 }
             }
         ]
@@ -205,7 +205,7 @@ const routes = [
         component: () => import('../views/account/About.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -214,7 +214,7 @@ const routes = [
         component: () => import('../views/account/Introduction.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -223,7 +223,7 @@ const routes = [
         component: () => import('../views/account/Question.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -242,7 +242,7 @@ const routes = [
         component: () => import('../views/product/Detail.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
             // tabColor: '#181818'
         }
     },
@@ -252,7 +252,7 @@ const routes = [
         component: () => import('../views/product/DetailMode.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -261,7 +261,7 @@ const routes = [
         component: () => import('../views/product/List.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -270,7 +270,7 @@ const routes = [
         component: () => import('../views/product/Search.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -279,7 +279,7 @@ const routes = [
         component: () => import('../views/creator/Detail.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -288,7 +288,7 @@ const routes = [
         component: () => import('../views/creator/List.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -297,7 +297,7 @@ const routes = [
         component: () => import('../views/creator/Search.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -306,7 +306,7 @@ const routes = [
         component: () => import('../views/asset/Detail.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
             // tabColor: '#181818'
         }
     },
@@ -316,7 +316,7 @@ const routes = [
         component: () => import('../views/asset/Consignment.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -324,7 +324,7 @@ const routes = [
         name: 'assetSearch',
         component: () => import('../views/asset/Search.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -332,7 +332,7 @@ const routes = [
         name: 'giveSearch',
         component: () => import('../views/asset/GiveSearch.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -340,7 +340,7 @@ const routes = [
         name: 'submit',
         component: () => import('../views/Submit.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -348,7 +348,7 @@ const routes = [
         name: 'couponList',
         component: () => import('../views/order/CouponList.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -356,7 +356,7 @@ const routes = [
         name: 'givesubmit',
         component: () => import('../views/Givesubmit.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -365,7 +365,7 @@ const routes = [
         component: () => import('../views/creator/Detail.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -373,7 +373,7 @@ const routes = [
         name: 'orders',
         component: () => import('../views/order/Orders.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -381,7 +381,7 @@ const routes = [
         name: 'orderDetail',
         component: () => import('../views/order/Detail.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -390,7 +390,7 @@ const routes = [
         component: () => import('../views/activity/List.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -399,7 +399,7 @@ const routes = [
         component: () => import('../views/activity/Detail.vue'),
         meta: {
             pageType: Page.Every,
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -407,7 +407,7 @@ const routes = [
         name: 'mineFollows',
         component: () => import('../views/user/Follows.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -415,7 +415,7 @@ const routes = [
         name: 'mineFollowers',
         component: () => import('../views/user/Followers.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -423,7 +423,7 @@ const routes = [
         name: 'mineLikes',
         component: () => import('../views/user/Likes.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -431,7 +431,7 @@ const routes = [
         name: 'mineBanks',
         component: () => import('../views/user/Banks.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -439,7 +439,7 @@ const routes = [
         name: 'mineBanksAdd',
         component: () => import('../views/user/BanksAdd.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -447,7 +447,7 @@ const routes = [
         name: 'mineAddress',
         component: () => import('../views/user/Address.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -455,7 +455,7 @@ const routes = [
         name: 'mineAddressEdit',
         component: () => import('../views/user/AddressEdit.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -463,7 +463,7 @@ const routes = [
         name: 'mineWallet',
         component: () => import('../views/user/Wallet.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -471,7 +471,7 @@ const routes = [
         name: 'minePoint',
         component: () => import('../views/user/Point.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     },
     {
@@ -479,7 +479,7 @@ const routes = [
         name: 'mineExchange',
         component: () => import('../views/user/Exchange.vue'),
         meta: {
-            title: '第九空间'
+            title: 'Cosmos Art'
         }
     }
 ];

+ 2 - 1
src/main/comos/src/views/Home.vue

@@ -92,7 +92,8 @@ export default {
         getProduct(type = 'BANNER') {
             return this.$http
                 .get('/collection/recommend', {
-                    type: type
+                    type: type,
+                    projectId: this.$store.state.projectId
                 })
                 .then(res => {
                     return Promise.resolve(res);

+ 1 - 1
src/main/comos/src/views/account/Connect.vue

@@ -31,7 +31,7 @@ export default {
     line-height: 30px;
 }
 .page {
-    background-color: @bg3;;
+    background-color: @bg3;
 }
 
 .van-cell-group {

+ 2 - 2
src/main/comos/src/views/account/Introduction.vue

@@ -7,7 +7,7 @@
                     RAEX绿洲是全球领先的专业艺术品生态簇运营商,重点打造“全球领先数字藏品生态簇”的产业闭环,持续塑造推出中国权威数字文创商品,参与全球数字藏品定价体系,加速“一带一路”的全球文化内容输出。在这里您可以创造、收集、售卖您的艺术品及数字手办潮玩,感受全球顽家为您带来的新奇别致体验,共同探索艺术宇宙的真实奥秘!欢迎您的加入!
                 </p>
                 <p>
-                    Comos,是元宇宙游戏《The Oasis绿洲》旗下重要的艺术品生态簇底层架构及原生内容展示平台,是《The
+                    Cosmos,是元宇宙游戏《The Oasis绿洲》旗下重要的艺术品生态簇底层架构及原生内容展示平台,是《The
                     Oasis绿洲》体系中的核心载体之一。
                 </p>
                 <p>
@@ -15,7 +15,7 @@
                     Oasis绿洲》的重要特征是开放和自由创作,且可进行不断扩张,摆脱了现实世界时间和空间的束缚,让用户能够放飞自己的想象力,在虚拟世界里自由搭建自己想要做的东西,并在用户互动中碰撞出更多的灵感火花。用户可以搭建建筑并展出自己的成果。用户购买虚拟地产后,可以通过搭建自己喜欢的建筑,展示自己的数字藏品,或者搭建自己的办公室甚至可以在里面开餐厅、数字展厅等。这些成果还可以在项目内进行交易、展览,获得项目积分支持。
                 </p>
                 <p>
-                    Comos于全球范围内持续性引入世界级IP,建立强大且完善的IP数据库:包含演艺明星、体育赛事、科技潮玩,潮流音乐,当红小说、知名艺术品及流量动漫在内的多种配置。
+                    Cosmos于全球范围内持续性引入世界级IP,建立强大且完善的IP数据库:包含演艺明星、体育赛事、科技潮玩,潮流音乐,当红小说、知名艺术品及流量动漫在内的多种配置。
                 </p>
             </div>
         </div>

+ 1 - 1
src/main/comos/src/views/account/Question.vue

@@ -11,7 +11,7 @@
                 <p>您好~已购买的数字藏品是经过蚂蚁链确权,权属清晰、数量透明,永不增发的藏品,极具收藏价值。</p>
                 <h6>3.如何购买数字藏品?</h6>
                 <p>您好~购买步骤如下:</p>
-                <p>1)下载Comos;</p>
+                <p>1)下载Cosmos;</p>
                 <p>2)注册账号;</p>
                 <p>3)浏览首页/发现页中的商品;</p>
                 <p>4)点击“立即购买“,付款;</p>

+ 4 - 4
src/main/comos/src/views/asset/Detail.vue

@@ -560,14 +560,14 @@ export default {
                     this.orderInfo = res;
                 });
                 wx.updateAppMessageShareData({
-                    title: '第九空间-' + res.name,
+                    title: 'Cosmos Art - ' + res.name,
                     desc: '全球首个基于区块链的游戏资产集换中心',
-                    link: location.origin + '/9th/assetDetail?id=' + res.id,
+                    link: location.origin + '/cosmos/assetDetail?id=' + res.id,
                     imgUrl: this.getImg(this.changeImgs(this.banners), '', 600)
                 });
                 wx.updateTimelineShareData({
-                    title: '第九空间-' + res.name,
-                    link: location.origin + '/9th/assetDetail?id=' + res.id,
+                    title: 'Cosmos Art - ' + res.name,
+                    link: location.origin + '/cosmos/assetDetail?id=' + res.id,
                     imgUrl: this.getImg(this.changeImgs(this.banners), '', 600)
                 });
                 this.tokenId = this.info.tokenId;

+ 4 - 4
src/main/comos/src/views/product/Detail.vue

@@ -366,14 +366,14 @@ export default {
                     this.info = res;
                     if (this.inWeixin) {
                         wx.updateAppMessageShareData({
-                            title: '第九空间-' + res.name,
+                            title: 'Cosmos Art - ' + res.name,
                             desc: '全球首个基于区块链的游戏资产集换中心',
-                            link: location.origin + '/9th/productDetail?id=' + res.id,
+                            link: location.origin + '/cosmos/productDetail?id=' + res.id,
                             imgUrl: this.getImg(this.changeImgs(this.banners), '', 300)
                         });
                         wx.updateTimelineShareData({
-                            title: '第九空间-' + res.name,
-                            link: location.origin + '/9th/productDetail?id=' + res.id,
+                            title: 'Cosmos Art - ' + res.name,
+                            link: location.origin + '/cosmos/productDetail?id=' + res.id,
                             imgUrl: this.getImg(this.changeImgs(this.banners), '', 300)
                         });
                         console.log(wx);

+ 1 - 1
src/main/comos/src/views/user/Follows.vue

@@ -58,7 +58,7 @@ export default {
 
 <style lang="less" scoped>
 .follow {
-    background-color: @bg3;;
+    background-color: @bg3;
 }
 .top {
     background-color: @bg;

+ 4 - 0
src/main/java/com/izouma/nineth/domain/Asset.java

@@ -149,6 +149,8 @@ public class Asset extends BaseEntity {
 
     private Long fromAssetId;
 
+    private int projectId;
+
     public static Asset create(Collection collection, User user) {
         return Asset.builder()
                 .userId(user.getId())
@@ -171,6 +173,7 @@ public class Asset extends BaseEntity {
                 .owner(user.getNickname())
                 .ownerId(user.getId())
                 .ownerAvatar(user.getAvatar())
+                .projectId(collection.getProjectId())
                 .build();
     }
 
@@ -196,6 +199,7 @@ public class Asset extends BaseEntity {
                 .owner(user.getNickname())
                 .ownerId(user.getId())
                 .ownerAvatar(user.getAvatar())
+                .projectId(item.getProjectId())
                 .build();
     }
 }

+ 2 - 0
src/main/java/com/izouma/nineth/domain/Banner.java

@@ -46,4 +46,6 @@ public class Banner extends BaseEntity {
 
     @ApiModelProperty("跳转内容")
     private String linkContent;
+
+    private int projectId;
 }

+ 2 - 0
src/main/java/com/izouma/nineth/domain/BlindBoxItem.java

@@ -91,4 +91,6 @@ public class BlindBoxItem extends BaseEntity {
 
     @ApiModelProperty("稀有")
     private boolean rare;
+
+    private int projectId;
 }

+ 2 - 0
src/main/java/com/izouma/nineth/domain/Collection.java

@@ -136,4 +136,6 @@ public class Collection extends BaseEntity {
 
     @Formula(value = "if(stock = 0, 1, 0)")
     private int soldOut;
+
+    private int projectId;
 }

+ 2 - 0
src/main/java/com/izouma/nineth/domain/Order.java

@@ -149,4 +149,6 @@ public class Order extends BaseEntity {
     private Long invitor;
 
     private boolean opened;
+
+    private int projectId;
 }

+ 2 - 0
src/main/java/com/izouma/nineth/domain/Recommend.java

@@ -28,4 +28,6 @@ public class Recommend extends BaseEntity {
     private String type;
 
     private String pic;
+
+    private int projectId;
 }

+ 3 - 3
src/main/java/com/izouma/nineth/repo/CollectionRepo.java

@@ -27,7 +27,7 @@ public interface CollectionRepo extends JpaRepository<Collection, Long>, JpaSpec
     @Modifying
     @Query(value = "update collection_info c set c.on_shelf = ?2, c.salable = ?3, c.start_time = ?4, " +
             "c.schedule_sale = ?5, c.sort = ?6, c.detail = ?7, c.privileges = ?8, " +
-            "c.properties = ?9, c.model3d = ?10 where c.id = ?1",nativeQuery = true)
+            "c.properties = ?9, c.model3d = ?10 where c.id = ?1", nativeQuery = true)
     @CacheEvict(value = {"collection", "recommend"}, allEntries = true)
     void update(@Nonnull Long id, boolean onShelf, boolean salable, LocalDateTime startTime,
                 boolean schedule, int sort, String detail, String privileges,
@@ -54,8 +54,8 @@ public interface CollectionRepo extends JpaRepository<Collection, Long>, JpaSpec
     Collection save(@Nonnull Collection collection);
 
     @Query("select new com.izouma.nineth.dto.RecommendCollection(c,r) from Collection c join Recommend r on c.id = r.collectionId " +
-            "where c.del = false and c.onShelf = true and r.type = ?1 order by r.sort desc")
-    List<RecommendCollection> recommend(String type);
+            "where c.del = false and c.onShelf = true and r.type = ?1 and c.projectId = ?2 order by r.sort desc")
+    List<RecommendCollection> recommend(String type, int projectId);
 
     @Transactional
     @Modifying

+ 2 - 0
src/main/java/com/izouma/nineth/service/AssetService.java

@@ -133,6 +133,7 @@ public class AssetService {
                 .serviceCharge(asset.getServiceCharge())
                 .assetId(id)
                 .number(asset.getNumber())
+                .projectId(asset.getProjectId())
                 .build();
         collectionRepo.save(collection);
         asset.setPublicShow(true);
@@ -186,6 +187,7 @@ public class AssetService {
                 .serviceCharge(asset.getServiceCharge())
                 .assetId(id)
                 .number(asset.getNumber())
+                .projectId(asset.getProjectId())
                 .build();
         collectionRepo.save(collection);
         asset.setPublicShow(true);

+ 1 - 0
src/main/java/com/izouma/nineth/service/CollectionService.java

@@ -232,6 +232,7 @@ public class CollectionService {
             blindBoxItem.setStock(item.getTotal());
             blindBoxItem.setRare(item.isRare());
             blindBoxItem.setBlindBoxId(blindBox.getId());
+            blindBoxItem.setProjectId(blindBox.getProjectId());
             blindBoxItemRepo.save(blindBoxItem);
         }
 

+ 1 - 0
src/main/java/com/izouma/nineth/service/OrderService.java

@@ -144,6 +144,7 @@ public class OrderService {
                 .assetId(collection.getAssetId())
                 .couponId(userCouponId)
                 .invitor(invitor)
+                .projectId(collection.getProjectId())
                 .build();
         if (coupon != null) {
             coupon.setUsed(true);

+ 2 - 2
src/main/java/com/izouma/nineth/web/CollectionController.java

@@ -97,8 +97,8 @@ public class CollectionController extends BaseController {
     }
 
     @GetMapping("/recommend")
-    public List<CollectionDTO> recommend(@RequestParam String type) {
-        return collectionService.toDTO(collectionRepo.recommend(type).stream().map(rc -> {
+    public List<CollectionDTO> recommend(@RequestParam String type, @RequestParam(defaultValue = "0") int projectId) {
+        return collectionService.toDTO(collectionRepo.recommend(type, projectId).stream().map(rc -> {
             if (StringUtils.isNotBlank(rc.getRecommend().getPic())) {
                 rc.getCollection().setPic(Collections.singletonList(new FileObject(null, rc.getRecommend()
                         .getPic(), null, null)));

+ 1 - 1
src/main/nine-space/src/store/index.js

@@ -9,7 +9,7 @@ export default createStore({
         couponInfo: null,
         invitor: null,
         countdown: '',
-        projectId:1
+        projectId: 0
     },
     mutations: {
         setFinished(state, finished) {

+ 4 - 5
src/main/resources/application.yaml

@@ -12,9 +12,9 @@ spring:
   profiles:
     active: dev
   datasource:
-    url: jdbc:mysql://rm-wz9y2p75f51a2o19kbo.mysql.rds.aliyuncs.com:53306/9th_test?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&useSSL=false&serverTimezone=GMT%2b8
-    username: develop
-    password: glV1BJCzcNB9ughR
+    url: jdbc:mysql://192.168.50.10/9th_test?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&useSSL=false&serverTimezone=GMT%2b8
+    username: root
+    password: 123456
     hikari:
       minimum-idle: 5
       maximum-pool-size: 30
@@ -77,9 +77,8 @@ spring:
         enable_lazy_load_no_trans: true
     open-in-view: true
   redis:
-    host: 120.78.235.238
+    host: 192.168.50.16
     port: 6379
-    password: 98dwT6ghgoRVxwcRrDDy
     lettuce:
       pool:
         max_active: 8

+ 6 - 0
src/main/vue/src/mixins/pageableTable.js

@@ -47,6 +47,7 @@ export default {
                     data = { ...data, ...mergeData };
                 }
             }
+            data.query.projectId = this.$store.state.projectId;
             this.fetchingData = true;
             this.$http
                 .post(this.url, data, { body: 'json' })
@@ -159,6 +160,11 @@ export default {
                 .catch(_ => {});
             this.sortStr = sortStr;
             this.getData();
+        },
+        '$store.state.projectId'() {
+            this.search = '';
+            this.page = 1;
+            this.getData();
         }
     }
 };

+ 6 - 1
src/main/vue/src/store.js

@@ -7,7 +7,8 @@ export default new Vuex.Store({
     state: {
         tableHeight: 0,
         fetchingData: false,
-        userInfo: null
+        userInfo: null,
+        projectId: parseInt(localStorage.getItem('9th_projectId') || 0)
     },
     mutations: {
         updateTableHeight(state, height) {
@@ -18,6 +19,10 @@ export default new Vuex.Store({
         },
         updateUserInfo(state, userInfo) {
             state.userInfo = userInfo;
+        },
+        setProjectId(state, projectId) {
+            state.projectId = projectId;
+            localStorage.setItem('9th_projectId', projectId);
         }
     },
     actions: {}

+ 9 - 1
src/main/vue/src/views/Admin.vue

@@ -24,7 +24,12 @@
                         <i class="fas fa-bars" style="font-size: 18px"></i>
                     </div>
                 </div>
-                <div style="flex-grow: 1; margin-left: 20px"></div>
+                <div style="flex-grow: 1; margin-left: 20px">
+                    <el-select :value="$store.state.projectId" @input="changeProjectId">
+                        <el-option :value="0" label="第九空间"></el-option>
+                        <el-option :value="1" label="comos art"></el-option>
+                    </el-select>
+                </div>
 
                 <el-tooltip
                     effect="dark"
@@ -253,6 +258,9 @@ export default {
                 this.captcha = res.image;
                 this.pwdForm.key = res.key;
             });
+        },
+        changeProjectId(projectId) {
+            this.$store.commit('setProjectId', projectId);
         }
     },
     watch: {

+ 4 - 1
src/main/vue/src/views/CollectionList.vue

@@ -172,7 +172,10 @@ export default {
             return '';
         },
         beforeGetData() {
-            return { search: this.search, query: { del: false, source: 'OFFICIAL' } };
+            return {
+                search: this.search,
+                query: { del: false, source: 'OFFICIAL' }
+            };
         },
         toggleMultipleMode(multipleMode) {
             this.multipleMode = multipleMode;