sync
This commit is contained in:
@@ -155,12 +155,12 @@ export function insertFile(container, file, r) {
|
||||
type = type.substring(type.lastIndexOf('.'));
|
||||
}
|
||||
if (fileSupported.indexOf(type) < 0) {
|
||||
showAlert(r('P_WO_ERROR', 'Error'), r('P_CU_TYPENOTSUPPORTED', 'File type "{type}" is now not supported.').replace('{type}', type));
|
||||
showAlert(r('FLTL_01165', 'Error'), r('FLTL_01385', 'File type "{type}" is now not supported.').replace('{type}', type));
|
||||
return;
|
||||
}
|
||||
const isImage = /^image\//.test(type);
|
||||
if (!isImage && file.size > MaxAttachmentSize.limit) {
|
||||
showAlert(r('P_WO_ERROR', 'Error'), r('P_WO_ATTACHMENTSIZEEXCEEDSTHEMAXIMUMTIPS', `Attachment size exceeds the maximum allowed to be sent (${MaxAttachmentSize.text})`), 'warn');
|
||||
showAlert(r('FLTL_01165', 'Error'), r('FLTL_00407', `Attachment size exceeds the maximum allowed to be sent (${MaxAttachmentSize.text})`), 'warn');
|
||||
return;
|
||||
}
|
||||
const fn = file.name;
|
||||
@@ -202,12 +202,12 @@ function getStatusText(status, dict) {
|
||||
|
||||
export function getMessageStatus(comm, r, _var) {
|
||||
const messageStatus = {
|
||||
0: r('P_CU_PENDING', 'Pending'),
|
||||
1: r('P_WO_SENT', 'Sent'),
|
||||
5: r('P_CU_DELIVERYCONFIRMED', 'Delivery Confirmed'),
|
||||
6: r('P_CU_RESENT', 'Resent'),
|
||||
9: r('P_MA_FAILED', 'Failed'),
|
||||
9999: r('P_CU_UNKNOWN', 'Unknown')
|
||||
0: r('FLTL_02186', 'Pending'),
|
||||
1: r('FLTL_02711', 'Sent'),
|
||||
5: r('FLTL_00864', 'Delivery Confirmed'),
|
||||
6: r('FLTL_02478', 'Resent'),
|
||||
9: r('FLTL_01224', 'Failed'),
|
||||
9999: r('FLTL_03152', 'Unknown')
|
||||
};
|
||||
const knownStatus = [0, 1, 5, 6, 9, 10, 412];
|
||||
const okStatus = [1, 5, 6];
|
||||
@@ -269,7 +269,7 @@ export function getMessageStatus(comm, r, _var) {
|
||||
if (statusUpdatable !== false) {
|
||||
tip.appendChild(createElement('div', b => {
|
||||
b.className = 'tip-function-button';
|
||||
// setTooltip(b, r('P_CU_UPDATESTATUS', 'Update Status'));
|
||||
// setTooltip(b, r('FLTL_03174', 'Update Status'));
|
||||
b.addEventListener('click', async () => {
|
||||
for (let p of comm.Participator) {
|
||||
switch (p.Status) {
|
||||
@@ -292,7 +292,7 @@ export function getMessageStatus(comm, r, _var) {
|
||||
const gridContainer = createElement('div', 'status-grid');
|
||||
const popup = new Popup({
|
||||
onMasking: _var.option.onMasking,
|
||||
title: r('P_CU_UPDATESTATUS', 'Update Status'),
|
||||
title: r('FLTL_03174', 'Update Status'),
|
||||
content: createElement('div', wrapper => {
|
||||
wrapper.className = 'update-status-wrapper';
|
||||
wrapper.style.width = '500px';
|
||||
@@ -301,7 +301,7 @@ export function getMessageStatus(comm, r, _var) {
|
||||
),
|
||||
buttons: [
|
||||
{
|
||||
text: r('P_WO_OK', 'OK'),
|
||||
text: r('FLTL_02057', 'OK'),
|
||||
key: 'ok',
|
||||
trigger: () => {
|
||||
const changed = msgs.filter(m => {
|
||||
@@ -329,7 +329,7 @@ export function getMessageStatus(comm, r, _var) {
|
||||
}
|
||||
},
|
||||
{
|
||||
text: r('P_WO_CANCEL', 'Cancel'),
|
||||
text: r('FLTL_00499', 'Cancel'),
|
||||
key: 'cancel'
|
||||
}
|
||||
]
|
||||
@@ -341,22 +341,22 @@ export function getMessageStatus(comm, r, _var) {
|
||||
grid.columns = [
|
||||
{
|
||||
key: 'CustomerNumber',
|
||||
caption: r('P_JS_NUMBER', 'Number'),
|
||||
caption: r('FLTL_02026', 'Number'),
|
||||
width: 150
|
||||
},
|
||||
/*{
|
||||
key: 'customerName',
|
||||
caption: r('P_WOS_CUSTOMERNAME', 'Customer Name'),
|
||||
caption: r('FLTL_00742', 'Customer Name'),
|
||||
width: 120
|
||||
},*/
|
||||
{
|
||||
key: 'statusText',
|
||||
caption: r('P_CU_CURRENTSTATUS', 'Current Status'),
|
||||
caption: r('FLTL_00725', 'Current Status'),
|
||||
width: 155
|
||||
},
|
||||
{
|
||||
key: 'statusChanged',
|
||||
caption: r('P_CU_REVISEDSTATUS', 'Revised Status'),
|
||||
caption: r('FLTL_02511', 'Revised Status'),
|
||||
width: 155,
|
||||
type: Grid.ColumnTypes.Dropdown,
|
||||
source: [
|
||||
@@ -404,7 +404,7 @@ export function getMessageSendTo(comm, contacts, followers, r) {
|
||||
}
|
||||
}
|
||||
if (sendto !== '') {
|
||||
sendto = r('P_CU_SENDTO_COLON', 'Sent to :') + `\n${sendto}`;
|
||||
sendto = r('FLTL_02716', 'Sent to :') + `\n${sendto}`;
|
||||
}
|
||||
return sendto;
|
||||
}
|
||||
@@ -432,7 +432,7 @@ export function createHideMessageTitleButton(This, optionName) {
|
||||
span.className = 'msgadminsetting sbutton iconnotview';
|
||||
}
|
||||
span.style.padding = '0px 0px 0px 5px';
|
||||
setTooltip(span, option?.getText('P_WO_MESSAGEHISTORY_MANAGE', 'Manage Messages'));
|
||||
setTooltip(span, option?.getText('FLTL_01860', 'Manage Messages'));
|
||||
span.addEventListener('click', function () {
|
||||
const container = This._var.container;
|
||||
if (!option[optionName]) {
|
||||
@@ -457,8 +457,8 @@ export function createHideMessageTitleButton(This, optionName) {
|
||||
|
||||
export function createHideMessageCommentTail(This, optionName, comment, commentTime, func, hisFunc) {
|
||||
const option = This._var.option;
|
||||
const showTooltip = option?.getText('P_WO_MESSAGEHISTORY_VISIBLE', 'Visible');
|
||||
const notShowTooltip = option?.getText('P_WO_MESSAGEHISTORY_NOTVISIBLE', 'Not Visible');
|
||||
const showTooltip = option?.getText('FLTL_03267', 'Visible');
|
||||
const notShowTooltip = option?.getText('FLTL_02006', 'Not Visible');
|
||||
return createElement('div', div => {
|
||||
div.className = 'item-time';
|
||||
div.style.display = 'flex';
|
||||
@@ -498,7 +498,7 @@ export function createHideMessageCommentTail(This, optionName, comment, commentT
|
||||
span.className = 'msgHistory history-span-' + comment.Id;
|
||||
span.setAttribute('ModifyCount', comment.ModifyCount ?? 0);
|
||||
span.style.display = (option[optionName] && comment.ModifyCount > 0) ? '' : 'none';
|
||||
setTooltip(span, option?.getText('P_WO_MESSAGEHISTORY_HEADER', 'Hidden History'));
|
||||
setTooltip(span, option?.getText('FLTL_01508', 'Hidden History'));
|
||||
const icon = createIcon('fa-light', 'wave-sine');
|
||||
icon.style.height = '12px';
|
||||
icon.style.width = '12px';
|
||||
|
Reference in New Issue
Block a user