From b9fd7aae25c66c19a7e645b267befbe1217aab57 Mon Sep 17 00:00:00 2001 From: xhxu Date: Thu, 26 Nov 2020 17:07:45 +0800 Subject: [PATCH] bug --- .../migration/V202011250001__miniappTheme.sql | 23 +++++++++++++++++++ .../iformall/enums/EnumCouponChannelType.java | 1 + .../resources/mapper/WxMiniappThemeMapper.xml | 2 +- 3 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 mallinkAdmin/src/main/resources/db/migration/V202011250001__miniappTheme.sql diff --git a/mallinkAdmin/src/main/resources/db/migration/V202011250001__miniappTheme.sql b/mallinkAdmin/src/main/resources/db/migration/V202011250001__miniappTheme.sql new file mode 100644 index 000000000..d75cbbbd3 --- /dev/null +++ b/mallinkAdmin/src/main/resources/db/migration/V202011250001__miniappTheme.sql @@ -0,0 +1,23 @@ +--加小程序换肤菜单 +INSERT INTO `mall_permission`(`id`, `name`, `parent_id`, `available`, `permission`, `resource_type`, `module_color`, `module_color_num`, `url`, `icon`, `version_type`, `sort`) VALUES (904, '其他设置', 50, 'Y', NULL, 0, NULL, NULL, null, 'icon-xitongguanli', 0, 904); +INSERT INTO `mall_permission`(`id`, `name`, `parent_id`, `available`, `permission`, `resource_type`, `module_color`, `module_color_num`, `url`, `icon`, `version_type`, `sort`) VALUES (905, '主题管理', 904, 'Y', NULL, 1, NULL, NULL, 'miniappTheme', null, 0, 905); + +--销售类型加权限 +update mall_sale_type set menus = '[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 50, 101, 102, 103, 104, 105, 106, 107, 108, 201, 202, 203, 204, 205, 206, 209, 211, 212, 221, 222, 251, 299, 300, 301, 302, 303, 304, 305, 306, 401, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, 501, 502, 503, 504, 505, 506, 507, 508, 509, 511, 512, 513, 521, 522, 523, 531, 532, 533, 591, 592, 595, 601, 602, 603, 604, 605, 606, 607, 608, 609, 610, 611, 612, 621, 622, 623, 624, 625, 626, 627, 641, 642, 643, 644, 645, 646, 651, 661, 662, 663, 671, 672, 673, 674, 675, 681, 682, 683, 684, 685, 686, 691, 692, 693, 694, 695, 701, 702, 703, 704, 711, 712, 713, 901, 902, 903, 904, 905, 931, 932, 951, 952, 961, 962, 963, 965, 966, 967, 968, 1001, 1002, 1003, 1004]' where id=1; +update mall_sale_type set menus = '[1, 2, 4, 5, 6, 7, 8, 9, 10, 50, 101, 102, 103, 104, 105, 106, 107, 201, 202, 203, 204, 205, 209, 211, 212, 221, 222, 251, 409, 410, 411, 416, 418, 501, 502, 503, 504, 505, 506, 507, 508, 509, 511, 512, 513, 521, 522, 523, 531, 532, 533, 591, 592, 595, 601, 602, 603, 604, 605, 606, 607, 608, 609, 610, 611, 612, 621, 622, 623, 624, 625, 626, 627, 641, 642, 643, 644, 645, 646, 651, 661, 662, 663, 671, 672, 673, 674, 675, 681, 682, 683, 684, 685, 686, 691, 692, 693, 694, 695, 701, 702, 703, 704, 711, 712, 713, 901, 902, 903, 904, 905, 931, 932, 951, 961]' where id=2; +update mall_sale_type set menus = '[2, 4, 5, 6, 7, 10, 50, 201, 202, 205, 211, 212, 221, 222, 251, 409, 410, 411, 416, 418, 501, 502, 503, 504, 505, 506, 507, 508, 511, 512, 513, 521, 522, 523, 531, 532, 533, 591, 592, 601, 602, 603, 604, 605, 606, 607, 608, 609, 610, 611, 612, 621, 622, 623, 624, 625, 626, 641, 642, 643, 644, 645, 646, 651, 661, 662, 663, 671, 672, 673, 674, 675, 681, 682, 683, 684, 685, 686, 691, 692, 693, 694, 695, 701, 702, 703, 704, 711, 712, 713, 901, 902, 903, 904, 905, 931, 932]' where id=3; +update mall_sale_type set menus = '[2, 4, 5, 6, 7, 10, 50, 201, 202, 205, 211, 212, 221, 222, 251, 409, 410, 411, 416, 418, 501, 502, 503, 504, 505, 506, 507, 508, 511, 512, 513, 521, 522, 523, 531, 532, 591, 601, 602, 604, 605, 606, 607, 608, 610, 611, 612, 622, 623, 624, 625, 626, 641, 642, 643, 644, 661, 662, 663, 671, 672, 674, 675, 681, 682, 684, 685, 686, 691, 692, 693, 694, 695, 711, 901, 902, 904, 905, 931, 932]' where id=4; + +--所有广场管理员角色加权限 +INSERT INTO `mall_role_permission`(`id`, `tenant_id`, `parent_tenant_id`, `permission_id`, `role_id`) + select CEILING(RAND()*90000000000+10000000000) ,mui.tenant_id,mui.parent_tenant_id,904,mur.role_id +from mall_user_info mui +left join mall_user_role mur on mui.id = mur.uid +where mui.is_admin = 1 and mur.role_id is not null GROUP BY mur.role_id; + +INSERT INTO `mall_role_permission`(`id`, `tenant_id`, `parent_tenant_id`, `permission_id`, `role_id`) + select CEILING(RAND()*90000000000+10000000000) ,mui.tenant_id,mui.parent_tenant_id,905,mur.role_id +from mall_user_info mui +left join mall_user_role mur on mui.id = mur.uid +where mui.is_admin = 1 and mur.role_id is not null GROUP BY mur.role_id; + diff --git a/mallinkService/src/main/java/com/iformall/enums/EnumCouponChannelType.java b/mallinkService/src/main/java/com/iformall/enums/EnumCouponChannelType.java index 12350946e..066843772 100644 --- a/mallinkService/src/main/java/com/iformall/enums/EnumCouponChannelType.java +++ b/mallinkService/src/main/java/com/iformall/enums/EnumCouponChannelType.java @@ -13,6 +13,7 @@ public enum EnumCouponChannelType { COUPON_CHANNEL_ID_PRESS(6, "砍价频道"), COUPON_CHANNEL_ID_ORDER_GROUP(7, "拼团频道"), COUPON_CHANNEL_ID_TOPIC(8, "专题"), + COUPON_CHANNEL_ID_PREORDER(9, "预购商品"), COUPON_CHANNEL_ID_CREDIT(50, "积分商城"), COUPON_CHANNEL_ID_H5(100, "DSP的H5页面"), ; diff --git a/mallinkService/src/main/resources/mapper/WxMiniappThemeMapper.xml b/mallinkService/src/main/resources/mapper/WxMiniappThemeMapper.xml index 0dc10fe71..60cf39aa3 100644 --- a/mallinkService/src/main/resources/mapper/WxMiniappThemeMapper.xml +++ b/mallinkService/src/main/resources/mapper/WxMiniappThemeMapper.xml @@ -48,7 +48,7 @@ update wx_miniapp_theme set `status` = 0, update_date = now() where id = #{id} and del_status = 0; - update wx_miniapp_theme set `status` = 1, update_date = now() where tenant_id = #{tenantId} and id != #{id} and `status` = 0 and del_status = 0 ; + update wx_miniapp_theme set `status` = 1, update_date = now() where tenant_id = #{tenantId} and id <> #{id} and `status` = 0 and del_status = 0 ;