This commit is contained in:
2025-12-26 17:28:45 +08:00
parent 537bdfef2b
commit a4cd51a53a
5 changed files with 40 additions and 21 deletions
+16 -16
View File
@@ -1599,23 +1599,23 @@ namespace BLL
public static string getInitialPassword(string unitId, string idCard)
{
string prefixValue = "XJYJ";
string prefixValue = "XJYJ!@#qwe";
string suffixValue = "1234";
var getUnit = UnitService.GetUnitByUnitId(unitId);
if (getUnit != null)
{
if (!string.IsNullOrEmpty(getUnit.UnitCode))
{
if (getUnit.UnitCode.Length > 4)
{
prefixValue = getUnit.UnitCode.Substring(getUnit.UnitCode.Length-4, 4);
}
else
{
prefixValue = getUnit.UnitCode;
}
}
}
//var getUnit = UnitService.GetUnitByUnitId(unitId);
//if (getUnit != null)
//{
// if (!string.IsNullOrEmpty(getUnit.UnitCode))
// {
// if (getUnit.UnitCode.Length > 4)
// {
// prefixValue = getUnit.UnitCode.Substring(getUnit.UnitCode.Length-4, 4);
// }
// else
// {
// prefixValue = getUnit.UnitCode;
// }
// }
//}
if (!string.IsNullOrEmpty(idCard))
{
if (idCard.Length > 4)