people tags #387
This commit is contained in:
parent
dfe514c55e
commit
3493225dc5
@ -34,6 +34,9 @@
|
|||||||
case PersonAffiliationType.Successor: return "جانشین";
|
case PersonAffiliationType.Successor: return "جانشین";
|
||||||
case PersonAffiliationType.Panegyrized: return "مدحگو";
|
case PersonAffiliationType.Panegyrized: return "مدحگو";
|
||||||
case PersonAffiliationType.Satirized: return "هجوگو";
|
case PersonAffiliationType.Satirized: return "هجوگو";
|
||||||
|
case PersonAffiliationType.MilitaryCommander: return "سردار";
|
||||||
|
case PersonAffiliationType.Champion: return "پهلوان";
|
||||||
|
case PersonAffiliationType.Contemporary: return "همعصر";
|
||||||
case PersonAffiliationType.Other: return "نوع دیگر";
|
case PersonAffiliationType.Other: return "نوع دیگر";
|
||||||
default: return t.ToString();
|
default: return t.ToString();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -264,6 +264,9 @@
|
|||||||
'<option value="Rival">رقیب</option>' +
|
'<option value="Rival">رقیب</option>' +
|
||||||
'<option value="Panegyrized">مدحگو (طرف اول، طرف دوم را مدح کرده)</option>' +
|
'<option value="Panegyrized">مدحگو (طرف اول، طرف دوم را مدح کرده)</option>' +
|
||||||
'<option value="Satirized">هجوگو (طرف اول، طرف دوم را هجو کرده)</option>' +
|
'<option value="Satirized">هجوگو (طرف اول، طرف دوم را هجو کرده)</option>' +
|
||||||
|
'<option value="MilitaryCommander">سردار</option>' +
|
||||||
|
'<option value="Champion">پهلوان</option>' +
|
||||||
|
'<option value="Contemporary">همعصر (بدون نسبت دیگر)</option>' +
|
||||||
'<option value="Other">سایر</option>' +
|
'<option value="Other">سایر</option>' +
|
||||||
'</select>' +
|
'</select>' +
|
||||||
'</div>' +
|
'</div>' +
|
||||||
@ -378,6 +381,9 @@
|
|||||||
Ally: function (p1, p2) { return p1 + ' و ' + p2 + ' متحد هم هستند.'; },
|
Ally: function (p1, p2) { return p1 + ' و ' + p2 + ' متحد هم هستند.'; },
|
||||||
Rival: function (p1, p2) { return p1 + ' و ' + p2 + ' رقیب هم هستند.'; },
|
Rival: function (p1, p2) { return p1 + ' و ' + p2 + ' رقیب هم هستند.'; },
|
||||||
Companion: function (p1, p2) { return p1 + ' و ' + p2 + ' همراه هم هستند.'; },
|
Companion: function (p1, p2) { return p1 + ' و ' + p2 + ' همراه هم هستند.'; },
|
||||||
|
MilitaryCommander: function (p1, p2) { return p1 + ' سردار ' + p2 + ' است.'; },
|
||||||
|
Champion: function (p1, p2) { return p1 + ' پهلوان ' + p2 + ' است.'; },
|
||||||
|
Contemporary: function (p1, p2) { return p1 + ' و ' + p2 + ' همعصر هم هستند.'; },
|
||||||
Other: function (p1, p2) { return p1 + ' با ' + p2 + ' نسبتی دارد (طبق یادداشت).'; }
|
Other: function (p1, p2) { return p1 + ' با ' + p2 + ' نسبتی دارد (طبق یادداشت).'; }
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -98,9 +98,14 @@ else
|
|||||||
<option value="Panegyrized_Subject">این نامبرده در شعری او را مدح/ستایش کرد (مدحگوی او بود)</option>
|
<option value="Panegyrized_Subject">این نامبرده در شعری او را مدح/ستایش کرد (مدحگوی او بود)</option>
|
||||||
<option value="Satirized_Other">او در شعری این نامبرده را هجو کرد (هجوگوی او بود)</option>
|
<option value="Satirized_Other">او در شعری این نامبرده را هجو کرد (هجوگوی او بود)</option>
|
||||||
<option value="Satirized_Subject">این نامبرده در شعری او را هجو کرد (هجوگوی او بود)</option>
|
<option value="Satirized_Subject">این نامبرده در شعری او را هجو کرد (هجوگوی او بود)</option>
|
||||||
|
<option value="MilitaryCommander_Other">او سردار این نامبرده بود</option>
|
||||||
|
<option value="MilitaryCommander_Subject">این نامبرده سردار او بود</option>
|
||||||
|
<option value="Champion_Other">او پهلوان این نامبرده بود</option>
|
||||||
|
<option value="Champion_Subject">این نامبرده پهلوان او بود</option>
|
||||||
<option value="Ally">با او متحد/همپیمان بود</option>
|
<option value="Ally">با او متحد/همپیمان بود</option>
|
||||||
<option value="Rival">با او رقیب/دشمن بود</option>
|
<option value="Rival">با او رقیب/دشمن بود</option>
|
||||||
<option value="Companion">با او همراه/همدم بود</option>
|
<option value="Companion">با او همراه/همدم بود</option>
|
||||||
|
<option value="Contemporary">همعصر او بود (بدون نسبت دیگر)</option>
|
||||||
<option value="Other">نوع دیگر (در یادداشت توضیح دهید)</option>
|
<option value="Other">نوع دیگر (در یادداشت توضیح دهید)</option>
|
||||||
</select>
|
</select>
|
||||||
</td>
|
</td>
|
||||||
|
|||||||
@ -147,10 +147,10 @@ namespace GanjooRazor.Areas.User.Pages
|
|||||||
|
|
||||||
// OtherIsPerson1/SubjectIsPerson1 pairs translate the direction-aware choice into the
|
// OtherIsPerson1/SubjectIsPerson1 pairs translate the direction-aware choice into the
|
||||||
// symmetric Person1Id/Person2Id pair, following the direction each PersonAffiliationType
|
// symmetric Person1Id/Person2Id pair, following the direction each PersonAffiliationType
|
||||||
// value's own doc comment defines (Minister/Advisor/Courtier/Servant: Person1 is the
|
// value's own doc comment defines (Minister/Advisor/Courtier/Servant/MilitaryCommander/
|
||||||
// subordinate one; Patron/Successor: Person1 is the patron/later one; Panegyrized/
|
// Champion: Person1 is the subordinate one; Patron/Successor: Person1 is the
|
||||||
// Satirized: Person1 is the poet; Ally/Rival/Companion/Other: symmetric, direction
|
// patron/later one; Panegyrized/Satirized: Person1 is the poet; Ally/Rival/Companion/
|
||||||
// doesn't matter)
|
// Contemporary/Other: symmetric, direction doesn't matter)
|
||||||
switch (AffiliationKind)
|
switch (AffiliationKind)
|
||||||
{
|
{
|
||||||
case "Minister_Other": // the other person served as minister to this one
|
case "Minister_Other": // the other person served as minister to this one
|
||||||
@ -233,6 +233,26 @@ namespace GanjooRazor.Areas.User.Pages
|
|||||||
suggestion.Person2Id = OtherPersonId;
|
suggestion.Person2Id = OtherPersonId;
|
||||||
suggestion.SuggestedAffiliationType = PersonAffiliationType.Satirized;
|
suggestion.SuggestedAffiliationType = PersonAffiliationType.Satirized;
|
||||||
break;
|
break;
|
||||||
|
case "MilitaryCommander_Other": // the other person served as military commander (سردار) to this one
|
||||||
|
suggestion.Person1Id = OtherPersonId;
|
||||||
|
suggestion.Person2Id = personId;
|
||||||
|
suggestion.SuggestedAffiliationType = PersonAffiliationType.MilitaryCommander;
|
||||||
|
break;
|
||||||
|
case "MilitaryCommander_Subject": // this person served as military commander (سردار) to the other one
|
||||||
|
suggestion.Person1Id = personId;
|
||||||
|
suggestion.Person2Id = OtherPersonId;
|
||||||
|
suggestion.SuggestedAffiliationType = PersonAffiliationType.MilitaryCommander;
|
||||||
|
break;
|
||||||
|
case "Champion_Other": // the other person was champion/warrior (پهلوان) to this one
|
||||||
|
suggestion.Person1Id = OtherPersonId;
|
||||||
|
suggestion.Person2Id = personId;
|
||||||
|
suggestion.SuggestedAffiliationType = PersonAffiliationType.Champion;
|
||||||
|
break;
|
||||||
|
case "Champion_Subject": // this person was champion/warrior (پهلوان) to the other one
|
||||||
|
suggestion.Person1Id = personId;
|
||||||
|
suggestion.Person2Id = OtherPersonId;
|
||||||
|
suggestion.SuggestedAffiliationType = PersonAffiliationType.Champion;
|
||||||
|
break;
|
||||||
case "Ally":
|
case "Ally":
|
||||||
suggestion.Person1Id = personId;
|
suggestion.Person1Id = personId;
|
||||||
suggestion.Person2Id = OtherPersonId;
|
suggestion.Person2Id = OtherPersonId;
|
||||||
@ -248,6 +268,11 @@ namespace GanjooRazor.Areas.User.Pages
|
|||||||
suggestion.Person2Id = OtherPersonId;
|
suggestion.Person2Id = OtherPersonId;
|
||||||
suggestion.SuggestedAffiliationType = PersonAffiliationType.Companion;
|
suggestion.SuggestedAffiliationType = PersonAffiliationType.Companion;
|
||||||
break;
|
break;
|
||||||
|
case "Contemporary": // symmetric - no other relationship implied, just overlapping lifetimes
|
||||||
|
suggestion.Person1Id = personId;
|
||||||
|
suggestion.Person2Id = OtherPersonId;
|
||||||
|
suggestion.SuggestedAffiliationType = PersonAffiliationType.Contemporary;
|
||||||
|
break;
|
||||||
case "Other":
|
case "Other":
|
||||||
suggestion.Person1Id = personId;
|
suggestion.Person1Id = personId;
|
||||||
suggestion.Person2Id = OtherPersonId;
|
suggestion.Person2Id = OtherPersonId;
|
||||||
|
|||||||
@ -66,9 +66,12 @@ else
|
|||||||
<option value="@((int)PersonAffiliationType.Successor)">جانشین (طرف اول، جانشین طرف دوم است)</option>
|
<option value="@((int)PersonAffiliationType.Successor)">جانشین (طرف اول، جانشین طرف دوم است)</option>
|
||||||
<option value="@((int)PersonAffiliationType.Panegyrized)">مدحگو (طرف اول، طرف دوم را مدح کرده است)</option>
|
<option value="@((int)PersonAffiliationType.Panegyrized)">مدحگو (طرف اول، طرف دوم را مدح کرده است)</option>
|
||||||
<option value="@((int)PersonAffiliationType.Satirized)">هجوگو (طرف اول، طرف دوم را هجو کرده است)</option>
|
<option value="@((int)PersonAffiliationType.Satirized)">هجوگو (طرف اول، طرف دوم را هجو کرده است)</option>
|
||||||
|
<option value="@((int)PersonAffiliationType.MilitaryCommander)">سردار (طرف اول، سردار طرف دوم بوده است)</option>
|
||||||
|
<option value="@((int)PersonAffiliationType.Champion)">پهلوان (طرف اول، پهلوان طرف دوم بوده است)</option>
|
||||||
<option value="@((int)PersonAffiliationType.Ally)">متحد/همپیمان</option>
|
<option value="@((int)PersonAffiliationType.Ally)">متحد/همپیمان</option>
|
||||||
<option value="@((int)PersonAffiliationType.Rival)">رقیب/دشمن</option>
|
<option value="@((int)PersonAffiliationType.Rival)">رقیب/دشمن</option>
|
||||||
<option value="@((int)PersonAffiliationType.Companion)">همراه/همدم</option>
|
<option value="@((int)PersonAffiliationType.Companion)">همراه/همدم</option>
|
||||||
|
<option value="@((int)PersonAffiliationType.Contemporary)">همعصر (بدون نسبت دیگر)</option>
|
||||||
<option value="@((int)PersonAffiliationType.Other)">نوع دیگر (در یادداشت توضیح دهید)</option>
|
<option value="@((int)PersonAffiliationType.Other)">نوع دیگر (در یادداشت توضیح دهید)</option>
|
||||||
</select>
|
</select>
|
||||||
<p class="up-hint"><small>جهت وابستگی (کدام طرف زیردست/حامی/... است) قابل تغییر نیست؛ در صورت اشتباه بودن جهت، این وابستگی را حذف و یکی تازه پیشنهاد کنید.</small></p>
|
<p class="up-hint"><small>جهت وابستگی (کدام طرف زیردست/حامی/... است) قابل تغییر نیست؛ در صورت اشتباه بودن جهت، این وابستگی را حذف و یکی تازه پیشنهاد کنید.</small></p>
|
||||||
|
|||||||
@ -115,12 +115,16 @@ namespace GanjooRazor.Pages
|
|||||||
{ PersonAffiliationType.Successor, "جانشینِ" },
|
{ PersonAffiliationType.Successor, "جانشینِ" },
|
||||||
{ PersonAffiliationType.Panegyrized, "مدحگویِ" },
|
{ PersonAffiliationType.Panegyrized, "مدحگویِ" },
|
||||||
{ PersonAffiliationType.Satirized, "هجوگویِ" },
|
{ PersonAffiliationType.Satirized, "هجوگویِ" },
|
||||||
|
{ PersonAffiliationType.MilitaryCommander, "سردارِ" },
|
||||||
|
{ PersonAffiliationType.Champion, "پهلوانِ" },
|
||||||
|
{ PersonAffiliationType.Contemporary, "همعصرِ" },
|
||||||
{ PersonAffiliationType.Other, "دارای نسبتی (به یادداشت نگاه کنید) با" },
|
{ PersonAffiliationType.Other, "دارای نسبتی (به یادداشت نگاه کنید) با" },
|
||||||
};
|
};
|
||||||
|
|
||||||
private static bool IsSymmetricAffiliation(PersonAffiliationType t) =>
|
private static bool IsSymmetricAffiliation(PersonAffiliationType t) =>
|
||||||
t == PersonAffiliationType.Ally || t == PersonAffiliationType.Rival ||
|
t == PersonAffiliationType.Ally || t == PersonAffiliationType.Rival ||
|
||||||
t == PersonAffiliationType.Companion || t == PersonAffiliationType.Other;
|
t == PersonAffiliationType.Companion || t == PersonAffiliationType.Contemporary ||
|
||||||
|
t == PersonAffiliationType.Other;
|
||||||
|
|
||||||
public async Task<IActionResult> OnGetAsync(int id)
|
public async Task<IActionResult> OnGetAsync(int id)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -8,7 +8,8 @@
|
|||||||
// person2Id, person2Name, category, typeValue, degreeHint, note}] } where category is
|
// person2Id, person2Name, category, typeValue, degreeHint, note}] } where category is
|
||||||
// "Relation" (typeValue is PersonRelationType: 0=Parent,1=Sibling,2=Spouse,3=Ancestor) or
|
// "Relation" (typeValue is PersonRelationType: 0=Parent,1=Sibling,2=Spouse,3=Ancestor) or
|
||||||
// "Affiliation" (typeValue is PersonAffiliationType: 0=Minister,1=Advisor,2=Courtier,3=Patron,
|
// "Affiliation" (typeValue is PersonAffiliationType: 0=Minister,1=Advisor,2=Courtier,3=Patron,
|
||||||
// 4=Ally,5=Rival,6=Servant,7=Companion,8=Successor,9=Panegyrized,10=Satirized,99=Other). directlyTagged is false only on
|
// 4=Ally,5=Rival,6=Servant,7=Companion,8=Successor,9=Panegyrized,10=Satirized,11=MilitaryCommander,
|
||||||
|
// 12=Champion,13=Contemporary,99=Other). directlyTagged is false only on
|
||||||
// the category-scoped graph (GET api/ganjoor/cat/{id}/persongraph, the "characters in this work"
|
// the category-scoped graph (GET api/ganjoor/cat/{id}/persongraph, the "characters in this work"
|
||||||
// tab): such a node was pulled in as a one-hop relative/affiliate of someone actually named in the
|
// tab): such a node was pulled in as a one-hop relative/affiliate of someone actually named in the
|
||||||
// work's verses, and is never false on the whole-site graph fed by PeopleExplorer.cshtml. importance
|
// work's verses, and is never false on the whole-site graph fed by PeopleExplorer.cshtml. importance
|
||||||
|
|||||||
@ -70,6 +70,32 @@ namespace RMuseum.Models.Ganjoor
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
Satirized = 10,
|
Satirized = 10,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Person1 served as a military commander/general (سردار) under Person2 - directional, same
|
||||||
|
/// subordinate-side convention as Minister/Advisor/Courtier, but deliberately kept separate
|
||||||
|
/// from Courtier: a سردار's tie to Person2 is a military command relationship, not a court
|
||||||
|
/// role, and (unlike e.g. Minister, which implies one standing appointment) doesn't imply the
|
||||||
|
/// tie held continuously - a commander could serve across campaigns/kings, with specifics
|
||||||
|
/// (which campaign, how long) left to Note
|
||||||
|
/// </summary>
|
||||||
|
MilitaryCommander = 11,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Person1 was a champion/legendary warrior (پهلوان) associated with Person2 - directional,
|
||||||
|
/// same subordinate-side convention as MilitaryCommander, but distinct from it: a پهلوان's
|
||||||
|
/// standing comes from individual prowess/heroism (e.g. Rostam), not from holding a command
|
||||||
|
/// post, and like MilitaryCommander this doesn't imply a permanent/continuous tie
|
||||||
|
/// </summary>
|
||||||
|
Champion = 12,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Person1 and Person2 lived in the same era (همعصر), with no other relationship between
|
||||||
|
/// them necessarily known/implied - symmetric (order doesn't matter). Unlike every other
|
||||||
|
/// value here, this doesn't assert any kind of tie or interaction, only overlapping lifetimes;
|
||||||
|
/// use one of the other types instead whenever an actual relationship is known
|
||||||
|
/// </summary>
|
||||||
|
Contemporary = 13,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// doesn't fit any of the above - rely on Note for what the tie actually is
|
/// doesn't fit any of the above - rely on Note for what the tie actually is
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@ -11926,6 +11926,32 @@
|
|||||||
the satire's target) - directional, same convention as Minister/Patron
|
the satire's target) - directional, same convention as Minister/Patron
|
||||||
</summary>
|
</summary>
|
||||||
</member>
|
</member>
|
||||||
|
<member name="F:RMuseum.Models.Ganjoor.PersonAffiliationType.MilitaryCommander">
|
||||||
|
<summary>
|
||||||
|
Person1 served as a military commander/general (سردار) under Person2 - directional, same
|
||||||
|
subordinate-side convention as Minister/Advisor/Courtier, but deliberately kept separate
|
||||||
|
from Courtier: a سردار's tie to Person2 is a military command relationship, not a court
|
||||||
|
role, and (unlike e.g. Minister, which implies one standing appointment) doesn't imply the
|
||||||
|
tie held continuously - a commander could serve across campaigns/kings, with specifics
|
||||||
|
(which campaign, how long) left to Note
|
||||||
|
</summary>
|
||||||
|
</member>
|
||||||
|
<member name="F:RMuseum.Models.Ganjoor.PersonAffiliationType.Champion">
|
||||||
|
<summary>
|
||||||
|
Person1 was a champion/legendary warrior (پهلوان) associated with Person2 - directional,
|
||||||
|
same subordinate-side convention as MilitaryCommander, but distinct from it: a پهلوان's
|
||||||
|
standing comes from individual prowess/heroism (e.g. Rostam), not from holding a command
|
||||||
|
post, and like MilitaryCommander this doesn't imply a permanent/continuous tie
|
||||||
|
</summary>
|
||||||
|
</member>
|
||||||
|
<member name="F:RMuseum.Models.Ganjoor.PersonAffiliationType.Contemporary">
|
||||||
|
<summary>
|
||||||
|
Person1 and Person2 lived in the same era (همعصر), with no other relationship between
|
||||||
|
them necessarily known/implied - symmetric (order doesn't matter). Unlike every other
|
||||||
|
value here, this doesn't assert any kind of tie or interaction, only overlapping lifetimes;
|
||||||
|
use one of the other types instead whenever an actual relationship is known
|
||||||
|
</summary>
|
||||||
|
</member>
|
||||||
<member name="F:RMuseum.Models.Ganjoor.PersonAffiliationType.Other">
|
<member name="F:RMuseum.Models.Ganjoor.PersonAffiliationType.Other">
|
||||||
<summary>
|
<summary>
|
||||||
doesn't fit any of the above - rely on Note for what the tie actually is
|
doesn't fit any of the above - rely on Note for what the tie actually is
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user