This commit is contained in:
2024-03-26 15:56:31 +08:00
parent 634e8b71ab
commit 0855ae42cd
547 changed files with 94818 additions and 60463 deletions

View File

@ -14,30 +14,6 @@
text-overflow: ellipsis;
white-space: nowrap;
}
.dialog-content table {
border-collapse: collapse;
width: 100%;
line-height: 32px;
}
.dialog-content table td.label {
width: 130px;
text-align: right;
padding-right: 10px;
line-height: 24px;
height: 24px;
vertical-align: top;
}
.dialog-content table td input,
.dialog-content table td textarea {
border: 1px solid #a9a9a9;
width: 250px;
height: 18px;
padding: 1px;
}
#dialog_machines .dialog-content table td input {
width: auto;
}
@ -119,16 +95,6 @@
line-height: 21px;
padding: 0;
}
.machine_maskbg {
top: 0;
left: 0;
width: 100%;
height: 100%;
position: absolute;
background: #000;
opacity: 0.2;
}
</style>
<script src="<%=GetFileUrlWithVersion("js/controls.js")%>" type="text/javascript"></script>
<script src="<%=GetFileUrlWithVersion("../js/assetselector.js")%>" type="text/javascript"></script>
@ -175,7 +141,7 @@
if (index < 0) {
showAlert(GetTextByKey("P_CR_PLEASESELECTCUSTOMERRECORD", "Please select customer record."), GetTextByKey("P_CUSTOMERRECORD", "Customer Record")); return;
}
var cust = grid_dt.source[index].Values;
var cust = grid_dt.source[index];
if (!cust) {
custrecordid = undefined;
return;
@ -216,8 +182,7 @@
for (var j in r) {
}
var fr = { Values: r };
rows.push(fr);
rows.push(r);
}
grid_dt.setData(rows);
@ -225,12 +190,7 @@
var grid_dt;
function InitGridData() {
grid_dt = new GridView('#customerlist');
grid_dt.lang = {
all: GetTextByKey("P_GRID_ALL", "(All)"),
ok: GetTextByKey("P_GRID_OK", "OK"),
reset: GetTextByKey("P_GRID_RESET", "Reset")
};
grid_dt = createGridView('#customerlist');
var list_columns = [
{ name: 'Code', caption: GetTextByKey("P_CR_CODE", "Code"), valueIndex: 'Code', allowFilter: true, css: { 'width': 120, 'text-align': 'left' } },
{ name: 'Name', caption: GetTextByKey("P_CR_COMPANYNAME", "Company Name"), valueIndex: 'Name', allowFilter: true, css: { 'width': 240, 'text-align': 'left' } },
@ -263,9 +223,10 @@
}
if (col.name === "Edit") {
col.isurl = true;
col.text = "\uf044";
col.sortable = false;
col.resizable = false;
col.type = GridView.ColumnTypes.Icon;
col.text = "edit";
col.events = {
onclick: function () {
OnEdit();
@ -277,9 +238,10 @@
col.attrs = { 'title': GetTextByKey("P_UM_EDIT", 'Edit') };
}
else if (col.name === "Delete") {
col.isurl = true;
col.text = "\uf00d";
col.sortable = false;
col.resizable = false;
col.type = GridView.ColumnTypes.Icon;
col.text = "times";
col.events = {
onclick: function () {
OnDelete(this);
@ -292,9 +254,10 @@
}
else if (col.name === "AssetAssignment") {
col.visible = !IsDealer;
col.isurl = true;
col.text = "\uf63c";
col.sortable = false;
col.resizable = false;
col.type = GridView.ColumnTypes.Icon;
col.text = "truck-pickup";
col.events = {
onclick: function () {
OnManageMachine(this);
@ -307,15 +270,15 @@
}
columns.push(col);
}
grid_dt.canMultiSelect = false;
grid_dt.multiSelect = false;
grid_dt.columns = columns;
grid_dt.init();
grid_dt.rowdblclick = OnEdit;
grid_dt.onRowDblClicked = OnEdit;
grid_dt.selectedrowchanged = function (rowindex) {
grid_dt.onSelectedRowChanged = function (rowindex) {
var rowdata = grid_dt.source[rowindex];
if (rowdata) {
uiid = rowdata.Values.IID;
uiid = rowdata.IID;
}
}
}
@ -326,13 +289,13 @@
InitGridData();
$('#dialog_managemahchine').dialog(function () {
$('.machine_maskbg').hide();
showmaskbg(false);
});
OnRefresh();
$('#dialog_managemahchine').dialog(function () {
$('.machine_maskbg').hide();
showmaskbg(false);
});
$('#searchinputtxt').keydown(searchEnter);
@ -366,7 +329,7 @@
<div class="search_bar">
<input type="password" autocomplete="new-password" style="display: none" />
<input type="text" id="searchinputtxt" autocomplete="off" />
<input class="search" type="button" onclick="OnRefresh();" value="Search" data-lgid="P_CM_SEARCH" />
<input class="search" type="button" onclick="OnRefresh();" value="Search" data-lgid="P_CM_SEARCH" style="margin-left: 5px" />
</div>
<div class="function_title">
<%if (!CRReadOnly)
@ -379,8 +342,10 @@
</div>
<div class="clear"></div>
<div id="customerlist"></div>
<div class="machine_maskbg" style="display: none;"></div>
<div id="mask_bg" style="display: none;">
<div class="loading c-spin"></div>
</div>
<div class="dialog" id="dialog_managemahchine" style="display: none;">
<div id="dialogmask" class="maskbg" style="display: none; z-index: 1;">
<div class="loading_icon icon c-spin"></div>
@ -416,9 +381,6 @@
</div>
</div>
<div id="mask_bg" style="display: none;">
<div class="loading c-spin"></div>
</div>
<div class="dialog" id="dialog_user" style="display: none; height: 100%; border-bottom: 0; border-top: 0;">
<iframe id="iframeuser" src="AddCustomerRecord.aspx" style="width: 100%; height: 100%; display: block; border: none;"></iframe>
<div class="maskbg" style="display: none;"></div>