黄贺彬 3 meses atrás
pai
commit
561f111055

+ 1 - 1
TEAMModelOS.SDK/Models/Service/ExamService.cs

@@ -256,7 +256,7 @@ namespace TEAMModelOS.SDK.Models.Service
                         stringBuilder.Append($" and  c.createTime <= {data} ");
                     };
                 };*/
-                string periodId = string.Empty;
+              //  string periodId = string.Empty;
                 
                 if (request.TryGetProperty("name", out JsonElement name) && !string.IsNullOrWhiteSpace($"{name}"))
                 {

+ 11 - 2
TEAMModelOS.SDK/Models/Service/GroupListService.cs

@@ -13,6 +13,7 @@ using Microsoft.Extensions.Configuration;
 using System.Text.RegularExpressions;
 using TEAMModelOS.SDK.Models;
 using System.Net.Http;
+using static Microsoft.Azure.Amqp.Serialization.SerializableType;
 
 
 namespace TEAMModelOS.SDK
@@ -916,7 +917,7 @@ namespace TEAMModelOS.SDK
                         {
                             if (i == 9)
                             {
-                                string msg = $"OS,{_option.Location},school/course/upsert-list()\n 编号生成异常,重复生成次数超过10次";
+                                string msg = $"OS,{_option.Location}\n 编号生成异常,重复生成次数超过10次";
                                 await _dingDing.SendBotMsg(msg, GroupNames.醍摩豆服務運維群組);
                                 throw new Exception(msg);
                             }
@@ -1221,7 +1222,7 @@ namespace TEAMModelOS.SDK
 
 
 
-            string periodId = string.Empty;
+           // string periodId = string.Empty;
             if (classes.Count == 1 && classes.First().Equals("TeacherAll") && !string.IsNullOrEmpty(school))
             {
                 //默认的教研组
@@ -1935,6 +1936,14 @@ namespace TEAMModelOS.SDK
                         change.tcount = change.members.Where(x => x.type == 1).Count();
                         change.scount = change.members.Where(x => x.type == 2).Count();
                         GroupList group = change.ToJsonString().ToObject<GroupList>();
+                        if (group.scope.Equals("school")&& group.type.Equals("teach"))
+                        {
+                            if (string.IsNullOrWhiteSpace(group.periodId))
+                            {
+                               // list.periodId=periodIdheader;
+                                await _dingDing.SendBotMsg($"教学班学段丢失GetGroupListMemberInfo{group.ToJsonString()}", GroupNames.成都开发測試群組);
+                            }
+                        }
                         await client.GetContainer(Constant.TEAMModelOS, groupTbname).ReplaceItemAsync(group, group.id, new PartitionKey(group.code));
                     }
                 }

+ 113 - 0
TEAMModelOS/Properties/ServiceDependencies/teammodelos-yx - Web Deploy/profile.arm.json

@@ -0,0 +1,113 @@
+{
+  "$schema": "https://schema.management.azure.com/schemas/2018-05-01/subscriptionDeploymentTemplate.json#",
+  "contentVersion": "1.0.0.0",
+  "metadata": {
+    "_dependencyType": "compute.appService.windows"
+  },
+  "parameters": {
+    "resourceGroupName": {
+      "type": "string",
+      "defaultValue": "TEAMModelChengdu",
+      "metadata": {
+        "description": "Name of the resource group for the resource. It is recommended to put resources under same resource group for better tracking."
+      }
+    },
+    "resourceGroupLocation": {
+      "type": "string",
+      "defaultValue": "",
+      "metadata": {
+        "description": "Location of the resource group. Resource groups could have different location than resources, however by default we use API versions from latest hybrid profile which support all locations for resource types we support."
+      }
+    },
+    "resourceName": {
+      "type": "string",
+      "defaultValue": "yx",
+      "metadata": {
+        "description": "Name of the main resource to be created by this template."
+      }
+    },
+    "resourceLocation": {
+      "type": "string",
+      "defaultValue": "[parameters('resourceGroupLocation')]",
+      "metadata": {
+        "description": "Location of the resource. By default use resource group's location, unless the resource provider is not supported there."
+      }
+    }
+  },
+  "variables": {
+    "appServicePlan_name": "[concat('Plan', uniqueString(concat(parameters('resourceName'), subscription().subscriptionId)))]",
+    "appServicePlan_ResourceId": "[concat('/subscriptions/', subscription().subscriptionId, '/resourceGroups/', parameters('resourceGroupName'), '/providers/Microsoft.Web/serverFarms/', variables('appServicePlan_name'))]"
+  },
+  "resources": [
+    {
+      "type": "Microsoft.Resources/resourceGroups",
+      "name": "[parameters('resourceGroupName')]",
+      "location": "[parameters('resourceGroupLocation')]",
+      "apiVersion": "2019-10-01"
+    },
+    {
+      "type": "Microsoft.Resources/deployments",
+      "name": "[concat(parameters('resourceGroupName'), 'Deployment', uniqueString(concat(parameters('resourceName'), subscription().subscriptionId)))]",
+      "resourceGroup": "[parameters('resourceGroupName')]",
+      "apiVersion": "2019-10-01",
+      "dependsOn": [
+        "[parameters('resourceGroupName')]"
+      ],
+      "properties": {
+        "mode": "Incremental",
+        "template": {
+          "$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
+          "contentVersion": "1.0.0.0",
+          "resources": [
+            {
+              "location": "[parameters('resourceLocation')]",
+              "name": "[parameters('resourceName')]",
+              "type": "Microsoft.Web/sites",
+              "apiVersion": "2015-08-01",
+              "tags": {
+                "[concat('hidden-related:', variables('appServicePlan_ResourceId'))]": "empty"
+              },
+              "dependsOn": [
+                "[variables('appServicePlan_ResourceId')]"
+              ],
+              "kind": "app",
+              "properties": {
+                "name": "[parameters('resourceName')]",
+                "kind": "app",
+                "httpsOnly": true,
+                "reserved": false,
+                "serverFarmId": "[variables('appServicePlan_ResourceId')]",
+                "siteConfig": {
+                  "metadata": [
+                    {
+                      "name": "CURRENT_STACK",
+                      "value": "dotnetcore"
+                    }
+                  ]
+                }
+              },
+              "identity": {
+                "type": "SystemAssigned"
+              }
+            },
+            {
+              "location": "[parameters('resourceLocation')]",
+              "name": "[variables('appServicePlan_name')]",
+              "type": "Microsoft.Web/serverFarms",
+              "apiVersion": "2015-08-01",
+              "sku": {
+                "name": "S1",
+                "tier": "Standard",
+                "family": "S",
+                "size": "S1"
+              },
+              "properties": {
+                "name": "[variables('appServicePlan_name')]"
+              }
+            }
+          ]
+        }
+      }
+    }
+  ]
+}