forked from erupts/erupt-web
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
281 changed files
with
98,206 additions
and
2,337 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
src/app/build/erupt/components/ueditor/ueditor.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<ueditor [name]="eruptField.fieldName" [(ngModel)]="eruptField.eruptFieldJson.edit.$value" | ||
[config]="{serverUrl:serverPath,readonly:eruptField.eruptFieldJson.edit.readOnly}"></ueditor> |
33 changes: 33 additions & 0 deletions
33
src/app/build/erupt/components/ueditor/ueditor.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import {Component, EventEmitter, Inject, Input, OnInit, Output} from '@angular/core'; | ||
import {EruptFieldModel} from "../../model/erupt-field.model"; | ||
import {EruptModel} from "../../model/erupt.model"; | ||
import {RestPath} from "../../model/erupt.enum"; | ||
import {DA_SERVICE_TOKEN, ITokenService, TokenService} from "@delon/auth"; | ||
import {WindowModel} from "@shared/model/window.model"; | ||
|
||
@Component({ | ||
selector: 'erupt-ueditor', | ||
templateUrl: './ueditor.component.html', | ||
styles: [] | ||
}) | ||
export class UeditorComponent implements OnInit { | ||
|
||
@Input() eruptField: EruptFieldModel; | ||
|
||
@Input() erupt: EruptModel; | ||
|
||
serverPath: string; | ||
|
||
constructor(@Inject(DA_SERVICE_TOKEN) private tokenService: ITokenService) { | ||
} | ||
|
||
ngOnInit() { | ||
let rf = RestPath.file; | ||
if (!WindowModel.domain) { | ||
rf = "/" + rf; | ||
} | ||
this.serverPath = rf + "/upload-ueditor/" + this.erupt.eruptName + "/" + | ||
this.eruptField.fieldName + "?_erupt=" + this.erupt.eruptName + "&_token=" + this.tokenService.get().token; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" | ||
"http:https://www.w3.org/TR/html4/loose.dtd"> | ||
<html> | ||
<head> | ||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> | ||
<title></title> | ||
<style type="text/css"> | ||
*{color: #838383;margin: 0;padding: 0} | ||
html,body {font-size: 12px;overflow: hidden; } | ||
.content{padding:5px 0 0 15px;} | ||
input{width:210px;height:21px;line-height:21px;margin-left: 4px;} | ||
</style> | ||
</head> | ||
<body> | ||
<div class="content"> | ||
<span><var id="lang_input_anchorName"></var></span><input id="anchorName" value="" /> | ||
</div> | ||
<script type="text/javascript" src="../internal.js"></script> | ||
<script type="text/javascript"> | ||
var anchorInput = $G('anchorName'), | ||
node = editor.selection.getRange().getClosedNode(); | ||
if(node && node.tagName == 'IMG' && (node = node.getAttribute('anchorname'))){ | ||
anchorInput.value = node; | ||
} | ||
anchorInput.onkeydown = function(evt){ | ||
evt = evt || window.event; | ||
if(evt.keyCode == 13){ | ||
editor.execCommand('anchor', anchorInput.value); | ||
dialog.close(); | ||
domUtils.preventDefault(evt) | ||
} | ||
}; | ||
dialog.onok = function (){ | ||
editor.execCommand('anchor', anchorInput.value); | ||
dialog.close(); | ||
}; | ||
$focus(anchorInput); | ||
</script> | ||
</body> | ||
</html> |
Oops, something went wrong.