SubForm List Form Title
This commit is contained in:
parent
6e6599ba15
commit
a9a137a08c
10 changed files with 21 additions and 23 deletions
|
|
@ -5703,13 +5703,13 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"resourceName": "Platform",
|
"resourceName": "Platform",
|
||||||
"key": "App.Definitions.Bank",
|
"key": "App.Accounting.Bank",
|
||||||
"tr": "Bankalar",
|
"tr": "Bankalar",
|
||||||
"en": "Banks"
|
"en": "Banks"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"resourceName": "Platform",
|
"resourceName": "Platform",
|
||||||
"key": "App.Definitions.BankAccount",
|
"key": "App.Accounting.BankAccount",
|
||||||
"tr": "Banka Hesapları",
|
"tr": "Banka Hesapları",
|
||||||
"en": "Bank Accounts"
|
"en": "Bank Accounts"
|
||||||
},
|
},
|
||||||
|
|
@ -9810,12 +9810,6 @@
|
||||||
"tr": "Kasa",
|
"tr": "Kasa",
|
||||||
"en": "Cash"
|
"en": "Cash"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"resourceName": "Platform",
|
|
||||||
"key": "App.Accounting.Bank",
|
|
||||||
"tr": "Banka",
|
|
||||||
"en": "Bank"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"resourceName": "Platform",
|
"resourceName": "Platform",
|
||||||
"key": "App.Accounting.CheckNote",
|
"key": "App.Accounting.CheckNote",
|
||||||
|
|
|
||||||
|
|
@ -44,8 +44,10 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
|
||||||
public async Task SeedAsync(DataSeedContext context)
|
public async Task SeedAsync(DataSeedContext context)
|
||||||
{
|
{
|
||||||
using var utils = new SeederUtils();
|
using var utils = new SeederUtils();
|
||||||
|
string listFormCode = string.Empty;
|
||||||
|
|
||||||
#region Bank
|
#region Bank
|
||||||
|
listFormCode = AppCodes.Accounting.Bank;
|
||||||
if (!await _listFormRepository.AnyAsync(a => a.ListFormCode == AppCodes.Accounting.Bank))
|
if (!await _listFormRepository.AnyAsync(a => a.ListFormCode == AppCodes.Accounting.Bank))
|
||||||
{
|
{
|
||||||
var listForm = await _listFormRepository.InsertAsync(
|
var listForm = await _listFormRepository.InsertAsync(
|
||||||
|
|
@ -59,11 +61,11 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
|
||||||
ListFormCode = AppCodes.Accounting.Bank,
|
ListFormCode = AppCodes.Accounting.Bank,
|
||||||
Name = AppCodes.Accounting.Bank,
|
Name = AppCodes.Accounting.Bank,
|
||||||
Title = AppCodes.Accounting.Bank,
|
Title = AppCodes.Accounting.Bank,
|
||||||
|
Description = AppCodes.Accounting.Bank,
|
||||||
DataSourceCode = SeedConsts.DataSources.DefaultCode,
|
DataSourceCode = SeedConsts.DataSources.DefaultCode,
|
||||||
IsTenant = true,
|
IsTenant = true,
|
||||||
IsBranch = true,
|
IsBranch = true,
|
||||||
IsOrganizationUnit = false,
|
IsOrganizationUnit = false,
|
||||||
Description = AppCodes.Accounting.Bank,
|
|
||||||
SelectCommandType = SelectCommandTypeEnum.Table,
|
SelectCommandType = SelectCommandTypeEnum.Table,
|
||||||
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.Bank)),
|
SelectCommand = TableNameResolver.GetFullTableName(nameof(TableNameEnum.Bank)),
|
||||||
KeyFieldName = "Id",
|
KeyFieldName = "Id",
|
||||||
|
|
@ -493,7 +495,7 @@ public class ListFormSeeder_Accounting : IDataSeedContributor, ITransientDepende
|
||||||
AppCodes.Accounting.Bank,
|
AppCodes.Accounting.Bank,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Bank Accounts",
|
TabTitle = AppCodes.Accounting.BankAccount,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Accounting.BankAccount,
|
Code = AppCodes.Accounting.BankAccount,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -4349,7 +4349,7 @@ public class ListFormSeeder_Administration : IDataSeedContributor, ITransientDep
|
||||||
AppCodes.Definitions.SkillType,
|
AppCodes.Definitions.SkillType,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Skill Levels",
|
TabTitle = AppCodes.Definitions.SkillLevel,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Definitions.SkillLevel,
|
Code = AppCodes.Definitions.SkillLevel,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
@ -4655,7 +4655,7 @@ public class ListFormSeeder_Administration : IDataSeedContributor, ITransientDep
|
||||||
AppCodes.Definitions.UomCategory,
|
AppCodes.Definitions.UomCategory,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Uoms",
|
TabTitle = AppCodes.Definitions.Uom,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Definitions.Uom,
|
Code = AppCodes.Definitions.Uom,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -2416,7 +2416,7 @@ public class ListFormSeeder_Coordinator : IDataSeedContributor, ITransientDepend
|
||||||
AppCodes.Definitions.QuestionPool,
|
AppCodes.Definitions.QuestionPool,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Questions",
|
TabTitle = AppCodes.Definitions.Question,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Definitions.Question,
|
Code = AppCodes.Definitions.Question,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -1935,7 +1935,7 @@ public class ListFormSeeder_Crm : IDataSeedContributor, ITransientDependency
|
||||||
AppCodes.Crm.Opportunity,
|
AppCodes.Crm.Opportunity,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Activity",
|
TabTitle = AppCodes.Crm.OpportunityActivity,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Crm.OpportunityActivity,
|
Code = AppCodes.Crm.OpportunityActivity,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -4481,7 +4481,7 @@ public class ListFormSeeder_Hr : IDataSeedContributor, ITransientDependency
|
||||||
AppCodes.Hr.Survey,
|
AppCodes.Hr.Survey,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Questions",
|
TabTitle = AppCodes.Hr.SurveyQuestion,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Hr.SurveyQuestion,
|
Code = AppCodes.Hr.SurveyQuestion,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -1256,7 +1256,7 @@ public class ListFormSeeder_Maintenance : IDataSeedContributor, ITransientDepend
|
||||||
AppCodes.Maintenance.Plan,
|
AppCodes.Maintenance.Plan,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Materials",
|
TabTitle = AppCodes.Maintenance.PlanMaterial,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Maintenance.PlanMaterial,
|
Code = AppCodes.Maintenance.PlanMaterial,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -968,7 +968,7 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
|
||||||
TenantManagementPermissions.Tenants.Default,
|
TenantManagementPermissions.Tenants.Default,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Branches",
|
TabTitle = AppCodes.Branches,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Branches,
|
Code = AppCodes.Branches,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
@ -1820,7 +1820,7 @@ public class ListFormSeeder_Saas : IDataSeedContributor, ITransientDependency
|
||||||
AppCodes.Languages.Language,
|
AppCodes.Languages.Language,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Language Texts",
|
TabTitle = AppCodes.Languages.LanguageText,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.Languages.LanguageText,
|
Code = AppCodes.Languages.LanguageText,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -2353,7 +2353,7 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
|
||||||
AppCodes.SupplyChain.Supply,
|
AppCodes.SupplyChain.Supply,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Banks",
|
TabTitle = AppCodes.SupplyChain.PartnerBank,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.SupplyChain.PartnerBank,
|
Code = AppCodes.SupplyChain.PartnerBank,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
@ -2398,7 +2398,7 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
|
||||||
AppCodes.Crm.Customer,
|
AppCodes.Crm.Customer,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Banks",
|
TabTitle = AppCodes.SupplyChain.PartnerBank,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.SupplyChain.PartnerBank,
|
Code = AppCodes.SupplyChain.PartnerBank,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
@ -2768,7 +2768,7 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
|
||||||
AppCodes.SupplyChain.Approval,
|
AppCodes.SupplyChain.Approval,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Steps",
|
TabTitle = AppCodes.SupplyChain.ApprovalStep,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.SupplyChain.ApprovalStep,
|
Code = AppCodes.SupplyChain.ApprovalStep,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
@ -3374,7 +3374,7 @@ public class ListFormSeeder_SupplyChain : IDataSeedContributor, ITransientDepend
|
||||||
AppCodes.SupplyChain.Request,
|
AppCodes.SupplyChain.Request,
|
||||||
JsonSerializer.Serialize(new List<dynamic>() {
|
JsonSerializer.Serialize(new List<dynamic>() {
|
||||||
new {
|
new {
|
||||||
TabTitle = "Malzemeler",
|
TabTitle = AppCodes.SupplyChain.RequestItem,
|
||||||
TabType = ListFormTabTypeEnum.List,
|
TabType = ListFormTabTypeEnum.List,
|
||||||
Code = AppCodes.SupplyChain.RequestItem,
|
Code = AppCodes.SupplyChain.RequestItem,
|
||||||
Relation = new List<dynamic>() {
|
Relation = new List<dynamic>() {
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,7 @@ import { GridDto, SubFormDto, SubFormTabTypeEnum } from '@/proxy/form/models'
|
||||||
import FormEdit from './FormEdit'
|
import FormEdit from './FormEdit'
|
||||||
import FormNew from './FormNew'
|
import FormNew from './FormNew'
|
||||||
import FormView from './FormView'
|
import FormView from './FormView'
|
||||||
|
import { useLocalization } from '@/utils/hooks/useLocalization'
|
||||||
|
|
||||||
const SubForms = (props: {
|
const SubForms = (props: {
|
||||||
gridDto: GridDto
|
gridDto: GridDto
|
||||||
|
|
@ -24,6 +25,7 @@ const SubForms = (props: {
|
||||||
const [currentTab, setCurrentTab] = useState<string>()
|
const [currentTab, setCurrentTab] = useState<string>()
|
||||||
const [subForms, setSubForms] = useState<SubFormDto[]>()
|
const [subForms, setSubForms] = useState<SubFormDto[]>()
|
||||||
const navigate = useNavigate()
|
const navigate = useNavigate()
|
||||||
|
const { translate } = useLocalization()
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (hash && level === 0) {
|
if (hash && level === 0) {
|
||||||
|
|
@ -89,7 +91,7 @@ const SubForms = (props: {
|
||||||
value={subForm.code}
|
value={subForm.code}
|
||||||
icon={subForm.tabType == SubFormTabTypeEnum.List ? <FaList /> : <FaChartBar />}
|
icon={subForm.tabType == SubFormTabTypeEnum.List ? <FaList /> : <FaChartBar />}
|
||||||
>
|
>
|
||||||
{subForm.tabTitle}
|
{translate('::' + subForm.tabTitle)}
|
||||||
</TabNav>
|
</TabNav>
|
||||||
)
|
)
|
||||||
})}
|
})}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue