- Import emails from a list to a DB

- Create Template Emails
- Options Email
This commit is contained in:
Paolo Arena
2019-12-04 02:04:54 +01:00
parent 895df43074
commit 8268a09897
20 changed files with 619 additions and 165 deletions

View File

@@ -9,10 +9,11 @@ import { CMyChipList } from '../CMyChipList'
import { CDateTime } from '../CDateTime'
import { CMyToggleList } from '../CMyToggleList'
import { CMySelect } from '../CMySelect'
import { CMyEditor } from '../CMyEditor'
@Component({
name: 'CMyPopupEdit',
components: {CMyChipList, CDateTime, CMyToggleList, CMySelect}
components: {CMyChipList, CDateTime, CMyToggleList, CMySelect, CMyEditor}
})
export default class CMyPopupEdit extends Vue {
@@ -21,6 +22,7 @@ export default class CMyPopupEdit extends Vue {
@Prop({ required: false, default: false }) public canEdit
@Prop({ required: false, default: '' }) public field
@Prop({ required: false, default: '' }) public subfield
@Prop({ required: false, default: false }) public showall
public myvalue = ''
@@ -75,6 +77,13 @@ export default class CMyPopupEdit extends Vue {
this.$emit('save', newVal, valinitial)
}
public Savedb(newVal, valinitial) {
// console.log('Savedb', newVal)
this.$emit('showandsave', this.row, this.col, newVal, valinitial)
}
public visuValByType(val, col: IColGridTable, row) {
if (col === undefined || row === undefined)
return
@@ -118,7 +127,12 @@ export default class CMyPopupEdit extends Vue {
else if (val === '') {
return '[]'
} else {
let mystr = tools.firstchars(val, tools.MAX_CHARACTERS)
let mystr = ''
if (this.showall) {
return val
} else {
mystr = tools.firstchars(val, tools.MAX_CHARACTERS)
}
if (val) {
if (val.length > tools.MAX_CHARACTERS)
mystr += '...'
@@ -132,7 +146,7 @@ export default class CMyPopupEdit extends Vue {
public getclassCol(col) {
if (col) {
let mycl = (col.disable || !this.canEdit) ? '' : 'colmodif'
let mycl = (col.disable) ? '' : 'colmodif'
mycl += (col.fieldtype === tools.FieldType.date) ? ' coldate flex flex-container' : ''
return mycl

View File

@@ -32,6 +32,10 @@
:optlab="db_fieldsTable.getLabelByTable(col.jointable)"
:opticon="db_fieldsTable.getIconByTable(col.jointable)"></CMyChipList>
</div>
<div v-else-if="col.fieldtype === tools.FieldType.boolean">
<q-toggle dark color="green" v-model="myvalue" :label="col.title"
@input="Savedb"></q-toggle>
</div>
<div v-else>
{{ visuValByType(myvalue, col, row) }}
</div>
@@ -65,6 +69,15 @@
<div v-else-if="col.fieldtype === tools.FieldType.string">
<q-input v-model="myvalue"
autogrow
@keyup.enter.stop
autofocus>
</q-input>
</div>
<div v-else-if="col.fieldtype === tools.FieldType.password">
<q-input v-model="myvalue"
type="password"
@keyup.enter.stop
autofocus>
</q-input>
@@ -84,10 +97,13 @@
</CMyToggleList>
</div>
<div v-else-if="col.fieldtype === tools.FieldType.html">
<q-input v-model="myvalue"
autofocus
@keyup.enter.stop
type="textarea"></q-input>
<CMyEditor :value.sync="myvalue" :title="col.title" @keyup.enter.stop>
</CMyEditor>
<!--<q-input v-model="myvalue"-->
<!--autofocus-->
<!--@keyup.enter.stop-->
<!--type="textarea"></q-input>-->
</div>
<div v-else-if="col.fieldtype === tools.FieldType.select">
<CMySelect :label="col.title"