37 changed files with 1850 additions and 0 deletions
@ -0,0 +1,18 @@ |
|||
@page |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote.CreateModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="CreateModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["CreateStoreReceiptAbnormalNote"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,27 @@ |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNote; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNote.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote; |
|||
|
|||
public class CreateModalModel : WmsPageModel |
|||
{ |
|||
[BindProperty] |
|||
public CreateEditStoreReceiptAbnormalNoteViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreReceiptAbnormalNoteAppService _service; |
|||
|
|||
public CreateModalModel(IStoreReceiptAbnormalNoteAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreReceiptAbnormalNoteViewModel, CreateUpdateStoreReceiptAbnormalNoteDto>(ViewModel); |
|||
await _service.CreateAsync(dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,19 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote.EditModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="EditModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["EditStoreReceiptAbnormalNote"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-input asp-for="Id" /> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,38 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNote; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNote.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote; |
|||
|
|||
public class EditModalModel : WmsPageModel |
|||
{ |
|||
[HiddenInput] |
|||
[BindProperty(SupportsGet = true)] |
|||
public Guid Id { get; set; } |
|||
|
|||
[BindProperty] |
|||
public CreateEditStoreReceiptAbnormalNoteViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreReceiptAbnormalNoteAppService _service; |
|||
|
|||
public EditModalModel(IStoreReceiptAbnormalNoteAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
var dto = await _service.GetAsync(Id); |
|||
ViewModel = ObjectMapper.Map<StoreReceiptAbnormalNoteDto, CreateEditStoreReceiptAbnormalNoteViewModel>(dto); |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreReceiptAbnormalNoteViewModel, CreateUpdateStoreReceiptAbnormalNoteDto>(ViewModel); |
|||
await _service.UpdateAsync(Id, dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,57 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Permissions |
|||
@using Microsoft.AspNetCore.Authorization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Layout |
|||
@using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using WinIn.FasterZ.Wms.Web.Menus |
|||
@model IndexModel |
|||
@inject IPageLayout PageLayout |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@inject IAuthorizationService Authorization |
|||
@{ |
|||
PageLayout.Content.Title = L["StoreReceiptAbnormalNote"].Value; |
|||
PageLayout.Content.BreadCrumb.Add(L["Menu:StoreReceiptAbnormalNote"].Value); |
|||
PageLayout.Content.MenuItemName = WmsMenus.StoreReceiptAbnormalNote; |
|||
} |
|||
|
|||
@section scripts |
|||
{ |
|||
<abp-script src="/Pages/Z_Business/StoreReceiptAbnormalNote/StoreReceiptAbnormalNote/index.js" /> |
|||
} |
|||
@section styles |
|||
{ |
|||
<abp-style src="/Pages/Z_Business/StoreReceiptAbnormalNote/StoreReceiptAbnormalNote/index.css"/> |
|||
} |
|||
|
|||
<abp-card> |
|||
<abp-card-header> |
|||
<abp-row> |
|||
<abp-column size-md="_6"> |
|||
<abp-card-title>@L["StoreReceiptAbnormalNote"]</abp-card-title> |
|||
</abp-column> |
|||
<abp-column size-md="_6" class="text-end"> |
|||
@if (await Authorization.IsGrantedAsync(WmsPermissions.StoreReceiptAbnormalNote.Create)) |
|||
{ |
|||
<abp-button id="NewStoreReceiptAbnormalNoteButton" |
|||
text="@L["CreateStoreReceiptAbnormalNote"].Value" |
|||
icon="plus" |
|||
button-type="Primary" /> |
|||
} |
|||
</abp-column> |
|||
</abp-row> |
|||
</abp-card-header> |
|||
<abp-card-body> |
|||
<abp-row class="mb-3"> |
|||
<a abp-collapse-id="StoreReceiptAbnormalNoteCollapse" class="text-secondary">@L["TableFilter"] </a> |
|||
</abp-row> |
|||
<abp-dynamic-form abp-model="StoreReceiptAbnormalNoteFilter" id="StoreReceiptAbnormalNoteFilter" required-symbols="false" column-size="_3"> |
|||
<abp-collapse-body id="StoreReceiptAbnormalNoteCollapse"> |
|||
<abp-form-content /> |
|||
</abp-collapse-body> |
|||
</abp-dynamic-form> |
|||
<hr /> |
|||
<abp-table striped-rows="true" id="StoreReceiptAbnormalNoteTable" class="nowrap"/> |
|||
</abp-card-body> |
|||
</abp-card> |
@ -0,0 +1,51 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using System.ComponentModel.DataAnnotations; |
|||
using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Form; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote; |
|||
|
|||
public class IndexModel : WmsPageModel |
|||
{ |
|||
public StoreReceiptAbnormalNoteFilterInput StoreReceiptAbnormalNoteFilter { get; set; } |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
await Task.CompletedTask; |
|||
} |
|||
} |
|||
|
|||
public class StoreReceiptAbnormalNoteFilterInput |
|||
{ |
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteActiveDate")] |
|||
public DateTime? ActiveDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteAsnNumber")] |
|||
public string? AsnNumber { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteNumber")] |
|||
public string? Number { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteReceiptNumber")] |
|||
public string? ReceiptNumber { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteStoreReceiptAbnormalNoteDetails")] |
|||
public ICollection<StoreReceiptAbnormalNoteDetail>? StoreReceiptAbnormalNoteDetails { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteSupplierCode")] |
|||
public string? SupplierCode { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteWorker")] |
|||
public string? Worker { get; set; } |
|||
} |
@ -0,0 +1,31 @@ |
|||
using System; |
|||
using System.ComponentModel.DataAnnotations; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNote.StoreReceiptAbnormalNote.ViewModels; |
|||
|
|||
public class CreateEditStoreReceiptAbnormalNoteViewModel |
|||
{ |
|||
[Display(Name = "StoreReceiptAbnormalNoteActiveDate")] |
|||
public DateTime ActiveDate { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteAsnNumber")] |
|||
public string AsnNumber { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteNumber")] |
|||
public string Number { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteReceiptNumber")] |
|||
public string ReceiptNumber { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteStoreReceiptAbnormalNoteDetails")] |
|||
public ICollection<StoreReceiptAbnormalNoteDetail> StoreReceiptAbnormalNoteDetails { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteSupplierCode")] |
|||
public string SupplierCode { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteWorker")] |
|||
public string? Worker { get; set; } |
|||
} |
@ -0,0 +1,113 @@ |
|||
$(function () { |
|||
|
|||
$("#StoreReceiptAbnormalNoteFilter :input").on('input', function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
//After abp v7.2 use dynamicForm 'column-size' instead of the following settings
|
|||
//$('#StoreReceiptAbnormalNoteCollapse div').addClass('col-sm-3').parent().addClass('row');
|
|||
|
|||
var getFilter = function () { |
|||
var input = {}; |
|||
$("#StoreReceiptAbnormalNoteFilter") |
|||
.serializeArray() |
|||
.forEach(function (data) { |
|||
if (data.value != '') { |
|||
input[abp.utils.toCamelCase(data.name.replace(/StoreReceiptAbnormalNoteFilter./g, ''))] = data.value; |
|||
} |
|||
}) |
|||
return input; |
|||
}; |
|||
|
|||
var l = abp.localization.getResource('Wms'); |
|||
|
|||
var service = winIn.fasterZ.wms.z_Business.storeReceiptAbnormalNote.storeReceiptAbnormalNote; |
|||
var createModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreReceiptAbnormalNote/StoreReceiptAbnormalNote/CreateModal'); |
|||
var editModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreReceiptAbnormalNote/StoreReceiptAbnormalNote/EditModal'); |
|||
|
|||
var dataTable = $('#StoreReceiptAbnormalNoteTable').DataTable(abp.libs.datatables.normalizeConfiguration({ |
|||
processing: true, |
|||
serverSide: true, |
|||
paging: true, |
|||
searching: false,//disable default searchbox
|
|||
autoWidth: false, |
|||
scrollCollapse: true, |
|||
order: [[0, "asc"]], |
|||
ajax: abp.libs.datatables.createAjax(service.getList,getFilter), |
|||
columnDefs: [ |
|||
{ |
|||
rowAction: { |
|||
items: |
|||
[ |
|||
{ |
|||
text: l('Edit'), |
|||
visible: abp.auth.isGranted('Wms.StoreReceiptAbnormalNote.Update'), |
|||
action: function (data) { |
|||
editModal.open({ id: data.record.id }); |
|||
} |
|||
}, |
|||
{ |
|||
text: l('Delete'), |
|||
visible: abp.auth.isGranted('Wms.StoreReceiptAbnormalNote.Delete'), |
|||
confirmMessage: function (data) { |
|||
return l('StoreReceiptAbnormalNoteDeletionConfirmationMessage', data.record.id); |
|||
}, |
|||
action: function (data) { |
|||
service.delete(data.record.id) |
|||
.then(function () { |
|||
abp.notify.info(l('SuccessfullyDeleted')); |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
} |
|||
} |
|||
] |
|||
} |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteActiveDate'), |
|||
data: "activeDate" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteAsnNumber'), |
|||
data: "asnNumber" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteNumber'), |
|||
data: "number" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteReceiptNumber'), |
|||
data: "receiptNumber" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteRemark'), |
|||
data: "remark" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteStoreReceiptAbnormalNoteDetails'), |
|||
data: "storeReceiptAbnormalNoteDetails" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteSupplierCode'), |
|||
data: "supplierCode" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteWorker'), |
|||
data: "worker" |
|||
}, |
|||
] |
|||
})); |
|||
|
|||
createModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
editModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
$('#NewStoreReceiptAbnormalNoteButton').click(function (e) { |
|||
e.preventDefault(); |
|||
createModal.open(); |
|||
}); |
|||
}); |
@ -0,0 +1,18 @@ |
|||
@page |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail.CreateModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="CreateModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["CreateStoreReceiptAbnormalNoteDetail"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,27 @@ |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNoteDetail; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNoteDetail.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail; |
|||
|
|||
public class CreateModalModel : WmsPageModel |
|||
{ |
|||
[BindProperty] |
|||
public CreateEditStoreReceiptAbnormalNoteDetailViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreReceiptAbnormalNoteDetailAppService _service; |
|||
|
|||
public CreateModalModel(IStoreReceiptAbnormalNoteDetailAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreReceiptAbnormalNoteDetailViewModel, CreateUpdateStoreReceiptAbnormalNoteDetailDto>(ViewModel); |
|||
await _service.CreateAsync(dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,19 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail.EditModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="EditModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["EditStoreReceiptAbnormalNoteDetail"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-input asp-for="Id" /> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,38 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNoteDetail; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreReceiptAbnormalNoteDetail.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail; |
|||
|
|||
public class EditModalModel : WmsPageModel |
|||
{ |
|||
[HiddenInput] |
|||
[BindProperty(SupportsGet = true)] |
|||
public Guid Id { get; set; } |
|||
|
|||
[BindProperty] |
|||
public CreateEditStoreReceiptAbnormalNoteDetailViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreReceiptAbnormalNoteDetailAppService _service; |
|||
|
|||
public EditModalModel(IStoreReceiptAbnormalNoteDetailAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
var dto = await _service.GetAsync(Id); |
|||
ViewModel = ObjectMapper.Map<StoreReceiptAbnormalNoteDetailDto, CreateEditStoreReceiptAbnormalNoteDetailViewModel>(dto); |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreReceiptAbnormalNoteDetailViewModel, CreateUpdateStoreReceiptAbnormalNoteDetailDto>(ViewModel); |
|||
await _service.UpdateAsync(Id, dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,57 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Permissions |
|||
@using Microsoft.AspNetCore.Authorization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Layout |
|||
@using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using WinIn.FasterZ.Wms.Web.Menus |
|||
@model IndexModel |
|||
@inject IPageLayout PageLayout |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@inject IAuthorizationService Authorization |
|||
@{ |
|||
PageLayout.Content.Title = L["StoreReceiptAbnormalNoteDetail"].Value; |
|||
PageLayout.Content.BreadCrumb.Add(L["Menu:StoreReceiptAbnormalNoteDetail"].Value); |
|||
PageLayout.Content.MenuItemName = WmsMenus.StoreReceiptAbnormalNoteDetail; |
|||
} |
|||
|
|||
@section scripts |
|||
{ |
|||
<abp-script src="/Pages/Z_Business/StoreReceiptAbnormalNoteDetail/StoreReceiptAbnormalNoteDetail/index.js" /> |
|||
} |
|||
@section styles |
|||
{ |
|||
<abp-style src="/Pages/Z_Business/StoreReceiptAbnormalNoteDetail/StoreReceiptAbnormalNoteDetail/index.css"/> |
|||
} |
|||
|
|||
<abp-card> |
|||
<abp-card-header> |
|||
<abp-row> |
|||
<abp-column size-md="_6"> |
|||
<abp-card-title>@L["StoreReceiptAbnormalNoteDetail"]</abp-card-title> |
|||
</abp-column> |
|||
<abp-column size-md="_6" class="text-end"> |
|||
@if (await Authorization.IsGrantedAsync(WmsPermissions.StoreReceiptAbnormalNoteDetail.Create)) |
|||
{ |
|||
<abp-button id="NewStoreReceiptAbnormalNoteDetailButton" |
|||
text="@L["CreateStoreReceiptAbnormalNoteDetail"].Value" |
|||
icon="plus" |
|||
button-type="Primary" /> |
|||
} |
|||
</abp-column> |
|||
</abp-row> |
|||
</abp-card-header> |
|||
<abp-card-body> |
|||
<abp-row class="mb-3"> |
|||
<a abp-collapse-id="StoreReceiptAbnormalNoteDetailCollapse" class="text-secondary">@L["TableFilter"] </a> |
|||
</abp-row> |
|||
<abp-dynamic-form abp-model="StoreReceiptAbnormalNoteDetailFilter" id="StoreReceiptAbnormalNoteDetailFilter" required-symbols="false" column-size="_3"> |
|||
<abp-collapse-body id="StoreReceiptAbnormalNoteDetailCollapse"> |
|||
<abp-form-content /> |
|||
</abp-collapse-body> |
|||
</abp-dynamic-form> |
|||
<hr /> |
|||
<abp-table striped-rows="true" id="StoreReceiptAbnormalNoteDetailTable" class="nowrap"/> |
|||
</abp-card-body> |
|||
</abp-card> |
@ -0,0 +1,127 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using System.ComponentModel.DataAnnotations; |
|||
using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Form; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail; |
|||
|
|||
public class IndexModel : WmsPageModel |
|||
{ |
|||
public StoreReceiptAbnormalNoteDetailFilterInput StoreReceiptAbnormalNoteDetailFilter { get; set; } |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
await Task.CompletedTask; |
|||
} |
|||
} |
|||
|
|||
public class StoreReceiptAbnormalNoteDetailFilterInput |
|||
{ |
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailAbnormalType")] |
|||
public string? AbnormalType { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailArriveDate")] |
|||
public DateTime? ArriveDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailContainerCode")] |
|||
public string? ContainerCode { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailExpireDate")] |
|||
public DateTime? ExpireDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemCode")] |
|||
public string? ItemCode { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemDesc1")] |
|||
public string? ItemDesc1 { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemDesc2")] |
|||
public string? ItemDesc2 { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemName")] |
|||
public string? ItemName { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationArea")] |
|||
public string? LocationArea { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationCode")] |
|||
public string? LocationCode { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationErpCode")] |
|||
public string? LocationErpCode { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationGroup")] |
|||
public string? LocationGroup { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLot")] |
|||
public string? Lot { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailMaster")] |
|||
public StoreReceiptAbnormalNote? Master { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailMasterId")] |
|||
public Guid? MasterId { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailNumber")] |
|||
public string? Number { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailPackingCode")] |
|||
public string? PackingCode { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailPhotos")] |
|||
public string? Photos { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailProduceDate")] |
|||
public DateTime? ProduceDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailQty")] |
|||
public decimal? Qty { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailReceiptNumber")] |
|||
public string? ReceiptNumber { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailStatus")] |
|||
public string? Status { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailStdPackQty")] |
|||
public decimal? StdPackQty { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailSupplierBatch")] |
|||
public string? SupplierBatch { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailUom")] |
|||
public string? Uom { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailWarehouseCode")] |
|||
public string? WarehouseCode { get; set; } |
|||
} |
@ -0,0 +1,88 @@ |
|||
using System; |
|||
using System.ComponentModel.DataAnnotations; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreReceiptAbnormalNoteDetail.StoreReceiptAbnormalNoteDetail.ViewModels; |
|||
|
|||
public class CreateEditStoreReceiptAbnormalNoteDetailViewModel |
|||
{ |
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailAbnormalType")] |
|||
public string AbnormalType { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailArriveDate")] |
|||
public DateTime ArriveDate { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailContainerCode")] |
|||
public string? ContainerCode { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailExpireDate")] |
|||
public DateTime ExpireDate { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemCode")] |
|||
public string ItemCode { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemDesc1")] |
|||
public string? ItemDesc1 { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemDesc2")] |
|||
public string? ItemDesc2 { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailItemName")] |
|||
public string? ItemName { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationArea")] |
|||
public string? LocationArea { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationCode")] |
|||
public string LocationCode { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationErpCode")] |
|||
public string LocationErpCode { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLocationGroup")] |
|||
public string? LocationGroup { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailLot")] |
|||
public string? Lot { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailMaster")] |
|||
public StoreReceiptAbnormalNote Master { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailMasterId")] |
|||
public Guid MasterId { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailNumber")] |
|||
public string Number { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailPackingCode")] |
|||
public string PackingCode { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailPhotos")] |
|||
public string? Photos { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailProduceDate")] |
|||
public DateTime ProduceDate { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailQty")] |
|||
public decimal Qty { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailReceiptNumber")] |
|||
public string ReceiptNumber { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailStatus")] |
|||
public string Status { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailStdPackQty")] |
|||
public decimal StdPackQty { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailSupplierBatch")] |
|||
public string? SupplierBatch { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailUom")] |
|||
public string Uom { get; set; } |
|||
|
|||
[Display(Name = "StoreReceiptAbnormalNoteDetailWarehouseCode")] |
|||
public string WarehouseCode { get; set; } |
|||
} |
@ -0,0 +1,189 @@ |
|||
$(function () { |
|||
|
|||
$("#StoreReceiptAbnormalNoteDetailFilter :input").on('input', function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
//After abp v7.2 use dynamicForm 'column-size' instead of the following settings
|
|||
//$('#StoreReceiptAbnormalNoteDetailCollapse div').addClass('col-sm-3').parent().addClass('row');
|
|||
|
|||
var getFilter = function () { |
|||
var input = {}; |
|||
$("#StoreReceiptAbnormalNoteDetailFilter") |
|||
.serializeArray() |
|||
.forEach(function (data) { |
|||
if (data.value != '') { |
|||
input[abp.utils.toCamelCase(data.name.replace(/StoreReceiptAbnormalNoteDetailFilter./g, ''))] = data.value; |
|||
} |
|||
}) |
|||
return input; |
|||
}; |
|||
|
|||
var l = abp.localization.getResource('Wms'); |
|||
|
|||
var service = winIn.fasterZ.wms.z_Business.storeReceiptAbnormalNoteDetail.storeReceiptAbnormalNoteDetail; |
|||
var createModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreReceiptAbnormalNoteDetail/StoreReceiptAbnormalNoteDetail/CreateModal'); |
|||
var editModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreReceiptAbnormalNoteDetail/StoreReceiptAbnormalNoteDetail/EditModal'); |
|||
|
|||
var dataTable = $('#StoreReceiptAbnormalNoteDetailTable').DataTable(abp.libs.datatables.normalizeConfiguration({ |
|||
processing: true, |
|||
serverSide: true, |
|||
paging: true, |
|||
searching: false,//disable default searchbox
|
|||
autoWidth: false, |
|||
scrollCollapse: true, |
|||
order: [[0, "asc"]], |
|||
ajax: abp.libs.datatables.createAjax(service.getList,getFilter), |
|||
columnDefs: [ |
|||
{ |
|||
rowAction: { |
|||
items: |
|||
[ |
|||
{ |
|||
text: l('Edit'), |
|||
visible: abp.auth.isGranted('Wms.StoreReceiptAbnormalNoteDetail.Update'), |
|||
action: function (data) { |
|||
editModal.open({ id: data.record.id }); |
|||
} |
|||
}, |
|||
{ |
|||
text: l('Delete'), |
|||
visible: abp.auth.isGranted('Wms.StoreReceiptAbnormalNoteDetail.Delete'), |
|||
confirmMessage: function (data) { |
|||
return l('StoreReceiptAbnormalNoteDetailDeletionConfirmationMessage', data.record.id); |
|||
}, |
|||
action: function (data) { |
|||
service.delete(data.record.id) |
|||
.then(function () { |
|||
abp.notify.info(l('SuccessfullyDeleted')); |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
} |
|||
} |
|||
] |
|||
} |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailAbnormalType'), |
|||
data: "abnormalType" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailArriveDate'), |
|||
data: "arriveDate" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailContainerCode'), |
|||
data: "containerCode" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailExpireDate'), |
|||
data: "expireDate" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailItemCode'), |
|||
data: "itemCode" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailItemDesc1'), |
|||
data: "itemDesc1" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailItemDesc2'), |
|||
data: "itemDesc2" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailItemName'), |
|||
data: "itemName" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailLocationArea'), |
|||
data: "locationArea" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailLocationCode'), |
|||
data: "locationCode" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailLocationErpCode'), |
|||
data: "locationErpCode" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailLocationGroup'), |
|||
data: "locationGroup" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailLot'), |
|||
data: "lot" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailMaster'), |
|||
data: "master" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailMasterId'), |
|||
data: "masterId" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailNumber'), |
|||
data: "number" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailPackingCode'), |
|||
data: "packingCode" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailPhotos'), |
|||
data: "photos" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailProduceDate'), |
|||
data: "produceDate" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailQty'), |
|||
data: "qty" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailReceiptNumber'), |
|||
data: "receiptNumber" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailRemark'), |
|||
data: "remark" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailStatus'), |
|||
data: "status" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailStdPackQty'), |
|||
data: "stdPackQty" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailSupplierBatch'), |
|||
data: "supplierBatch" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailUom'), |
|||
data: "uom" |
|||
}, |
|||
{ |
|||
title: l('StoreReceiptAbnormalNoteDetailWarehouseCode'), |
|||
data: "warehouseCode" |
|||
}, |
|||
] |
|||
})); |
|||
|
|||
createModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
editModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
$('#NewStoreReceiptAbnormalNoteDetailButton').click(function (e) { |
|||
e.preventDefault(); |
|||
createModal.open(); |
|||
}); |
|||
}); |
@ -0,0 +1,18 @@ |
|||
@page |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote.CreateModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="CreateModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["CreateStoreRecycledMaterialReceiptNote"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,27 @@ |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreRecycledMaterialReceiptNote; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreRecycledMaterialReceiptNote.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote; |
|||
|
|||
public class CreateModalModel : WmsPageModel |
|||
{ |
|||
[BindProperty] |
|||
public CreateEditStoreRecycledMaterialReceiptNoteViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreRecycledMaterialReceiptNoteAppService _service; |
|||
|
|||
public CreateModalModel(IStoreRecycledMaterialReceiptNoteAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreRecycledMaterialReceiptNoteViewModel, CreateUpdateStoreRecycledMaterialReceiptNoteDto>(ViewModel); |
|||
await _service.CreateAsync(dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,19 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote.EditModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="EditModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["EditStoreRecycledMaterialReceiptNote"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-input asp-for="Id" /> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,38 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreRecycledMaterialReceiptNote; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreRecycledMaterialReceiptNote.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote; |
|||
|
|||
public class EditModalModel : WmsPageModel |
|||
{ |
|||
[HiddenInput] |
|||
[BindProperty(SupportsGet = true)] |
|||
public Guid Id { get; set; } |
|||
|
|||
[BindProperty] |
|||
public CreateEditStoreRecycledMaterialReceiptNoteViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreRecycledMaterialReceiptNoteAppService _service; |
|||
|
|||
public EditModalModel(IStoreRecycledMaterialReceiptNoteAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
var dto = await _service.GetAsync(Id); |
|||
ViewModel = ObjectMapper.Map<StoreRecycledMaterialReceiptNoteDto, CreateEditStoreRecycledMaterialReceiptNoteViewModel>(dto); |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreRecycledMaterialReceiptNoteViewModel, CreateUpdateStoreRecycledMaterialReceiptNoteDto>(ViewModel); |
|||
await _service.UpdateAsync(Id, dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,57 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Permissions |
|||
@using Microsoft.AspNetCore.Authorization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Layout |
|||
@using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using WinIn.FasterZ.Wms.Web.Menus |
|||
@model IndexModel |
|||
@inject IPageLayout PageLayout |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@inject IAuthorizationService Authorization |
|||
@{ |
|||
PageLayout.Content.Title = L["StoreRecycledMaterialReceiptNote"].Value; |
|||
PageLayout.Content.BreadCrumb.Add(L["Menu:StoreRecycledMaterialReceiptNote"].Value); |
|||
PageLayout.Content.MenuItemName = WmsMenus.StoreRecycledMaterialReceiptNote; |
|||
} |
|||
|
|||
@section scripts |
|||
{ |
|||
<abp-script src="/Pages/Z_Business/StoreRecycledMaterialReceiptNote/StoreRecycledMaterialReceiptNote/index.js" /> |
|||
} |
|||
@section styles |
|||
{ |
|||
<abp-style src="/Pages/Z_Business/StoreRecycledMaterialReceiptNote/StoreRecycledMaterialReceiptNote/index.css"/> |
|||
} |
|||
|
|||
<abp-card> |
|||
<abp-card-header> |
|||
<abp-row> |
|||
<abp-column size-md="_6"> |
|||
<abp-card-title>@L["StoreRecycledMaterialReceiptNote"]</abp-card-title> |
|||
</abp-column> |
|||
<abp-column size-md="_6" class="text-end"> |
|||
@if (await Authorization.IsGrantedAsync(WmsPermissions.StoreRecycledMaterialReceiptNote.Create)) |
|||
{ |
|||
<abp-button id="NewStoreRecycledMaterialReceiptNoteButton" |
|||
text="@L["CreateStoreRecycledMaterialReceiptNote"].Value" |
|||
icon="plus" |
|||
button-type="Primary" /> |
|||
} |
|||
</abp-column> |
|||
</abp-row> |
|||
</abp-card-header> |
|||
<abp-card-body> |
|||
<abp-row class="mb-3"> |
|||
<a abp-collapse-id="StoreRecycledMaterialReceiptNoteCollapse" class="text-secondary">@L["TableFilter"] </a> |
|||
</abp-row> |
|||
<abp-dynamic-form abp-model="StoreRecycledMaterialReceiptNoteFilter" id="StoreRecycledMaterialReceiptNoteFilter" required-symbols="false" column-size="_3"> |
|||
<abp-collapse-body id="StoreRecycledMaterialReceiptNoteCollapse"> |
|||
<abp-form-content /> |
|||
</abp-collapse-body> |
|||
</abp-dynamic-form> |
|||
<hr /> |
|||
<abp-table striped-rows="true" id="StoreRecycledMaterialReceiptNoteTable" class="nowrap"/> |
|||
</abp-card-body> |
|||
</abp-card> |
@ -0,0 +1,39 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using System.ComponentModel.DataAnnotations; |
|||
using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Form; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote; |
|||
|
|||
public class IndexModel : WmsPageModel |
|||
{ |
|||
public StoreRecycledMaterialReceiptNoteFilterInput StoreRecycledMaterialReceiptNoteFilter { get; set; } |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
await Task.CompletedTask; |
|||
} |
|||
} |
|||
|
|||
public class StoreRecycledMaterialReceiptNoteFilterInput |
|||
{ |
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteActiveDate")] |
|||
public DateTime? ActiveDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteNumber")] |
|||
public string? Number { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteStoreRecycledMaterialReceiptNoteDetails")] |
|||
public ICollection<StoreRecycledMaterialReceiptNoteDetail>? StoreRecycledMaterialReceiptNoteDetails { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteWorker")] |
|||
public string? Worker { get; set; } |
|||
} |
@ -0,0 +1,22 @@ |
|||
using System; |
|||
using System.ComponentModel.DataAnnotations; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreRecycledMaterialReceiptNote.StoreRecycledMaterialReceiptNote.ViewModels; |
|||
|
|||
public class CreateEditStoreRecycledMaterialReceiptNoteViewModel |
|||
{ |
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteActiveDate")] |
|||
public DateTime ActiveDate { get; set; } |
|||
|
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteNumber")] |
|||
public string Number { get; set; } |
|||
|
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteStoreRecycledMaterialReceiptNoteDetails")] |
|||
public ICollection<StoreRecycledMaterialReceiptNoteDetail> StoreRecycledMaterialReceiptNoteDetails { get; set; } |
|||
|
|||
[Display(Name = "StoreRecycledMaterialReceiptNoteWorker")] |
|||
public string? Worker { get; set; } |
|||
} |
@ -0,0 +1,101 @@ |
|||
$(function () { |
|||
|
|||
$("#StoreRecycledMaterialReceiptNoteFilter :input").on('input', function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
//After abp v7.2 use dynamicForm 'column-size' instead of the following settings
|
|||
//$('#StoreRecycledMaterialReceiptNoteCollapse div').addClass('col-sm-3').parent().addClass('row');
|
|||
|
|||
var getFilter = function () { |
|||
var input = {}; |
|||
$("#StoreRecycledMaterialReceiptNoteFilter") |
|||
.serializeArray() |
|||
.forEach(function (data) { |
|||
if (data.value != '') { |
|||
input[abp.utils.toCamelCase(data.name.replace(/StoreRecycledMaterialReceiptNoteFilter./g, ''))] = data.value; |
|||
} |
|||
}) |
|||
return input; |
|||
}; |
|||
|
|||
var l = abp.localization.getResource('Wms'); |
|||
|
|||
var service = winIn.fasterZ.wms.z_Business.storeRecycledMaterialReceiptNote.storeRecycledMaterialReceiptNote; |
|||
var createModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreRecycledMaterialReceiptNote/StoreRecycledMaterialReceiptNote/CreateModal'); |
|||
var editModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreRecycledMaterialReceiptNote/StoreRecycledMaterialReceiptNote/EditModal'); |
|||
|
|||
var dataTable = $('#StoreRecycledMaterialReceiptNoteTable').DataTable(abp.libs.datatables.normalizeConfiguration({ |
|||
processing: true, |
|||
serverSide: true, |
|||
paging: true, |
|||
searching: false,//disable default searchbox
|
|||
autoWidth: false, |
|||
scrollCollapse: true, |
|||
order: [[0, "asc"]], |
|||
ajax: abp.libs.datatables.createAjax(service.getList,getFilter), |
|||
columnDefs: [ |
|||
{ |
|||
rowAction: { |
|||
items: |
|||
[ |
|||
{ |
|||
text: l('Edit'), |
|||
visible: abp.auth.isGranted('Wms.StoreRecycledMaterialReceiptNote.Update'), |
|||
action: function (data) { |
|||
editModal.open({ id: data.record.id }); |
|||
} |
|||
}, |
|||
{ |
|||
text: l('Delete'), |
|||
visible: abp.auth.isGranted('Wms.StoreRecycledMaterialReceiptNote.Delete'), |
|||
confirmMessage: function (data) { |
|||
return l('StoreRecycledMaterialReceiptNoteDeletionConfirmationMessage', data.record.id); |
|||
}, |
|||
action: function (data) { |
|||
service.delete(data.record.id) |
|||
.then(function () { |
|||
abp.notify.info(l('SuccessfullyDeleted')); |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
} |
|||
} |
|||
] |
|||
} |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteActiveDate'), |
|||
data: "activeDate" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteNumber'), |
|||
data: "number" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteRemark'), |
|||
data: "remark" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteStoreRecycledMaterialReceiptNoteDetails'), |
|||
data: "storeRecycledMaterialReceiptNoteDetails" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteWorker'), |
|||
data: "worker" |
|||
}, |
|||
] |
|||
})); |
|||
|
|||
createModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
editModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
$('#NewStoreRecycledMaterialReceiptNoteButton').click(function (e) { |
|||
e.preventDefault(); |
|||
createModal.open(); |
|||
}); |
|||
}); |
@ -0,0 +1,181 @@ |
|||
$(function () { |
|||
|
|||
$("#StoreRecycledMaterialReceiptNoteDetailFilter :input").on('input', function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
//After abp v7.2 use dynamicForm 'column-size' instead of the following settings
|
|||
//$('#StoreRecycledMaterialReceiptNoteDetailCollapse div').addClass('col-sm-3').parent().addClass('row');
|
|||
|
|||
var getFilter = function () { |
|||
var input = {}; |
|||
$("#StoreRecycledMaterialReceiptNoteDetailFilter") |
|||
.serializeArray() |
|||
.forEach(function (data) { |
|||
if (data.value != '') { |
|||
input[abp.utils.toCamelCase(data.name.replace(/StoreRecycledMaterialReceiptNoteDetailFilter./g, ''))] = data.value; |
|||
} |
|||
}) |
|||
return input; |
|||
}; |
|||
|
|||
var l = abp.localization.getResource('Wms'); |
|||
|
|||
var service = winIn.fasterZ.wms.z_Business.storeRecycledMaterialReceiptNoteDetail.storeRecycledMaterialReceiptNoteDetail; |
|||
var createModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreRecycledMaterialReceiptNoteDetail/StoreRecycledMaterialReceiptNoteDetail/CreateModal'); |
|||
var editModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreRecycledMaterialReceiptNoteDetail/StoreRecycledMaterialReceiptNoteDetail/EditModal'); |
|||
|
|||
var dataTable = $('#StoreRecycledMaterialReceiptNoteDetailTable').DataTable(abp.libs.datatables.normalizeConfiguration({ |
|||
processing: true, |
|||
serverSide: true, |
|||
paging: true, |
|||
searching: false,//disable default searchbox
|
|||
autoWidth: false, |
|||
scrollCollapse: true, |
|||
order: [[0, "asc"]], |
|||
ajax: abp.libs.datatables.createAjax(service.getList,getFilter), |
|||
columnDefs: [ |
|||
{ |
|||
rowAction: { |
|||
items: |
|||
[ |
|||
{ |
|||
text: l('Edit'), |
|||
visible: abp.auth.isGranted('Wms.StoreRecycledMaterialReceiptNoteDetail.Update'), |
|||
action: function (data) { |
|||
editModal.open({ id: data.record.id }); |
|||
} |
|||
}, |
|||
{ |
|||
text: l('Delete'), |
|||
visible: abp.auth.isGranted('Wms.StoreRecycledMaterialReceiptNoteDetail.Delete'), |
|||
confirmMessage: function (data) { |
|||
return l('StoreRecycledMaterialReceiptNoteDetailDeletionConfirmationMessage', data.record.id); |
|||
}, |
|||
action: function (data) { |
|||
service.delete(data.record.id) |
|||
.then(function () { |
|||
abp.notify.info(l('SuccessfullyDeleted')); |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
} |
|||
} |
|||
] |
|||
} |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailArriveDate'), |
|||
data: "arriveDate" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailContainerCode'), |
|||
data: "containerCode" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailExpireDate'), |
|||
data: "expireDate" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailItemCode'), |
|||
data: "itemCode" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailItemDesc1'), |
|||
data: "itemDesc1" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailItemDesc2'), |
|||
data: "itemDesc2" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailItemName'), |
|||
data: "itemName" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailLocationArea'), |
|||
data: "locationArea" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailLocationCode'), |
|||
data: "locationCode" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailLocationErpCode'), |
|||
data: "locationErpCode" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailLocationGroup'), |
|||
data: "locationGroup" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailLot'), |
|||
data: "lot" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailMaster'), |
|||
data: "master" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailMasterId'), |
|||
data: "masterId" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailNumber'), |
|||
data: "number" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailPackingCode'), |
|||
data: "packingCode" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailProduceDate'), |
|||
data: "produceDate" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailQty'), |
|||
data: "qty" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailReasonCode'), |
|||
data: "reasonCode" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailRemark'), |
|||
data: "remark" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailStatus'), |
|||
data: "status" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailStdPackQty'), |
|||
data: "stdPackQty" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailSupplierBatch'), |
|||
data: "supplierBatch" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailUom'), |
|||
data: "uom" |
|||
}, |
|||
{ |
|||
title: l('StoreRecycledMaterialReceiptNoteDetailWarehouseCode'), |
|||
data: "warehouseCode" |
|||
}, |
|||
] |
|||
})); |
|||
|
|||
createModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
editModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
$('#NewStoreRecycledMaterialReceiptNoteDetailButton').click(function (e) { |
|||
e.preventDefault(); |
|||
createModal.open(); |
|||
}); |
|||
}); |
@ -0,0 +1,18 @@ |
|||
@page |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder.CreateModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="CreateModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["CreateStoreSaleOrder"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,27 @@ |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreSaleOrder; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreSaleOrder.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder; |
|||
|
|||
public class CreateModalModel : WmsPageModel |
|||
{ |
|||
[BindProperty] |
|||
public CreateEditStoreSaleOrderViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreSaleOrderAppService _service; |
|||
|
|||
public CreateModalModel(IStoreSaleOrderAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreSaleOrderViewModel, CreateUpdateStoreSaleOrderDto>(ViewModel); |
|||
await _service.CreateAsync(dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,19 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal; |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@model WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder.EditModalModel |
|||
@{ |
|||
Layout = null; |
|||
} |
|||
<abp-dynamic-form abp-model="ViewModel" data-ajaxForm="true" asp-page="EditModal"> |
|||
<abp-modal> |
|||
<abp-modal-header title="@L["EditStoreSaleOrder"].Value"></abp-modal-header> |
|||
<abp-modal-body> |
|||
<abp-input asp-for="Id" /> |
|||
<abp-form-content /> |
|||
</abp-modal-body> |
|||
<abp-modal-footer buttons="@(AbpModalButtons.Cancel|AbpModalButtons.Save)"></abp-modal-footer> |
|||
</abp-modal> |
|||
</abp-dynamic-form> |
@ -0,0 +1,38 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreSaleOrder; |
|||
using WinIn.FasterZ.Wms.Z_Business.StoreSaleOrder.Dtos; |
|||
using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder.ViewModels; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder; |
|||
|
|||
public class EditModalModel : WmsPageModel |
|||
{ |
|||
[HiddenInput] |
|||
[BindProperty(SupportsGet = true)] |
|||
public Guid Id { get; set; } |
|||
|
|||
[BindProperty] |
|||
public CreateEditStoreSaleOrderViewModel ViewModel { get; set; } |
|||
|
|||
private readonly IStoreSaleOrderAppService _service; |
|||
|
|||
public EditModalModel(IStoreSaleOrderAppService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
var dto = await _service.GetAsync(Id); |
|||
ViewModel = ObjectMapper.Map<StoreSaleOrderDto, CreateEditStoreSaleOrderViewModel>(dto); |
|||
} |
|||
|
|||
public virtual async Task<IActionResult> OnPostAsync() |
|||
{ |
|||
var dto = ObjectMapper.Map<CreateEditStoreSaleOrderViewModel, CreateUpdateStoreSaleOrderDto>(ViewModel); |
|||
await _service.UpdateAsync(Id, dto); |
|||
return NoContent(); |
|||
} |
|||
} |
@ -0,0 +1,57 @@ |
|||
@page |
|||
@using WinIn.FasterZ.Wms.Permissions |
|||
@using Microsoft.AspNetCore.Authorization |
|||
@using Microsoft.AspNetCore.Mvc.Localization |
|||
@using Volo.Abp.AspNetCore.Mvc.UI.Layout |
|||
@using WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder |
|||
@using WinIn.FasterZ.Wms.Localization |
|||
@using WinIn.FasterZ.Wms.Web.Menus |
|||
@model IndexModel |
|||
@inject IPageLayout PageLayout |
|||
@inject IHtmlLocalizer<WmsResource> L |
|||
@inject IAuthorizationService Authorization |
|||
@{ |
|||
PageLayout.Content.Title = L["StoreSaleOrder"].Value; |
|||
PageLayout.Content.BreadCrumb.Add(L["Menu:StoreSaleOrder"].Value); |
|||
PageLayout.Content.MenuItemName = WmsMenus.StoreSaleOrder; |
|||
} |
|||
|
|||
@section scripts |
|||
{ |
|||
<abp-script src="/Pages/Z_Business/StoreSaleOrder/StoreSaleOrder/index.js" /> |
|||
} |
|||
@section styles |
|||
{ |
|||
<abp-style src="/Pages/Z_Business/StoreSaleOrder/StoreSaleOrder/index.css"/> |
|||
} |
|||
|
|||
<abp-card> |
|||
<abp-card-header> |
|||
<abp-row> |
|||
<abp-column size-md="_6"> |
|||
<abp-card-title>@L["StoreSaleOrder"]</abp-card-title> |
|||
</abp-column> |
|||
<abp-column size-md="_6" class="text-end"> |
|||
@if (await Authorization.IsGrantedAsync(WmsPermissions.StoreSaleOrder.Create)) |
|||
{ |
|||
<abp-button id="NewStoreSaleOrderButton" |
|||
text="@L["CreateStoreSaleOrder"].Value" |
|||
icon="plus" |
|||
button-type="Primary" /> |
|||
} |
|||
</abp-column> |
|||
</abp-row> |
|||
</abp-card-header> |
|||
<abp-card-body> |
|||
<abp-row class="mb-3"> |
|||
<a abp-collapse-id="StoreSaleOrderCollapse" class="text-secondary">@L["TableFilter"] </a> |
|||
</abp-row> |
|||
<abp-dynamic-form abp-model="StoreSaleOrderFilter" id="StoreSaleOrderFilter" required-symbols="false" column-size="_3"> |
|||
<abp-collapse-body id="StoreSaleOrderCollapse"> |
|||
<abp-form-content /> |
|||
</abp-collapse-body> |
|||
</abp-dynamic-form> |
|||
<hr /> |
|||
<abp-table striped-rows="true" id="StoreSaleOrderTable" class="nowrap"/> |
|||
</abp-card-body> |
|||
</abp-card> |
@ -0,0 +1,79 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using System.ComponentModel.DataAnnotations; |
|||
using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Form; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder; |
|||
|
|||
public class IndexModel : WmsPageModel |
|||
{ |
|||
public StoreSaleOrderFilterInput StoreSaleOrderFilter { get; set; } |
|||
|
|||
public virtual async Task OnGetAsync() |
|||
{ |
|||
await Task.CompletedTask; |
|||
} |
|||
} |
|||
|
|||
public class StoreSaleOrderFilterInput |
|||
{ |
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderActiveDate")] |
|||
public DateTime? ActiveDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderContactEmail")] |
|||
public string? ContactEmail { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderContactName")] |
|||
public string? ContactName { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderContactPhone")] |
|||
public string? ContactPhone { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderCustomerCode")] |
|||
public string? CustomerCode { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderDueDate")] |
|||
public DateTime? DueDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderNumber")] |
|||
public string? Number { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderOrderDate")] |
|||
public DateTime? OrderDate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderSoStatus")] |
|||
public string? SoStatus { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderSoType")] |
|||
public string? SoType { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderStoreSaleOrderDetails")] |
|||
public ICollection<StoreSaleOrderDetail>? StoreSaleOrderDetails { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderTaxRate")] |
|||
public decimal? TaxRate { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderVersion")] |
|||
public string? Version { get; set; } |
|||
|
|||
[FormControlSize(AbpFormControlSize.Small)] |
|||
[Display(Name = "StoreSaleOrderWorker")] |
|||
public string? Worker { get; set; } |
|||
} |
@ -0,0 +1,52 @@ |
|||
using System; |
|||
using System.ComponentModel.DataAnnotations; |
|||
|
|||
namespace WinIn.FasterZ.Wms.Web.Pages.Z_Business.StoreSaleOrder.StoreSaleOrder.ViewModels; |
|||
|
|||
public class CreateEditStoreSaleOrderViewModel |
|||
{ |
|||
[Display(Name = "StoreSaleOrderActiveDate")] |
|||
public DateTime ActiveDate { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderContactEmail")] |
|||
public string? ContactEmail { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderContactName")] |
|||
public string? ContactName { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderContactPhone")] |
|||
public string? ContactPhone { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderCustomerCode")] |
|||
public string? CustomerCode { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderDueDate")] |
|||
public DateTime DueDate { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderNumber")] |
|||
public string Number { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderOrderDate")] |
|||
public DateTime OrderDate { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderRemark")] |
|||
public string? Remark { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderSoStatus")] |
|||
public string SoStatus { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderSoType")] |
|||
public string? SoType { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderStoreSaleOrderDetails")] |
|||
public ICollection<StoreSaleOrderDetail> StoreSaleOrderDetails { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderTaxRate")] |
|||
public decimal TaxRate { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderVersion")] |
|||
public string? Version { get; set; } |
|||
|
|||
[Display(Name = "StoreSaleOrderWorker")] |
|||
public string? Worker { get; set; } |
|||
} |
@ -0,0 +1,141 @@ |
|||
$(function () { |
|||
|
|||
$("#StoreSaleOrderFilter :input").on('input', function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
//After abp v7.2 use dynamicForm 'column-size' instead of the following settings
|
|||
//$('#StoreSaleOrderCollapse div').addClass('col-sm-3').parent().addClass('row');
|
|||
|
|||
var getFilter = function () { |
|||
var input = {}; |
|||
$("#StoreSaleOrderFilter") |
|||
.serializeArray() |
|||
.forEach(function (data) { |
|||
if (data.value != '') { |
|||
input[abp.utils.toCamelCase(data.name.replace(/StoreSaleOrderFilter./g, ''))] = data.value; |
|||
} |
|||
}) |
|||
return input; |
|||
}; |
|||
|
|||
var l = abp.localization.getResource('Wms'); |
|||
|
|||
var service = winIn.fasterZ.wms.z_Business.storeSaleOrder.storeSaleOrder; |
|||
var createModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreSaleOrder/StoreSaleOrder/CreateModal'); |
|||
var editModal = new abp.ModalManager(abp.appPath + 'Z_Business/StoreSaleOrder/StoreSaleOrder/EditModal'); |
|||
|
|||
var dataTable = $('#StoreSaleOrderTable').DataTable(abp.libs.datatables.normalizeConfiguration({ |
|||
processing: true, |
|||
serverSide: true, |
|||
paging: true, |
|||
searching: false,//disable default searchbox
|
|||
autoWidth: false, |
|||
scrollCollapse: true, |
|||
order: [[0, "asc"]], |
|||
ajax: abp.libs.datatables.createAjax(service.getList,getFilter), |
|||
columnDefs: [ |
|||
{ |
|||
rowAction: { |
|||
items: |
|||
[ |
|||
{ |
|||
text: l('Edit'), |
|||
visible: abp.auth.isGranted('Wms.StoreSaleOrder.Update'), |
|||
action: function (data) { |
|||
editModal.open({ id: data.record.id }); |
|||
} |
|||
}, |
|||
{ |
|||
text: l('Delete'), |
|||
visible: abp.auth.isGranted('Wms.StoreSaleOrder.Delete'), |
|||
confirmMessage: function (data) { |
|||
return l('StoreSaleOrderDeletionConfirmationMessage', data.record.id); |
|||
}, |
|||
action: function (data) { |
|||
service.delete(data.record.id) |
|||
.then(function () { |
|||
abp.notify.info(l('SuccessfullyDeleted')); |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
} |
|||
} |
|||
] |
|||
} |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderActiveDate'), |
|||
data: "activeDate" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderContactEmail'), |
|||
data: "contactEmail" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderContactName'), |
|||
data: "contactName" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderContactPhone'), |
|||
data: "contactPhone" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderCustomerCode'), |
|||
data: "customerCode" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderDueDate'), |
|||
data: "dueDate" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderNumber'), |
|||
data: "number" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderOrderDate'), |
|||
data: "orderDate" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderRemark'), |
|||
data: "remark" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderSoStatus'), |
|||
data: "soStatus" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderSoType'), |
|||
data: "soType" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderStoreSaleOrderDetails'), |
|||
data: "storeSaleOrderDetails" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderTaxRate'), |
|||
data: "taxRate" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderVersion'), |
|||
data: "version" |
|||
}, |
|||
{ |
|||
title: l('StoreSaleOrderWorker'), |
|||
data: "worker" |
|||
}, |
|||
] |
|||
})); |
|||
|
|||
createModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
editModal.onResult(function () { |
|||
dataTable.ajax.reload(); |
|||
}); |
|||
|
|||
$('#NewStoreSaleOrderButton').click(function (e) { |
|||
e.preventDefault(); |
|||
createModal.open(); |
|||
}); |
|||
}); |
Loading…
Reference in new issue