diff --git a/fir_ser/common/libs/sendmsg/templates/check_developer.html b/fir_ser/common/libs/sendmsg/templates/check_developer.html index 5ac4f71..b34c508 100644 --- a/fir_ser/common/libs/sendmsg/templates/check_developer.html +++ b/fir_ser/common/libs/sendmsg/templates/check_developer.html @@ -10,10 +10,6 @@ margin-left: auto; } - .span12 { - width: 1170px; - } - .table { --bs-table-bg: transparent; --bs-table-accent-bg: transparent; @@ -136,7 +132,7 @@
-
+

尊敬的用户 {{ username }} 你好,苹果开发者状态监测如下:

diff --git a/fir_ser/tests/postudid.py b/fir_ser/tests/postudid.py index 3f04a18..3040b16 100644 --- a/fir_ser/tests/postudid.py +++ b/fir_ser/tests/postudid.py @@ -52,7 +52,7 @@ short_list = [ def postudid(short=short_list[0], udid=udid_lists[0]): data = '\n\n\n\n\tPRODUCT\n\tiPhone9,1\n\tSERIAL\n\tF71YD58GHG74\n\tUDID\n\t%s\n\tVERSION\n\t17E262\n\n\n' % ( udid) - uri = "https://app.hehelucky.cn/udid/%s" % (short) + uri = "https://app.hehelucky.cn/api/v1/fir/xsign/udid/%s" % (short) req = requests.post(uri, data=data) print(req.status_code, req.text) @@ -93,9 +93,8 @@ udid_test_s = [ "00008030-000E6CC122D2402E" ] - -# postudid(udid="760862a7367dea986542dae17ee31cd139e454ad", short='semi') -# exit() +postudid(udid="41d1b77e3a831f82a0ca306beaceeb955280b57a", short='vcdp') +exit() def call_function_try_attempts(try_attempts=3): diff --git a/fir_ser/xsign/utils/supersignutils.py b/fir_ser/xsign/utils/supersignutils.py index b7cfcfb..77a0aa5 100644 --- a/fir_ser/xsign/utils/supersignutils.py +++ b/fir_ser/xsign/utils/supersignutils.py @@ -1080,29 +1080,38 @@ class IosUtils(object): udid_developer_obj_list = UDIDsyncDeveloper.objects.filter(developerid=developer_obj).values_list('udid') udid_developer_list = [x[0] for x in udid_developer_obj_list if len(x) > 0] udid_result_list = [device.udid for device in result] + udid_enabled_result_list = [device.udid for device in result if device.status == 'ENABLED'] + + logger.warning(f"issuer_id:{developer_obj.issuer_id} udid database info: {udid_developer_list}") + logger.warning(f"issuer_id:{developer_obj.issuer_id} udid develope info: {udid_result_list}") + logger.warning(f"issuer_id:{developer_obj.issuer_id} udid develope enable info: {udid_enabled_result_list}") will_del_udid_list = list(set(udid_developer_list) - set(udid_result_list)) + logger.warning(f"issuer_id:{developer_obj.issuer_id} udidsync will delete: {will_del_udid_list}") - udid_enabled_result_list = [device.udid for device in result if device.status == 'ENABLED'] will_del_disabled_udid_list = list(set(udid_developer_list) - set(udid_enabled_result_list)) + logger.warning(f"issuer_id:{developer_obj.issuer_id} delete and disabled: {will_del_disabled_udid_list}") for device_obj in result: obj, create = update_or_create_developer_udid_info(device_obj, developer_obj) if not create: DeveloperDevicesID.objects.filter(udid=obj, developerid=developer_obj).update( **{'did': device_obj.id}) - AppUDID.objects.filter(udid__udid__in=will_del_disabled_udid_list, - app_id__developerdevicesid__udid__in=UDIDsyncDeveloper.objects.filter( - udid__in=will_del_disabled_udid_list)).delete() + AppUDID.objects.filter(udid__udid__in=will_del_disabled_udid_list, udid__developerid=developer_obj).delete() developer_device_list = DeveloperDevicesID.objects.filter(udid__udid__in=will_del_disabled_udid_list, developerid=developer_obj).all() + app_pk_list = [] for developer_device_obj in developer_device_list: - app_obj = developer_device_obj.app_id + app_pk_list.append(developer_device_obj.app_id.pk) + developer_device_obj.delete() + + for app_pk in list(set(app_pk_list)): + app_obj = Apps.objects.filter(pk=app_pk).first() if APPSuperSignUsedInfo.objects.filter(developerid=developer_obj, app_id=app_obj).count() == 0: + logger.warning(f"issuer_id:{developer_obj.issuer_id} delete {app_obj} profile and sign ipa file") IosUtils.clean_app_by_developer_obj(app_obj, developer_obj) delete_app_to_dev_and_file(developer_obj, app_obj.pk) delete_app_profile_file(developer_obj, app_obj) - developer_device_obj.delete() UDIDsyncDeveloper.objects.filter(udid__in=will_del_udid_list, developerid=developer_obj).delete()