Browse Source

文章编辑

XMTT 7 years ago
parent
commit
3faff56cb9

+ 5 - 0
css/model/sys/article.css

@ -26,4 +26,9 @@
26 26
.sys_article_sort .content{
27 27
    font-size: 25px;
28 28
    font-weight: bold;
29
}
30
31
.sys_article_relate {
32
    width: 800px;
33
    height: 800px;
29 34
}

+ 144 - 114
css/model/sys/articleModify.css

@ -76,6 +76,10 @@ select[multiple], select[size] { height: auto; }
76 76
select optgroup { font-family: inherit; font-size: inherit; font-style: inherit; }
77 77
input[type="file"]:focus, input[type="radio"]:focus, input[type="checkbox"]:focus { outline: -webkit-focus-ring-color auto 5px; outline-offset: -2px; }
78 78
input[type="number"]::-webkit-outer-spin-button, input[type="number"]::-webkit-inner-spin-button { height: auto; }
79
.has-warning .help-block, .has-warning .control-label { color: rgb(192, 152, 83); }
80
.has-error .help-block, .has-error .control-label { color: rgb(185, 74, 72); }
81
.has-success .help-block, .has-success .control-label { color: rgb(70, 136, 71); }
82
.help-block { display: block; margin-top: 5px; margin-bottom: 10px; color: rgb(115, 115, 115); }
79 83
.clearfix::before, .clearfix::after { display: table; content: " "; }
80 84
.clearfix::after { clear: both; }
81 85
.webuploader-container { position: relative; text-align: center; }
@ -101,6 +105,11 @@ ul, ol { list-style: none; }
101 105
button, input, select, textarea { font-size: 100%; }
102 106
table { border-collapse: collapse; border-spacing: 0px; }
103 107
a, a:active, a:hover { outline: 0px; text-decoration: none; }
108
[class^="icon-"], [class*=" icon-"] { display: inline-block; width: 14px; height: 14px; line-height: 14px; vertical-align: text-top; background-image: url("../images/glyphicons-halflings.png"); background-position: 14px 14px; background-repeat: no-repeat; margin-top: 1px; }
109
body { height: auto; position: relative; min-height: 100%; }
110
a { text-decoration: none; }
111
a:focus { }
112
a:active, a:hover { outline: 0px; text-decoration: none; }
104 113
.floatL { float: left; }
105 114
.floatR { float: right; }
106 115
.clearfix { clear: both; }
@ -108,37 +117,90 @@ a, a:active, a:hover { outline: 0px; text-decoration: none; }
108 117
.clearfix::after { clear: both; }
109 118
input::-webkit-input-placeholder, textarea::-webkit-input-placeholder { color: rgb(153, 153, 153); }
110 119
.displayNone { display: none; }
111
.h2Font { font-size: 18px; line-height: 30px; color: rgb(51, 51, 51); }
112
.frmtype { width: 100%; border-radius: 5px; border: 1px solid rgb(218, 218, 218); padding: 0px 10px; min-height: 30px; font-size: 14px; line-height: 30px; }
113
textarea.frmtype { line-height: 20px; padding: 6px 8px; min-height: 100px; }
114
.frmtype:focus { border: 1px solid rgb(255, 133, 0); box-shadow: none; outline: none; }
115
body { height: auto; position: relative; min-height: 100%; }
116
input { outline: none; }
117
.containerCon { width: 1120px; padding: 0px 10px; position: relative; margin: auto; clear: both; }
120
.cmpRadius { border-radius: 4px; }
121
.bgRadius { border-radius: 6px; }
122
.frmtype { border: 1px solid rgb(210, 210, 210); height: 36px; background: rgb(245, 246, 248); font-size: 14px; outline: none; padding: 6px 20px 6px 10px; border-radius: 6px; }
123
.frmtype:focus { box-shadow: none; outline: none; border: 1px solid rgb(40, 184, 250); }
124
textarea.frmtype { height: 100px; }
125
.requiredcon { color: red; font-size: 16px; margin: 0px 4px; }
126
.frmcontype { border: 1px solid rgb(229, 229, 229); width: 100%; height: 40px; background: rgb(255, 255, 255); font-size: 16px; color: rgb(102, 102, 102); line-height: 28px; outline: none; padding: 6px 12px; border-radius: 0px; }
127
.frmcontype:focus { border-color: rgb(40, 184, 250); }
128
.frmconmsg { color: rgb(253, 95, 57); margin-left: 12px; font-size: 14px; }
129
.modelContain { display: none; position: relative; clear: both; top: 20%; margin: 40px auto; width: 600px; background: rgb(255, 255, 255); border-radius: 8px; z-index: 1056; box-shadow: rgb(85, 85, 85) 2px 4px 10px 4px; }
130
.modelContain::before, .modelContain::after { display: table; content: " "; }
131
.modelContain::after { clear: both; }
132
#container { padding-top: 40px; }
133
.containerCon { width: 1120px; padding: 0px 10px; position: relative; margin: auto; }
118 134
.containerCon::before, .containerCon::after { display: table; content: " "; }
119 135
.containerCon::after { clear: both; }
120 136
footer { position: absolute; right: 0px; left: 0px; bottom: 0px; background: rgb(55, 61, 65); color: rgb(136, 136, 136); font-size: 14px; line-height: 30px; }
121 137
footer .containerCon { background: rgb(55, 61, 65); }
122 138
footer a { color: rgb(136, 136, 136); text-decoration: none; }
123
.topheader .containerCon { background: rgb(51, 51, 51); }
124
header { position: fixed; top: 0px; left: 0px; right: 0px; z-index: 1000; font-size: 16px; line-height: 32px; }
125
html, body { background: rgb(244, 246, 248); }
126
.frmtype { outline: none; border-radius: 6px; }
127
.frmtype:focus { box-shadow: none; outline: none; border: 1px solid rgb(255, 133, 0); }
128
textarea.frmtype { height: 100px; }
129
.requiredcon { color: red; font-size: 16px; }
130
.frmcontype { width: 100%; border: 1px solid rgb(229, 229, 229); height: 40px; background: rgb(255, 255, 255); font-size: 16px; color: rgb(102, 102, 102); line-height: 28px; outline: none; padding: 6px 12px; border-radius: 0px; }
131
.frmcontype:focus { border-color: rgb(255, 153, 0); }
132
.frmconmsg { color: rgb(253, 95, 57); margin-left: 12px; font-size: 14px; }
133
.contentCon { padding-top: 80px; }
139
footer p .listlink { margin-right: 25px; color: rgb(136, 136, 136); }
140
footer .bottom-block { padding: 30px 0px; }
141
footer .logo-block { width: 271px; height: 60px; background: url("../images/business_icon_logo_nor.png") 0% 0% / cover; margin-bottom: 30px; }
142
footer .copy-block { color: rgb(102, 102, 102); margin-top: 10px; font-size: 12px; }
143
footer .copy-block a { color: rgb(102, 102, 102); }
144
footer .copy-block a.beianbox em { display: inline-block; width: 14px; height: 14px; background: url("../images/home_icon_beian.png") 0% 0% / cover; }
145
footer .code-block div { text-align: center; }
146
footer .code-block div:last-child { margin-left: 80px; }
147
footer .codelist { margin: 20px auto 10px; width: 118px; height: 118px; text-align: center; background-position: center center; background-repeat: no-repeat; }
148
footer .codelist span { display: inline-block; width: 94px; height: 94px; margin: 12px auto; }
149
footer .appcode { background-image: url("../images/home_bg_xiazaiapp_nor.png"); }
150
footer .appcode span { background-image: url("../images/home_code_app.jpg"); background-size: cover; }
151
footer .weixincode { background-image: url("../images/home_bg_guanzhu_nor.png"); }
152
footer .weixincode span { background-image: url("../images/home_code_weixin.jpg"); background-size: cover; }
153
header { position: fixed; top: 0px; left: 0px; right: 0px; z-index: 1012; font-size: 16px; line-height: 32px; }
154
header .navheader { background: rgb(255, 255, 255); height: 62px; border-bottom: 2px solid rgb(229, 229, 229); }
155
header .topheader { background: rgb(51, 51, 51); height: 30px; font-size: 14px; line-height: 30px; }
156
header .topheader .containerCon { background: rgb(51, 51, 51); }
157
header .topheader a { padding: 0px 10px; margin-right: 16px; color: rgb(196, 195, 195); }
158
header .topheader a:hover { color: rgb(255, 255, 255); }
159
header .topheader .downicon { background: url("../images/top_icon_shouji_nor.png") 0px center no-repeat; padding-left: 18px; }
160
header .headlogo h1 { width: 60px; height: 30px; margin: 15px 14px 15px 0px; padding: 0px; background-image: url("../images/home_icon_cmplogo.png"); background-repeat: no-repeat; background-size: contain; overflow: hidden; }
161
header .headuserimg { position: relative; padding: 10px 0px 10px 20px; width: 60px; height: 60px; }
162
header .headuser { overflow: hidden; border: 1px solid rgb(229, 229, 229); width: 42px; height: 42px; display: table-cell; vertical-align: middle; text-align: center; cursor: pointer; }
163
header .headuser img { max-width: 40px; max-height: 100%; vertical-align: middle; overflow-y: auto; height: auto !important; }
164
header .headnavbtn { margin: 14px 6px; }
165
header .headnavbtn a { color: rgb(102, 102, 102); }
166
header .headnavbtn li { float: right; margin: 0px 6px; }
167
header .navheader li a:hover { color: rgb(40, 184, 250); }
168
header .navheader li.navcurrent a { color: rgb(40, 184, 250); }
169
header .comuserSelf { width: 180px; height: 180px; position: absolute; top: 42px; right: 0px; z-index: 100; }
170
header .triangleB { display: block; width: 0px; height: 0px; border-width: 8px; border-style: solid; border-color: transparent transparent rgb(40, 184, 250); border-image: initial; float: right; margin-right: 12px; margin-top: 14px; }
171
header .personal-box { width: 100%; background: rgb(40, 184, 250); clear: both; overflow: hidden; }
172
header .personal-box a { display: block; width: 100%; height: 40px; line-height: 40px; font-size: 13px; color: rgb(255, 255, 255); }
173
header .personal-box a:hover { background: rgb(23, 164, 228); }
174
header .icon { display: block; width: 20px; height: 20px; margin-left: 15px; margin-right: 12px; margin-top: 10px; float: left; }
175
header .icon3 { background: url("../images/index-icon.png") -40px 0px no-repeat; }
176
header .icon4 { background: url("../images/index-icon.png") -20px 0px no-repeat; }
177
body, html { background: rgb(244, 246, 248); }
178
.btnBlock .frmtype { display: block; width: 140px; }
179
.webuploader-container { background: rgba(0, 0, 0, 0.4); bottom: 90px; }
180
.uploadInp .webuploader-pick { background: none; height: 85px; width: 100%; margin: 0px; line-height: 85px; }
181
.uploadInp .webuploader-element-invisible { height: 90px; }
182
.cmpFrmList > li .frmadd { width: auto; position: absolute; right: 0px; top: 0px; background: rgb(40, 184, 250); color: rgb(255, 255, 255); border: none; padding: 6px 25px; }
183
.keyResult > ul.editUlist, .keyResult > ul.editUlistC { width: 98%; margin-right: -30px; margin-bottom: 0px; }
184
.keyResult > ul.editUlistC > li, .keyResult > ul.editUlist > li { position: relative; padding: 6px 12px; background: rgb(255, 255, 255); border-radius: 0px; margin-bottom: 0px; }
185
.keyResult > ul.editUlist > li { float: left; }
186
.keyResult > ul.editUlistC > li { width: 100%; margin-top: 12px; }
187
.saveBtn .frmcontype { width: 120px; margin-right: 30px; margin-top: 20px; }
188
.citybox .frmtype { border: 1px solid rgb(181, 181, 181); }
189
.uploadFile { line-height: 30px; text-align: center; }
190
.uploadFile .uploadlogo { width: 98%; padding: 16px 0px; border: 2px dashed rgb(214, 214, 214); border-radius: 6px; background: rgb(245, 250, 255); color: rgb(102, 102, 102); }
191
.uploadFile input.uploadInp[type="file"] { height: 96px; }
192
.uploadFile .uploadlogo .upBack { padding: 0px 10px; }
193
.uploadFile .uploadlogo .upBack a { color: rgb(40, 184, 250); }
194
.uploadFile .uploadlogo .upBack a:hover { color: rgb(29, 170, 235); }
195
ul.cmpAllUl.cmpBindul .frmtype { height: 40px; }
196
ul.cmpAllUl.cmpSettledul .frmtype { height: 40px; }
197
.rightRequ .requiredcon { top: 2px; right: -6px; left: auto; }
198
.contentCon { }
134 199
.leftconBox { width: 820px; padding-bottom: 20px; margin-bottom: 20px; background: rgb(255, 255, 255); }
135 200
.conBlock .leftconBox { width: 820px; padding: 30px; position: relative; }
136
.rightconBox { width: 260px; margin-left: 20px; }
137
.rightconBox .conItem { padding: 30px 20px; background: rgb(255, 255, 255); margin-bottom: 20px; }
138
.rightconBox .conItem .form-result { margin: 18px -20px 0px; }
139
.rightconBox .conItem .form-result.form-M0 { margin-top: 0px; }
140
.rightconBox .conItem .form-result > ul > li { padding: 8px 20px; }
141
.conBlock .rightconBox .conItem:first-child { padding: 30px 20px; border-top: 4px solid rgb(255, 153, 0); }
201
.conBlock .rightconBox { width: 260px; margin-left: 20px; }
202
.conBlock .rightconBox .conItem { padding: 15px; background: rgb(255, 255, 255); margin-bottom: 20px; }
203
.conBlock .rightconBox .conItem:first-child { padding: 30px 10px; border-top: 4px solid rgb(40, 184, 250); }
142 204
ul.artAbout > li { clear: both; }
143 205
ul.artAbout > li::before, ul.artAbout > li::after { display: table; content: " "; }
144 206
ul.artAbout > li::after { clear: both; }
@ -150,81 +212,67 @@ ul.artAbout .uploadFile input.upInp[type="file"] { position: absolute; height: 4
150 212
ul.artAbout .uploadFile .upbtn { display: inline-block; padding: 7px 23px; background: rgb(229, 229, 229); color: rgb(51, 51, 51); margin-top: 30px; }
151 213
ul.artAbout .uploadFile .uploadblock .upBackbtn { position: absolute; bottom: 30px; left: 50%; margin-left: -55px; background: rgba(0, 0, 0, 0.5); color: rgb(255, 255, 255); z-index: 10; display: none; }
152 214
.conBlock .aboutTit { font-size: 16px; line-height: 40px; color: rgb(102, 102, 102); margin-top: 18px; }
153
ul.artAbout #filePicker { position: absolute; left: 50%; bottom: 25px; margin-left: -52px; opacity: 0; z-index: 88; }
154
ul.artAbout .frmadd { width: auto; position: absolute; right: 0px; top: 0px; background: rgb(255, 153, 0); color: rgb(255, 255, 255); border: none; padding: 6px 25px; z-index: 4; }
155
.conItem ul.operateBlock { overflow: hidden; margin-top: -30px; }
156
.conItem ul.operateBlock > li { font-size: 15px; color: rgb(102, 102, 102); float: left; width: 33.333%; margin-top: 30px; text-align: center; cursor: pointer; }
215
ul.artAbout #filePicker { position: absolute; left: 50%; bottom: 22px; margin-left: -52px; opacity: 0; z-index: 88; }
216
ul.artAbout .frmadd { width: auto; position: absolute; right: 0px; top: 0px; background: rgb(40, 184, 250); color: rgb(255, 255, 255); border: none; padding: 6px 25px; z-index: 4; }
217
.conItem ul.operateBlock { overflow: hidden; margin-top: -20px; }
218
.conItem ul.operateBlock > li { font-size: 15px; color: rgb(102, 102, 102); float: left; width: 33.333%; margin-top: 20px; text-align: center; cursor: pointer; }
157 219
.conItem ul.operateBlock > li p { margin-top: 6px; }
158 220
.operateicon { display: inline-block; width: 18px; height: 18px; background-position: center center; background-repeat: no-repeat; background-size: cover; }
159
.operateicon.icon-issue { background-image: url("../images/g_article_icon_fabu_hig.png"); }
160
.conItem ul.operateBlock > li:hover { color: rgb(255, 153, 0); }
161
.conItem ul.operateBlock > li.goFabu { color: rgb(255, 153, 0); opacity: 0.8; }
221
.operateicon.icon-issue { background-image: url("/images/g_article_icon_fabu_lan_hig.png"); }
222
.operateicon.icon-timeissue { background-image: url("../../images/g_article_icon_dingshi_nor.png"); }
223
.operateicon.icon-preview { background-image: url("../../images/g_article_icon_yulan_nor.png"); }
224
.operateicon.icon-draft { background-image: url("../../images/g_article_icon_caogao_nor.png"); }
225
.operateicon.icon-delete { background-image: url("../../images/g_article_icon_shanchu_nor.png"); }
226
.conItem ul.operateBlock > li:hover { color: rgb(40, 184, 250); }
227
.conItem ul.operateBlock > li.goFabu { color: rgb(40, 184, 250); opacity: 0.8; }
162 228
.conItem ul.operateBlock > li.goFabu:hover { opacity: 1; }
163
.conItem ul.operateBlock > li:hover .operateicon.icon-timeissue { background-image: url("../images/g_article_icon_dingshi_hig.png"); }
164
.conItem ul.operateBlock > li:hover .operateicon.icon-preview { background-image: url("../images/g_article_icon_yulan_hig.png"); }
165
.conItem ul.operateBlock > li:hover .operateicon.icon-draft { background-image: url("../images/g_article_icon_caogao_hig.png"); }
166
.conItem ul.operateBlock > li:hover .operateicon.icon-delete { background-image: url("../images/g_article_icon_shanchu_hig.png"); }
167
.conItem ul.operateBlock > li:hover .operateicon.icon-feedback { background-image: url("../images/g_article_icon_jiucuo_hig.png"); }
229
.conItem ul.operateBlock > li:hover .operateicon.icon-timeissue { background-image: url("../images/g_article_icon_dingshi_lan_hig.png"); }
230
.conItem ul.operateBlock > li:hover .operateicon.icon-preview { background-image: url("../images/g_article_icon_yulan_lan_hig.png"); }
231
.conItem ul.operateBlock > li:hover .operateicon.icon-draft { background-image: url("../images/g_article_icon_caogao_lan_hig.png"); }
232
.conItem ul.operateBlock > li:hover .operateicon.icon-delete { background-image: url("../images/g_article_icon_shanchu_lan_hig.png"); }
168 233
.conItem ul.operateBlock > li.disableLi { opacity: 0.5; cursor: auto; }
169 234
.conItem ul.operateBlock > li.disableLi:hover { color: rgb(102, 102, 102); }
170
.conItem ul.operateBlock > li.disableLi:hover .operateicon.icon-delete { background-image: url("../images/g_article_icon_shanchu_nor.png"); }
235
.conItem ul.operateBlock > li.disableLi:hover .operateicon.icon-delete { background-image: url("../../images/g_article_icon_shanchu_nor.png"); }
171 236
.conItem .aboutTit { margin-top: -10px; }
172
.conItem .otherBlock { padding-bottom: 30px; border-bottom: 1px dashed rgb(229, 229, 229); margin-bottom: 30px; text-align: left; }
237
.conItem .otherBlock { padding-bottom: 30px; border-bottom: 1px dashed rgb(229, 229, 229); margin-bottom: 30px; }
173 238
.conItem .otherBlock:last-child { padding: 0px; margin: 0px; border: 0px; }
174
.rightconBox .conItem .currentArt.form-result { margin-top: 0px; }
175
.rightconBox .conItem .currentArt.form-result li { padding: 6px 20px; min-height: 62px; }
176
.rightconBox .conItem.conItemG .currentArt.form-result .ellipsisSty-2 { max-height: 42px; line-height: 20px; }
177
.rightconBox .conItem.conItemG .currentArt.form-result .smalltip { display: inline-block; color: rgb(153, 153, 153); margin-top: 6px; }
178
.rightconBox .conItem.conItemG .currentBlock { margin-top: 30px; padding-top: 16px; border-top: 1px solid rgb(229, 229, 229); }
179
.rightconBox .conItem.conItemG .currentBlock .madiaHead { width: 50px; height: 50px; margin-top: -25px; }
180
.conItem .otherBlock.currentBlock { border: none; margin-bottom: 0px; padding-bottom: 0px; }
239
.form-item { }
181 240
.form-drop { position: relative; top: -1px; border-right: 1px solid rgb(229, 229, 229); border-bottom: 1px solid rgb(229, 229, 229); border-left: 1px solid rgb(229, 229, 229); border-image: initial; border-top: none; width: 100%; z-index: 0; }
182 241
.form-item input.frmcontype { position: relative; z-index: 2; }
183
.form-item .frmaddG { display: none; width: auto; position: absolute; right: 0px; top: 0px; background: rgb(255, 153, 0); color: rgb(255, 255, 255); border: none; padding: 6px 25px; z-index: 6; }
184
.form-item .madiaHead { position: absolute; width: 50px; height: 50px; top: 50%; margin-top: -25px; background-position: center center; background-size: cover; }
185
.form-item .madiaHead.useHead { background-image: url("../images/default-photo.jpg"); border-radius: 50%; }
186
.form-item .madiaHead.cmpHead { background: rgb(255, 255, 255); border-radius: 0px; }
187
.form-item .madiaHead.cmpHead .boxBlock { width: 118px; height: 80px; }
188
.form-item .madiaHead.resouseHead { background-image: url("../images/default-resource.jpg"); border-radius: 0px; }
189
.form-item .madiaHead.paperHead { background-image: url("../images/default-paper.jpg"); border-radius: 0px; }
190
.form-item .madiaHead.patentHead { background-image: url("../images/default-patent.jpg"); border-radius: 0px; }
191
.form-item .madiaHead.artHead { background-image: url("../images/default-artical.jpg"); border-radius: 0px; }
242
.form-item .frmadd { z-index: 6; }
243
.form-item .madiaHead { position: absolute; border: 1px solid rgb(229, 229, 229); width: 50px; height: 50px; top: 50%; margin-top: -25px; background-position: center center; background-size: cover; }
244
.form-item .madiaHead.useHead { background-image: url("../../images/default-photo.jpg"); border-radius: 50%; }
245
.form-item .madiaHead.resouseHead { background-image: url("../../images/default-resource.jpg"); border-radius: 0px; }
246
.form-item .madiaHead.artHead { background-image: url("../../images/default-artical.jpg"); border-radius: 0px; }
192 247
.form-item .madiaInfo { width: 100%; padding-left: 62px; margin: 2px 0px; }
193
.form-item ul .h1Font { font-size: 16px; color: rgb(51, 51, 51); line-height: 20px; margin-bottom: 4px; }
194
.form-item ul .h2Font { font-size: 14px; color: rgb(102, 102, 102); line-height: 22px; }
195
.form-item ul .h3Font { font-size: 13px; color: rgb(153, 153, 153); line-height: 20px; }
196
.form-item ul .circlePre { display: inline-block; content: ""; width: 5px; height: 5px; border-radius: 50%; background: rgb(255, 153, 0); position: relative; top: -3px; margin-right: 5px; }
248
.form-item ul .h1Font { font-size: 16px; color: rgb(51, 51, 51); line-height: 24px; }
249
.form-item ul .h2Font { font-size: 14px; color: rgb(102, 102, 102); line-height: 24px; }
197 250
.form-drop > ul > li { position: relative; min-height: 76px; padding: 12px; cursor: pointer; background: rgb(255, 255, 255); }
198 251
.form-drop > ul > li:hover { background: rgb(238, 238, 238); }
199
.form-drop > ul > li:active { background: rgb(255, 153, 0); color: rgb(255, 255, 255); }
252
.form-drop > ul > li:active { background: rgb(40, 184, 250); color: rgb(255, 255, 255); }
200 253
.form-drop > ul > li:active .h1Font, .form-drop > ul > li:active .h2Font { color: rgb(255, 255, 255); }
201
.form-result { margin: 18px -30px 0px; }
202
.form-result > ul > li { position: relative; padding: 8px 30px; min-height: 76px; }
203
.form-result > ul > li > a { width: 100%; }
204
.form-result > ul > li .deleteThis { display: none; position: absolute; top: 50%; margin-top: -16px; right: 28px; width: 32px; height: 32px; background: url("../images/g_article_button_shanchu_hig.png") 0% 0% / cover; cursor: pointer; }
254
.form-result { margin: 18px -15px 0px; }
255
.form-result > ul > li { position: relative; padding: 12px 15px; min-height: 76px; }
256
.form-result > ul > li .deleteThis { display: none; position: absolute; top: 50%; margin-top: -16px; right: 14px; width: 32px; height: 32px; background: url("../../images/g_article_button_shanchu_hig.png") 0% 0% / cover; cursor: pointer; }
205 257
.form-result > ul > li:hover { background: rgb(238, 238, 238); }
206 258
.form-result > ul > li:hover .deleteThis { display: block; }
207 259
.form-drop.keydrop > ul > li { min-height: auto; padding: 8px 12px; }
208 260
.form-result.keyResult { margin: 18px -20px 0px 0px; }
209 261
.keyResult > ul { margin-bottom: -10px; }
210 262
.keyResult > ul > li { float: left; margin-right: 20px; margin-bottom: 10px; padding: 2px 12px; color: rgb(153, 153, 153); border: 1px solid rgb(229, 229, 229); border-radius: 20px; min-height: auto; }
211
.keyResult > ul > li .closeThis { display: none; position: absolute; top: -8px; right: -12px; width: 28px; height: 28px; background: url("../images/g_article_button_guanbi_hig.png") 0% 0% / cover; cursor: pointer; }
263
.keyResult > ul > li .closeThis { display: none; position: absolute; top: -8px; right: -12px; width: 28px; height: 28px; background: url("/images/g_article_button_guanbi_lan_hig.png") 0% 0% / cover; cursor: pointer; }
212 264
.keyResult > ul > li:hover { background: rgb(229, 229, 229); }
213 265
.keyResult > ul > li:hover .closeThis { display: block; }
214
.showDetail .h2Font { font-size: 14px; color: rgb(153, 153, 153); }
215
ul.tagList > li .h2Font { color: rgb(102, 102, 102); }
216 266
.otherShow .aboutTit { font-size: 18px; color: rgb(102, 102, 102); }
217 267
.otherShow .form-result { margin: 0px -30px; }
218
.commentsArea.form-item ul.commentList .madiaHead.useHeadMsg { top: 10px; margin-top: 0px; }
219
.commentsArea ul.commentList > li .h2Font { font-size: 16px; color: rgb(102, 102, 102); line-height: 26px; }
268
.otherShow .form-result > ul > li { min-height: 104px; }
220 269
.rightconBox .conItem.conItemG .madiaHead { width: 100px; height: 100px; border: 1px solid rgb(229, 229, 229); margin: 0px auto 10px; background-position: center center; background-size: cover; }
221
.rightconBox .conItem.conItemG .madiaHead.useHead { background-image: url("../images/default-photo.jpg"); border-radius: 50%; }
222
.rightconBox .conItem.conItemG .madiaHead.cmpHead { background: rgb(255, 255, 255); border: none; width: 200px; height: 120px; }
223
.rightconBox .conItem.conItemG .madiaHead.cmpHead .boxBlock { width: 198px; height: 118px; }
270
.rightconBox .conItem.conItemG .madiaHead.useHead { background-image: url("../../images/default-photo.jpg"); border-radius: 50%; }
271
.rightconBox .conItem.conItemG .madiaHead.cmpHead { background-image: url("../../images/default-icon.jpg"); }
224 272
.rightconBox .conItem.conItemG .h1Font { font-size: 16px; }
225 273
.rightconBox .conItem.conItemG .h2Font { font-size: 14px; color: rgb(102, 102, 102); line-height: 26px; }
226 274
.rightconBox .conItem.conItemG .h3Font > a { color: rgb(51, 51, 51); }
227
.itemListBolck .searchAbout .frmcontype { height: 36px; font-size: 14px; }
275
.itemListBolck .searchAbout .frmcontype { height: 36px; font-size: 14px; line-height: 22px; }
228 276
.itemListBolck .frmcontype { width: 100%; border-radius: 20px; padding-left: 20px; background: rgb(245, 246, 248); }
229 277
.itemListBolck .itemListCon .form-result > ul > li { padding: 20px; cursor: pointer; }
230 278
.itemListBolck .itemListCon .form-result > ul > li::after { content: ""; position: absolute; left: 0px; right: 0px; bottom: 0px; height: 2px; background: rgb(244, 246, 248); }
@ -232,23 +280,35 @@ ul.tagList > li .h2Font { color: rgb(102, 102, 102); }
232 280
.itemListBolck .itemListCon .form-result { margin: 20px 0px 30px; border-top: 1px solid rgb(229, 229, 229); }
233 281
.itemListCon.form-item ul .h1Font { font-size: 18px; }
234 282
.itemListCon .form-result > ul > li .madiaEdit > li { float: left; margin-right: 28px; }
235
.itemListCon .form-result > ul > li .madiaEdit .editThis { display: inline-block; width: 60px; height: 32px; background: url("../images/g_article_button_xiugai_hig.png") 0% 0% / cover; cursor: pointer; }
236
.itemListCon .form-result > ul > li .madiaEdit .deteleThis2 { display: inline-block; width: 32px; height: 32px; background: url("../images/g_article_button_shanchu_hig.png") 0% 0% / cover; cursor: pointer; }
283
.itemListCon .form-result > ul > li .madiaEdit .editThis { display: inline-block; width: 60px; height: 32px; background: url("../images/g_article_button_xiugai_lan_hig.png") 0% 0% / cover; cursor: pointer; }
284
.itemListCon .form-result > ul > li .madiaEdit .deteleThis2 { display: inline-block; width: 32px; height: 32px; background: url("../../images/g_article_button_shanchu_hig.png") 0% 0% / cover; cursor: pointer; }
285
.itemListCon .form-result > ul > li .madiaEdit .closeThis { color: rgb(255, 0, 0); }
237 286
.itemListCon .form-result > ul > li .madiaEdit { display: none; overflow: hidden; position: absolute; top: 50%; margin-top: -16px; right: 0px; }
238 287
.itemListCon .form-result > ul > li:hover .madiaEdit { display: block; }
239
.blackcover2 { display: none; overflow-x: hidden; overflow-y: auto; position: fixed; top: 0px; right: 0px; bottom: 0px; left: 0px; background: rgba(0, 0, 0, 0.5); z-index: 1000; }
288
.blackcover2 { display: none; overflow-x: hidden; overflow-y: auto; position: fixed; top: 0px; right: 0px; bottom: 0px; left: 0px; background: rgba(0, 0, 0, 0.5); z-index: 1050; }
289
.setTimeBlock { z-index: 999999; width: 400px; position: fixed; background-color: white; border-radius: 6px; box-shadow: rgb(102, 102, 102) 1px 1px 20px 4px; top: 50%; left: 50%; margin: -167px 0px 0px -200px; }
290
.setTimeBlock .mb_tit { display: block; font-size: 18px; color: rgb(255, 255, 255); background-color: rgb(40, 184, 250); line-height: 60px; text-align: center; border-radius: 6px 6px 0px 0px; }
291
.setTimeBlock .mb_close { display: block; position: absolute; right: 20px; top: 18px; background: url("/images/sign_icon_guanbi_nor.png") center center no-repeat; width: 20px; height: 20px; cursor: pointer; }
292
.setTimeBlock .mb_msg { position: relative; padding: 30px 40px 20px; line-height: 24px; text-align: center; font-size: 16px; }
293
.setTimeBlock .mb_msg .mb-list { margin: 6px 6px 12px; }
294
.setTimeBlock .mb_msg .mb-list p { margin: 6px; }
295
.setTimeBlock .mb_btnbox { margin: 0px auto 30px; text-align: center; position: relative; }
296
.setTimeBlock .mb_btn { width: 100px; font-size: 14px; height: 32px; color: white; border: none; background-image: none; padding: 0px; margin: 0px 10px; border-radius: 6px; }
297
.setTimeBlock .mb_btnOk { background-color: rgb(40, 184, 250); }
298
.setTimeBlock .mb_btnNo { background-color: rgb(204, 204, 204); }
240 299
.artAbout > li > dl { margin-top: -10px; margin-right: -15px; height: 200px; overflow: hidden; padding-top: 10px; }
241 300
.artAbout > li > dl > dd { position: relative; float: left; width: 31.2%; border: 1px solid rgb(229, 229, 229); height: 190px; margin-right: 15px; }
242
.artAbout > li > dl > dd:nth-child(2), .artAbout > li > dl > dd:nth-child(3) { background: url("../images/g_resource_bg_tianjia_nor.png") center center no-repeat; }
301
.artAbout > li > dl > dd:nth-child(2), .artAbout > li > dl > dd:nth-child(3) { background: url("../../images/g_resource_bg_tianjia_nor.png") center center no-repeat; }
243 302
.artAbout > li > dl > dd.uploadD { background: none; }
244 303
.artAbout > li > dl > dd .imgItem { background: rgb(255, 255, 255); display: table-cell; text-align: center; vertical-align: middle; width: 240px; height: 188px; }
245 304
.artAbout > li > dl > dd .imgItem img { vertical-align: middle; max-width: 240px; max-height: 188px; }
246 305
.artAbout > li > dl > dd .uploadFile .uploadblock { border: none; }
247 306
.artAbout > li > dl > dd .file-panel { position: absolute; top: -10px; right: -10px; text-align: center; overflow: hidden; }
248
.artAbout > li > dl > dd .file-panel .cancel { display: inline-block; width: 20px; height: 20px; cursor: pointer; background: url("../images/g_resource_button_guanbi_nor.png") 0% 0% / cover; }
249
.form-item .addexpertRe { margin: 0px -30px; }
307
.artAbout > li > dl > dd .file-panel .cancel { display: inline-block; width: 20px; height: 20px; cursor: pointer; background: url("../../images/g_resource_button_guanbi_nor.png") 0% 0% / cover; }
308
.form-item .addexpertRe { margin: 0px -15px; }
250 309
.form-item .addexpertRe ul.addexpert > li .madiaInfo { padding-right: 42px; }
251
.form-item .addexpertRe ul.addexpert > li .addbtn { position: absolute; right: 20px; background: rgb(255, 153, 0); top: 50%; margin-top: -14px; cursor: pointer; padding: 4px 10px; color: rgb(255, 255, 255); border-radius: 4px; }
310
.form-item .addexpertRe ul.addexpert > li .selectNull { position: absolute; right: 20px; top: 50%; margin-top: -11px; width: 22px; height: 22px; background-image: url("../../images/c-sign-on_button_xuanze_nor.png"); background-size: cover; }
311
.form-item .addexpertRe ul.addexpert > li .selectAdd { background-image: url("../../images/c-sign-on_button_xuanze_hig.png"); }
252 312
.conBlock .leftconBox2 { background: none; padding: 0px; }
253 313
.conBlock .leftconBox2 .reInfoBlock { width: 320px; margin-left: 24px; position: relative; height: 270px; }
254 314
.conBlock .leftconBox2 .reInfoBlock .h2Font { font-size: 16px; color: rgb(102, 102, 102); line-height: 26px; margin-top: 12px; }
@ -257,47 +317,17 @@ ul.tagList > li .h2Font { color: rgb(102, 102, 102); }
257 317
.conBlock .leftconBox2 .resShareUl { position: absolute; bottom: 0px; }
258 318
.conBlock .leftconBox2 .resShareUl > ul > li { float: left; margin-right: 30px; font-size: 14px; color: rgb(153, 153, 153); }
259 319
.conBlock .leftconBox2 .resShareUl > ul > li .operateicon { margin-left: 10px; cursor: pointer; }
260
.conBlock .leftconBox2 .resShareUl > ul > li > span { position: relative; top: -2px; font-size: 14px; }
320
.conBlock .leftconBox2 .resShareUl > ul > li > span { position: relative; top: -3px; }
261 321
.keydrop > ul > li.orgList { overflow: hidden; }
262 322
.keydrop > ul > li.orgList img { width: 50px; height: 50px; margin-right: 10px; }
263 323
.keydrop > ul > li.orgList p { line-height: 50px; font-size: 14px; }
264
.conBlock .workconG { float: right; width: 87%; background: rgb(255, 255, 255); margin-bottom: 20px; }
324
.conBlock .workconG { float: right; width: 87%; background: rgb(255, 255, 255); }
265 325
.conBlock .workconG .workcontit { height: 60px; padding: 0px 20px; font-size: 16px; line-height: 60px; border-bottom: 1px solid rgb(231, 231, 231); }
266 326
.conBlock .workconG .worksamlltit { font-size: 16px; line-height: 30px; margin-right: 30px; padding: 10px 4px 8px; cursor: pointer; }
267
.conBlock .workconG .worksamlltit.worksamlltitnow { color: rgb(255, 153, 0); border-bottom: 2px solid rgb(255, 153, 0); }
268
.mainDownP .containerCon { height: 100%; }
269
.mainDownP .contentCon { position: relative; height: 100%; width: 100%; }
327
.conBlock .workconG .worksamlltit.worksamlltitnow { color: rgb(40, 184, 250); border-bottom: 2px solid rgb(40, 184, 250); }
270 328
.footer_tools { position: fixed; z-index: 1070; left: 50%; margin-left: 562px; bottom: 20px; }
271
.footer_tools > a { margin-top: 10px; position: relative; display: inline-block; width: 52px; height: 52px; background-position: center center; background-size: cover; opacity: 0.8; }
272
#scrollUp { display: none; background-image: url("../images/bottom_button_dingbu_hig.png"); }
273
.footer_tools > a:hover { opacity: 1; }
274
.footer_tools .correctBlock { display: none; width: 270px; position: fixed; bottom: 0px; right: 0px; border-radius: 6px 6px 0px 0px; overflow: hidden; box-shadow: rgba(195, 195, 195, 0.3) 1px 1px 13px 1px; }
275
.correctBlock .frmcontype { font-size: 16px; color: rgb(255, 255, 255); }
276
.correctBlock textarea.frmcontype { height: 280px; border: none; font-size: 14px; color: rgb(102, 102, 102); }
277
.headconBox .reInfoBlock .h2Font { font-size: 16px; color: rgb(102, 102, 102); margin-bottom: 8px; }
278
.headconBox .head-center .h2Font { margin-bottom: 0px; }
279
.operateBlock { }
280
.operateBlock > ul > li { float: left; font-size: 14px; color: rgb(153, 153, 153); min-height: 24px; margin-right: 20px; }
281
.operateBlock > ul > li .operateicon { margin-left: 10px; cursor: pointer; }
282
.operateBlock > ul > li > span { position: relative; top: -2px; font-size: 14px; }
283
.headconBox .operateBlock > ul > li { margin-right: 0px; }
284
.cmpFrmList > li .frmadd { width: auto; position: absolute; right: 0px; top: 0px; background: rgb(255, 153, 0); color: rgb(255, 255, 255); border: none; padding: 6px 25px; }
285
.keyResult > ul.editUlist, .keyResult > ul.editUlistC { width: 98%; margin-right: -30px; margin-bottom: 0px; }
286
.keyResult > ul.editUlistC > li, .keyResult > ul.editUlist > li { position: relative; padding: 6px 12px; background: rgb(255, 255, 255); margin-bottom: 0px; }
287
.keyResult > ul.editUlist > li { float: left; }
288
.keyResult > ul.editUlistC > li { width: 100%; margin-top: 12px; }
289
.keyResult > ul.editUlistC > li.yjlist { margin: 10px 0px 0px; width: 100%; text-align: left; border-radius: 0px; line-height: 26px; border: none; background: none; padding: 0px 12px 0px 0px; }
290
.keyResult > ul.editUlistC > li.yjlist > div { width: auto; position: relative; border: 1px solid rgb(229, 229, 229); background: rgb(255, 255, 255); display: inline-block; padding: 0px 12px 0px 0px; }
291
.keyResult > ul.editUlistC > li.yjlist .like { display: inline-block; float: left; text-align: center; min-width: 28px; padding: 0px 6px; background: rgb(255, 153, 0); color: rgb(255, 255, 255); font-size: 10px; margin-right: 5px; }
292
.saveBtn .frmcontype { width: 120px; margin-right: 30px; margin-top: 20px; }
293
.modifybox .form-result.keyResult { margin-top: -10px; }
294
.aboutPa .form-result { margin: -6px -20px 0px 0px; }
295
.aboutPa .form-result > ul > li { display: none; float: left; width: 47%; border: 1px solid rgb(229, 229, 229); background: rgb(255, 255, 255); padding: 20px; margin: 20px 20px 0px 0px; min-height: auto; height: 76px; }
296
.aboutPa .form-result > ul > li > a { display: block; width: 100%; }
297
.aboutPa .form-result > ul > li .shareCode { left: -8px; z-index: 2; }
298
.aboutPa .form-result > ul > li:hover { background: rgb(255, 255, 255); }
299
.aboutPa .form-result ul.authorBox { position: relative; }
300
.aboutPa .form-result ul.authorBox > li > a { max-width: 80%; }
329
#scrollUp { display: none; width: 52px; height: 52px; background-image: url("../../images/../images/bottom_button_dingbu_hig.png"); background-position: center center; background-size: cover; opacity: 0.8; }
330
#scrollUp:hover { opacity: 1; }
301 331
.edui-default .edui-box { border: none; padding: 0px; margin: 0px; overflow: hidden; }
302 332
.edui-default a.edui-box { display: block; text-decoration: none; color: black; }
303 333
.edui-default a.edui-box:hover { text-decoration: none; }

+ 2 - 1
html/index.html

@ -171,7 +171,8 @@
171 171
	<script type="text/javascript" src="../js/webuploader.js"></script>
172 172
	<script type="text/javascript" src="../js/city.min.js"></script>
173 173
	<script type="text/javascript" src="../js/static.js"></script>
174

174
	<script type="text/javascript" src="../js/ueditor/ueditor.config.js"></script>
175
	<script type="text/javascript" src="../js/ueditor/ueditor.all.js"> </script>
175 176
	<script>
176 177
		$(function() {
177 178
			$.use(["spa", "util"], function(spa, util) {

+ 81 - 119
html/model/sys/article/articleModify.html

@ -5,49 +5,34 @@
5 5
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
6 6
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
7 7
    <title>修改文章-科袖网</title>
8
    <!--<link rel="shortcut icon" type="image/x-icon" href="images/favicon.png" media="screen" />-->
9
    <!--<link href="css/bootstrap.min.css" rel="stylesheet">-->
10
    <!--<link type="text/css" href="css/webuploader/webuploader.css" rel="stylesheet">-->
11
    <!--<link type="text/css" rel="stylesheet" href="css/datetimepicker.css">-->
12
    <!--<link type="text/css" href="css/webuploader/webuploader.css" rel="stylesheet">-->
13
    <!--<link type="text/css" href="css/common.css" rel="stylesheet">-->
14
    <link type="text/css" href="../../../../css/model/sys/articleModify.css" rel="stylesheet">
15
    <script type="text/javascript" src="../../../../js/jquery-1.12.4.js"></script>
8
    <link rel="shortcut icon" href="images/favicon.ico "/>
9
10
    <link type="text/css" href="/css/model/sys/articleModify.css" rel="stylesheet">
11
    <script type="text/javascript" src="/js/jquery-1.12.4.js"></script>
12
    <script src="../../../../js/jquery.similar.msgbox.js"></script>
16 13
17 14
</head>
18 15
19 16
<body>
20 17
<header id="header">
21
    <!--<script src="js/header.js"></script>-->
18
    <!--<script src="js/public/cmpHeader.js"></script>-->
22 19
</header>
23 20
<!--定时发布弹框-->
24 21
<!--<div class="blackcover2"></div>-->
25 22
<!--<div class="setTimeBlock modelContain">-->
26
<!--<span class="mb_tit">提示</span>-->
27
<!--<a class="mb_close"></a>-->
28
<!--<div class="mb_msg">-->
29
<!--<p style="margin: 10px;">请设置文章发布的时间:</p>-->
30
<!--<div class="formTime">-->
31
<!--&lt;!&ndash;<div class="form-group">-->
32
<!--<div class='input-group date' id='datetimepicker6'>-->
33
<!--<input type='text' class="form-control" />-->
34
<!--<span class="input-group-addon"><span class="glyphicon glyphicon-calendar"></span></span>-->
35
<!--</div>-->
36
<!--</div>&ndash;&gt;-->
37
<!--<div class="form-group">-->
38
<!--<input size="16" type="text" value="" readonly class="form-control form_datetime">-->
39
<!--</div>-->
40
<!--</div>-->
41
<!--</div>-->
42
<!--<div class="mb_btnbox">-->
43
<!--<input class="mb_btn mb_btnOk" type="button" value="确定">-->
44
<!--<input class="mb_btn mb_btnNo" type="button" value="取消">-->
45
<!--</div>-->
23
    <!--<span class="mb_tit">提示</span>-->
24
    <!--<a class="mb_close"></a>-->
25
    <!--<div class="mb_msg" id="promotTh">-->
26
27
    <!--</div>-->
28
    <!--<div class="mb_btnbox" id="promotGt">-->
29
        <!--<input class="mb_btn mb_btnNo" type="button" value="取消">-->
30
    <!--</div>-->
46 31
<!--</div>-->
47 32
48 33
<div id="container">
49 34
    <div class="containerCon">
50
        <div class="contentCon clearfix conBlock">
35
        <div class="contentCon clearfix conBlock" style="padding-top:20px">
51 36
            <div class="leftconBox floatL">
52 37
                <ul class="artAbout">
53 38
                    <li>
@ -56,8 +41,8 @@
56 41
                                <span class="" id="filePicker">上传图片</span>
57 42
                                <!--未上传图片时-->
58 43
                                <div class="upFront">
59
                                    <p>文章封面图<em class="requiredcon">*</em></p>
60
                                    <p class="uploadtip">JPG/PNG格式,2M以内</p>
44
                                    <p>文章封面图<em class="requiredcon">*</em></p>
45
                                    <p class="uploadtip">JPG/JPEG/PNG格式,2M以内</p>
61 46
                                    <span class="upbtn">上传图片</span>
62 47
                                </div>
63 48
                                <!--已上传图片时-->
@ -102,7 +87,7 @@
102 87
                    <ul class="operateBlock">
103 88
                        <li class="goFabu" id="release">
104 89
                            <em class="operateicon icon-issue"></em>
105
                            <p>发布</p>
90
                            <p>保存</p>
106 91
                        </li>
107 92
                        <!--<li id="setTimeIssue">-->
108 93
                            <!--<em class="operateicon icon-timeissue"></em>-->
@ -120,59 +105,64 @@
120 105
                            <!--<em class="operateicon icon-delete"></em>-->
121 106
                            <!--<p>删除</p>-->
122 107
                        <!--</li>-->
123
124 108
                    </ul>
125 109
                </div>
126
                <div class="conItem">
127
                    <div class="form-item otherBlock">
128
                        <div class="aboutTit">相关专家<span class="frmconmsg"></span></div>
129
                        <input type="text" class="frmtype frmcontype" placeholder="请输入专家姓名" id="checkZj" value="" />
130
                        <div class="form-drop displayNone">
131
                            <ul class="expertlist" id="expertlist">
132
133
                            </ul>
134
                        </div>
135
                        <div class="form-result">
136
                            <ul class="addexpert" id="expertli">
137
138
                            </ul>
139
                        </div>
140
                    </div>
141
                    <div class="form-item otherBlock">
142
                        <div class="aboutTit">相关资源<span class="frmconmsg"></span></div>
143
                        <input type="text" class="frmtype frmcontype" placeholder="请输入资源名称" id="checkZy" value="" />
144
                        <div class="form-drop displayNone">
145
                            <ul class="expertlist" id="resouselist">
146
147
                            </ul>
148
                        </div>
149
                        <div class="form-result">
150
                            <ul class="addexpert" id="resources">
151
152
                            </ul>
153
                        </div>
154
                    </div>
155
                </div>
110
                <!--<div class="conItem">-->
111
                    <!--<div class="form-item otherBlock">-->
112
                        <!--<div class="aboutTit">相关专家<span class="frmconmsg"></span></div>-->
113
                        <!--<input type="text" class="frmtype frmcontype" placeholder="请输入专家姓名" id="checkZj" value="" />-->
114
                        <!--<div class="form-drop displayNone">-->
115
                            <!--<ul class="expertlist" id="expertlist">-->
116
117
                            <!--</ul>-->
118
                        <!--</div>-->
119
                        <!--<div class="form-result">-->
120
                            <!--<ul class="addexpert" id="expertli">-->
121
122
                            <!--</ul>-->
123
                        <!--</div>-->
124
                    <!--</div>-->
125
                    <!--<div class="form-item otherBlock">-->
126
                        <!--<div class="aboutTit">相关资源<span class="frmconmsg"></span></div>-->
127
                        <!--<input type="text" class="frmtype frmcontype" placeholder="请输入资源名称" id="checkZy" value="" />-->
128
                        <!--<div class="form-drop displayNone">-->
129
                            <!--<ul class="expertlist" id="resouselist">-->
130
131
                            <!--</ul>-->
132
                        <!--</div>-->
133
                        <!--<div class="form-result">-->
134
                            <!--<ul class="addexpert" id="resources">-->
135
136
                            <!--</ul>-->
137
                        <!--</div>-->
138
                    <!--</div>-->
139
                    <!--<div class="form-item otherBlock">-->
140
                        <!--<div class="aboutTit">相关企业<span class="frmconmsg"></span></div>-->
141
                        <!--<input type="text" class="frmtype frmcontype" placeholder="请输入企业名称" id="company" value="" />-->
142
                        <!--<div class="form-drop displayNone">-->
143
                            <!--<ul class="expertlist" id="companylist">-->
144
145
                            <!--</ul>-->
146
                        <!--</div>-->
147
                        <!--<div class="form-result">-->
148
                            <!--<ul class="addexpert" id="companys">-->
149
150
                            <!--</ul>-->
151
                        <!--</div>-->
152
                    <!--</div>-->
153
                <!--</div>-->
156 154
            </div>
157 155
        </div>
158 156
    </div>
159 157
</div>
160
<div class="footer_tools">
161
    <a id="scrollUp" href="javascript:;" title="返回顶部"></a>
162
</div>
163
<!--<footer>-->
164
<!--<script type="text/javascript" src="js/footer.js"></script>-->
165
<!--</footer>-->
166
<!--<script type="text/javascript" src="js/public/bootstrap.min.js"></script>-->
167
<!--<script type="text/javascript" src="js/public/prettify.js"></script>-->
168
<!--<script type="text/javascript" src="js/public/bootstrap-datetimepicker.min.js"></script>-->
169
<script type="text/javascript" src="../../../../js/ueditor/ueditor.config.js"></script>
170
<script type="text/javascript" src="../../../../js/ueditor/ueditor.all.js"> </script>
171
<script type="text/javascript" src="../../../../js/webuploader.js"></script>
172
<!--<script type="text/javascript"src="js/jquery.cookie.js"></script>-->
173
<script type="text/javascript" src="../../../../js/jquery.similar.msgbox.js"></script>
174
<!--<script type="text/javascript" src="js/common.js"></script>-->
175
<script type="text/javascript" src="../../../../js/model/sys/article/articleModify.js"></script>
158
<!--<div class="footer_tools">-->
159
    <!--<a id="scrollUp" href="javascript:;" title="返回顶部"></a>-->
160
<!--</div>-->
161
<script type="text/javascript" src="/js/jquery.similar.msgbox.js"></script>
162
<script type="text/javascript" src="/js/ueditor/ueditor.config.js"></script>
163
<script type="text/javascript" src="/js/ueditor/ueditor.all.js"> </script>
164
<script type="text/javascript" src="/js/webuploader.js"></script>
165
<script type="text/javascript" src="/js/model/sys/article/articleModify.js"></script>
176 166
<script type="text/javascript">
177 167
    $(function () {
178 168
        //回到顶部
@ -191,39 +181,6 @@
191 181
            $('html,body').animate({ scrollTop:0});
192 182
        });
193 183
194
        var currentdate;
195
//    $(".form_datetime").datetimepicker({
196
//    	format: 'yyyy-mm-dd hh:ii',
197
//    	forceParse: true,
198
//    	autoclose: true,
199
//       // todayBtn: true
200
//    });
201
        function getNowFormatDate() {
202
            var date = new Date();
203
            var seperator1 = "-";
204
            var seperator2 = ":";
205
            var month = date.getMonth() + 1;
206
            var strDate = date.getDate();
207
            var getHours = date.getHours();
208
            var getMinutes = date.getMinutes();
209
            if (month >= 1 && month <= 9) {
210
                month = "0" + month;
211
            }
212
            if (strDate >= 0 && strDate <= 9) {
213
                strDate = "0" + strDate;
214
            }
215
            if (getMinutes >= 0 && getMinutes <= 9) {
216
                getMinutes = "0" + getMinutes;
217
            }
218
            if (getHours >= 0 && getHours <= 9) {
219
                getHours = "0" + getHours;
220
            }
221
            var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
222
                + " " + getHours + seperator2 + getMinutes
223
224
            return currentdate;
225
        }
226
        $(".form_datetime").val(getNowFormatDate(currentdate));
227 184
    });
228 185
    //Model模态框打开关闭
229 186
@ -244,7 +201,7 @@
244 201
        // swf文件路径
245 202
        swf: '../js/webuploader/Uploader.swf',
246 203
        // 文件接收服务端。
247
        server: '../ajax/cachedFileUpload',
204
        server: '/ajax/cachedFileUpload',
248 205
        // 选择文件的按钮。可选。
249 206
        // 内部根据当前运行是创建,可能是input元素,也可能是flash.
250 207
        fileSingleSizeLimit: 2 * 1024 * 1024,
@ -256,14 +213,14 @@
256 213
        // 只允许选择图片文件。
257 214
        accept: {
258 215
            title: 'Images',
259
            extensions: 'gif,jpg,jpeg,bmp,png',
260
            mimeTypes: 'image/gif,image/jpg,image/jpeg,image/bmp,image/png'
216
            extensions: 'jpg,jpeg,png',
217
            mimeTypes: 'image/jpg,image/jpeg,image/png'
261 218
        }
262 219
263 220
    });
264 221
    uploader.onError = function(code) {
265 222
        if(code=="F_EXCEED_SIZE"){
266
            $.MsgBox.Alert('提示', '请上传jpg、png格式的图片,大小不超过2M')
223
            $.MsgBox.Alert('提示', '请上传jpg、jpeg、png格式的图片,大小不超过2M');
267 224
        }
268 225
    };
269 226
    // 当有文件添加进来的时候
@ -280,8 +237,13 @@
280 237
    // 文件上传成功,给item添加成功class, 用样式标记上传成功。
281 238
    cacheImageKey="";
282 239
    uploader.on( 'uploadSuccess', function(file,data) {
283
        cacheImageKey =data.data[0].cacheKey;
284
        $("#uploader").attr("data-id",cacheImageKey);
240
        if(data.success) {
241
            cacheImageKey =data.data[0].cacheKey;
242
            $("#uploader").attr("data-id",cacheImageKey);
243
        }else{
244
            $.MsgBox.Alert('提示', '只支持jpeg/jpg/png格式的图片');
245
            $("#uploader").css("background-image","url('')");
246
        }
285 247
    });
286 248
287 249
</script>

+ 6 - 0
html/model/sys/article/index.html

@ -51,6 +51,12 @@
51 51
            <div class="btn opt-sort-num">
52 52
                设置权重
53 53
            </div>
54
            <div class="btn opt-edit">
55
                编辑文章内容
56
            </div>
57
            <div class="btn opt-relate">
58
                编辑关联信息
59
            </div>
54 60
            <div class="btn opt-del">
55 61
                删除
56 62
            </div>

+ 21 - 0
html/model/sys/article/relate.html

@ -0,0 +1,21 @@
1
<div class="sys_article_relate centerModal">
2
    <div class="modal-ctrl" id="header">
3
        <i class="icon icon-times"></i>
4
    </div>
5
    <div class="container newForm">
6
        <div class="row">
7
            <div class="col-2"></div>
8
            <div class="col-4 item-caption content ">设置权重</div>
9
        </div>
10
        
11
        <div class="row">
12
            <div class="col-10"></div>
13
            <div class="co  l-2">
14
                <div class="btn pull-right opt-save">
15
                    <i class="icon-check"></i> SAVE
16
                </div>
17
            </div>
18
        </div>
19
20
    </div>
21
</div>

BIN
images/g_article_button_guanbi_lan_hig.png


BIN
images/g_article_icon_fabu_lan_hig.png


BIN
images/sign_icon_chenggong_nor.png


BIN
images/sign_icon_gantan_nor.png


BIN
images/sign_icon_guanbi_nor.png


+ 2 - 2
js/jquery.similar.msgbox.js

@ -44,12 +44,12 @@
44 44
            textAlign:'center', fontSize: '16px',overflow:'hidden',fontFamily: fontfamily
45 45
        });
46 46
        $("#mb_msgicon").css({display:'inline-block',width:'40px',height: '40px',marginRight: '6px',
47
    		background: 'url(images/sign_icon_gantan_nor.png)', backgroundSize: 'contain',overflow:'hidden'
47
    		background: 'url(/images/sign_icon_gantan_nor.png)', backgroundSize: 'contain',overflow:'hidden'
48 48
        });
49 49
         $("#mb_msgcontent").css({margin:'10px'});
50 50
        
51 51
        $("#mb_ico").css({ display: 'block', position: 'absolute', right: '20px', top: '18px',
52
        	background:'url(images/sign_icon_guanbi_nor.png) center center no-repeat', width: '20px', height: '20px',cursor: 'pointer'
52
        	background:'url(/images/sign_icon_guanbi_nor.png) center center no-repeat', width: '20px', height: '20px',cursor: 'pointer'
53 53
        });
54 54
        $("#mb_btnbox").css({ margin: '0 auto 30px', textAlign: 'center', position:'relative' });
55 55
        $("#mb_btn_ok,#mb_btn_no").css({ width: '100px', fontSize: '14px', height: '32px', color: 'white', border: 'none' });

+ 659 - 388
js/model/sys/article/articleModify.js

@ -1,23 +1,26 @@
1
/**
2
 * Created by TT on 2017/8/21.
3
 */
4 1
$(function() {
5
    // loginStatus();//判断个人是否登录
6
    // valUser();
7 2
    var articleId = GetQueryString("articleId");
8 3
    var experarray = [];
9 4
    var resourcesarray = [];
10 5
    var $data = {};
11 6
    var modifyTimeval;
12 7
    var settime = false;
13
8
    // var orgId = $.cookie("orgId");
9
    var colMgr = true;
10
    // if(orgId == "" || orgId == null || orgId == "null"){
11
    //     location.href = "cmp-settled-log.html";
12
    // }
13
    var hbur,hburEnd;
14
    var pr,prEnd;
15
    var re,reEnd;
16
    var orgr,orgrEnd;
14 17
    articleshow();
15
    relevantExperts();
16
    relevantResources();
18
    // relevantExperts();
19
    // relevantResources();
17 20
18 21
    function GetQueryString(name) {
19 22
        var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
20
        var r = window.location.search.substr(1).match(reg);
23
        var r = window.location.search.substr(1).match(reg); //��ȡurl��"?"�����ַ�����ƥ��
21 24
22 25
        var context = "";
23 26
        if(r != null)
@ -27,6 +30,7 @@ $(function() {
27 30
        return context == null || context == "" || context == "undefined" ? "" : decodeURI(context);
28 31
    }
29 32
33
30 34
    //校验标题
31 35
    $("#newstitle").on({
32 36
        focus: function() {
@ -51,20 +55,28 @@ $(function() {
51 55
            $("#keyPrompt").text("");
52 56
        },
53 57
        keyup: function() {
54
            if($(this).val()==""){
58
            var ti=$(this).val();
59
            hbur=ti;
60
            if(ti==""){
55 61
                $(".frmadd").addClass("displayNone");
56 62
                $(".keydrop ul").html("");
57 63
                $(".keydrop").addClass("displayNone");
64
                return;
58 65
            }else{
59 66
                $(".frmadd").removeClass("displayNone");
60 67
            }
61 68
            if($(this).val().length > 15) {
62 69
                $(this).val($(this).val().substr(0, 15));
63 70
            }
64
            KeyWordList();
71
            setTimeout(function(){
72
                if( ti===hbur && ti!== hburEnd) {
73
                    KeyWordList(ti);
74
                }
75
76
            },500)
77
65 78
        }
66 79
    })
67
68 80
    //添加关键字
69 81
    $("#addkeyWord").on("click", function() {
70 82
        var keyWord = $("#KeyWord").val();
@ -125,28 +137,31 @@ $(function() {
125 137
        }
126 138
    }
127 139
128
    function KeyWordList() {
140
    function KeyWordList(seValue) {
141
        hburEnd=seValue;
129 142
        $.ajax({
130
            "url": "/ajax/dataDict/qaHotKey",
143
            "url": "/ajax/article/qaHotKey",
131 144
            "type": "get",
132 145
            "data": {
133 146
                "key": $("#KeyWord").val()
134 147
            },
135 148
            "success": function(data) {
136 149
                console.log(data);
137
                if(data.success && data.data != "") {
138
                    var itemlist = '';
139
                    $("#keydropList").html("");
140
                    for(var i = 0; i < 5; i++) {
141
                        var itemlist = '<li><p class="h2Font"></p></li>';
142
                        $itemlist = $(itemlist);
143
                        $("#keydropList").append($itemlist);
144
                        $itemlist.find(".h2Font").text(data.data[i].caption);
150
                if(data.success) {
151
                    if(hburEnd == seValue){
152
                        var itemlist = '';
153
                        $("#keydropList").html("");
154
                        for(var i = 0; i < Math.min(data.data.length,5); i++) {
155
                            var itemlist = '<li><p class="h2Font"></p></li>';
156
                            $itemlist = $(itemlist);
157
                            $("#keydropList").append($itemlist);
158
                            $itemlist.find(".h2Font").text(data.data[i].caption);
159
                        }
160
                        $(".keydrop").removeClass("displayNone");
145 161
                    }
146
                    $(".keydrop").removeClass("displayNone");
147 162
                } else {
148
                    $(".keydrop").addClass("displayNone");
149
                    $(".keydrop ul").html("");
163
                    //$(".keydrop").addClass("displayNone");
164
                    //$(".keydrop ul").html("");
150 165
                }
151 166
            },
152 167
            "error": function() {
@ -189,12 +204,34 @@ $(function() {
189 204
190 205
    $("#checkZj").on("keyup", function() {
191 206
        var _this = this;
192
        checkZj(_this);
207
        var ti=$(this).val();
208
        pr=ti;
209
        if($(this).val()=="") {
210
            return;
211
        }
212
        setTimeout(function(){
213
            if( ti===pr && ti!== prEnd) {
214
                checkZj(_this,ti);
215
            }
216
217
        },500)
218
193 219
    })
194 220
195 221
    $("#checkZy").on("keyup", function() {
222
        var ti=$(this).val();
223
        re=ti;
224
        if($(this).val()=="") {
225
            return;
226
        }
196 227
        var _this = this;
197
        checkZy(_this);
228
        setTimeout(function(){
229
            if( ti===re && ti!== reEnd) {
230
                checkZy(_this,ti);
231
            }
232
233
        },500)
234
198 235
    })
199 236
200 237
    $("#expertlist").on("click","li",function(){
@ -239,108 +276,112 @@ $(function() {
239 276
        $(this).parent().remove();
240 277
    })
241 278
242
    function checkZj(_this){
243
        $.ajax({
244
            "url": "/ajax/professor/qaByName",
245
            "type": "get",
246
            "data": {
247
                "name": $("#checkZj").val(),
248
                "total":3
249
            },
250
            "success": function(data) {
251
                console.log(data);
252
                if(data.success ) {
253
                    if(data.data != ""){
254
                        $(_this).next().removeClass("displayNone");
255
                        var itemlist = '';
256
                        $("#expertlist").html("");
257
                        for(var i = 0; i < data.data.length; i++) {
258
                            var itemlist = '<li id="usid" class="flexCenter">';
259
                            itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
260
                            itemlist += '<div class="madiaInfo">';
261
                            itemlist += '<p class="ellipsisSty"><span class="h1Font" id="name"></span><span class="h2Font" style="margin-left:10px;" id="title"></span></p>';
262
                            itemlist += '<p class="h2Font ellipsisSty" id="orgName"></p>';
263
                            itemlist += '</div><div class="deleteThis"></div></li>';
264
                            $itemlist = $(itemlist);
265
                            $("#expertlist").append($itemlist);
266
                            var datalist = data.data[i];
267
                            $itemlist.attr("data-id",datalist.id);
268
                            $itemlist.find("#name").text(datalist.name);
269
                            $itemlist.find("#title").text(datalist.title);
270
                            $itemlist.find("#orgName").text(datalist.orgName);
271
                            if(datalist.hasHeadImage==1) {
272
                                $itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + datalist.id + "_l.jpg);");
273
                            }
274
                        }
275
                    }else{
276
                        $(_this).next().addClass("displayNone");
277
                    }
278
                }else{
279
                    $(_this).next().addClass("displayNone");
280
                }
281
            },
282
            "error": function() {
283
                $.MsgBox.Alert('提示', '链接服务器超时')
284
            }
285
        });
286
    }
287
288
    function checkZy(_this) {
289
        $.ajax({
290
            "url": "/ajax/resource/qaByName",
291
            "type": "get",
292
            "data": {
293
                "resourceName": $("#checkZy").val(),
294
                "rows": 3
295
            },
296
            "success": function(data) {
297
                console.log(data);
298
                if(data.success) {
299
                    if(data.data != "") {
300
                        $(_this).next().removeClass("displayNone");
301
                        var itemlist = '';
302
                        $("#resouselist").html("");
303
                        for(var i = 0; i < data.data.length; i++) {
304
                            var itemlist = '<li id="usid" class="flexCenter">';
305
                            itemlist += '<div class="madiaHead resouseHead" id="userimg"></div>';
306
                            itemlist += '<div class="madiaInfo">';
307
                            itemlist += '<p class="h1Font ellipsisSty" id="resourceName"></p>';
308
                            itemlist += '<p class="h2Font ellipsisSty" id="name"></p>';
309
                            itemlist += '</div><div class="deleteThis"></div></li>';
310
                            $itemlist = $(itemlist);
311
                            $("#resouselist").append($itemlist);
312
                            var datalist = data.data[i];
313
                            $itemlist.attr("data-id", datalist.resourceId);
314
                            $itemlist.find("#resourceName").text(datalist.resourceName);
315
                            if(datalist.resourceType==1){
316
                                $itemlist.find("#name").text(datalist.professor.name);
317
                            }else{
318
                                $itemlist.find("#name").text(datalist.organization.name);
319
                            }
320
                            if(datalist.images.length > 0) {
321
                                $itemlist.find("#userimg").attr("style", "background-image: url(/data/resource/" + datalist.images[0].imageSrc + ");");
322
                            }
323
                        }
324
                    } else {
325
                        $(_this).next().addClass("displayNone");
326
                    }
327
                } else {
328
                    $(_this).next().addClass("displayNone");
329
                }
330
            },
331
            "error": function() {
332
                $.MsgBox.Alert('提示', '链接服务器超时')
333
            }
334
        });
335
    }
336
279
    // function checkZj(_this,prd) {
280
    //     prEnd=prd;
281
    //     $.ajax({
282
    //         "url": "/ajax/professor/qaByName",
283
    //         "type": "get",
284
    //         "data": {
285
    //             "name": $("#checkZj").val(),
286
    //             "total": 3
287
    //         },
288
    //         "success": function(data) {
289
    //             console.log(data);
290
    //             if(data.success) {
291
    //                 if(data.data != "") {
292
    //                     if(prEnd == prd){
293
    //                         $(_this).next().removeClass("displayNone");
294
    //                         var itemlist = '';
295
    //                         $("#expertlist").html("");
296
    //                         for(var i = 0; i < data.data.length; i++) {
297
    //                             var itemlist = '<li id="usid" class="flexCenter">';
298
    //                             itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
299
    //                             itemlist += '<div class="madiaInfo">';
300
    //                             itemlist += '<p class="ellipsisSty"><span class="h1Font" id="name"></span><span class="h2Font" style="margin-left:10px;" id="title"></span></p>';
301
    //                             itemlist += '<p class="h2Font ellipsisSty" id="orgName"></p>';
302
    //                             itemlist += '</div><div class="deleteThis"></div></li>';
303
    //                             $itemlist = $(itemlist);
304
    //                             $("#expertlist").append($itemlist);
305
    //                             var datalist = data.data[i];
306
    //                             $itemlist.attr("data-id", datalist.id);
307
    //                             $itemlist.find("#name").text(datalist.name);
308
    //                             $itemlist.find("#title").text(datalist.title);
309
    //                             $itemlist.find("#orgName").text(datalist.orgName);
310
    //                             if(datalist.hasHeadImage == 1) {
311
    //                                 $itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + datalist.id + "_l.jpg);");
312
    //                             }
313
    //                         }
314
    //                     }
315
    //                 } else {
316
    //                     $(_this).next().addClass("displayNone");
317
    //                 }
318
    //             } else {
319
    //                 $(_this).next().addClass("displayNone");
320
    //             }
321
    //         },
322
    //         "error": function() {
323
    //             $.MsgBox.Alert('提示', '链接服务器超时')
324
    //         }
325
    //     });
326
    // }
327
328
    // function checkZy(_this,prd) {
329
    //     reEnd=prd;
330
    //     $.ajax({
331
    //         "url": "/ajax/resource/qaByName",
332
    //         "type": "get",
333
    //         "data": {
334
    //             "resourceName": $("#checkZy").val(),
335
    //             "rows": 3
336
    //         },
337
    //         "success": function(data) {
338
    //             console.log(data);
339
    //             if(data.success) {
340
    //                 if(data.data != "") {
341
    //                     if(reEnd==prd) {
342
    //                         $(_this).next().removeClass("displayNone");
343
    //                         var itemlist = '';
344
    //                         $("#resouselist").html("");
345
    //                         for(var i = 0; i < data.data.length; i++) {
346
    //                             var itemlist = '<li id="usid" class="flexCenter">';
347
    //                             itemlist += '<div class="madiaHead resouseHead" id="userimg"></div>';
348
    //                             itemlist += '<div class="madiaInfo">';
349
    //                             itemlist += '<p class="h1Font ellipsisSty" id="resourceName"></p>';
350
    //                             itemlist += '<p class="h2Font ellipsisSty" id="name"></p>';
351
    //                             itemlist += '</div><div class="deleteThis"></div></li>';
352
    //                             $itemlist = $(itemlist);
353
    //                             $("#resouselist").append($itemlist);
354
    //                             var datalist = data.data[i];
355
    //                             $itemlist.attr("data-id", datalist.resourceId);
356
    //                             $itemlist.find("#resourceName").text(datalist.resourceName);
357
    //                             if(datalist.resourceType==1){
358
    //                                 $itemlist.find("#name").text(datalist.professor.name);
359
    //                             }else{
360
    //                                 $itemlist.find("#name").text(datalist.organization.name);
361
    //                             }
362
    //                             if(datalist.images.length > 0) {
363
    //                                 $itemlist.find("#userimg").attr("style", "background-image: url(/data/resource/" + datalist.images[0].imageSrc + ");");
364
    //                             }
365
    //                         }
366
    //                     }
367
    //                 } else {
368
    //                     $(_this).next().addClass("displayNone");
369
    //                 }
370
    //             } else {
371
    //                 $(_this).next().addClass("displayNone");
372
    //             }
373
    //         },
374
    //         "error": function() {
375
    //             $.MsgBox.Alert('提示', '链接服务器超时')
376
    //         }
377
    //     });
378
    // }
337 379
    //初始化数据
338 380
    function articleshow(){
339 381
        $.ajax({
340
            "url" : "/ajax/article/query",
382
            "url" : "/ajax/article/id/"+articleId,
341 383
            "type" :  "GET" ,
342 384
            "dataType" : "json",
343
            "data" :{"articleId":articleId},
344 385
            "success" : function(data) {
345 386
                console.log(data)
346 387
                if (data.success){
@ -370,115 +411,115 @@ $(function() {
370 411
    }
371 412
372 413
    //相关专家
373
    function relevantExperts(){
374
        $.ajax({
375
            "url": "/ajax/article/ralatePro",
376
            "type": "get",
377
            "dataType" : "json",
378
            "data" :{"articleId":articleId},
379
            "success": function(data) {
380
                if(data.success && data.data) {
381
                    for(var i = 0; i < data.data.length; i++) {
382
                        var professorId = data.data[i].professorId;
383
                        relevantExpertsList(professorId)
384
                    }
385
386
                }
387
            },
388
            "error": function() {
389
                $.MsgBox.Alert('提示', '链接服务器超时')
390
            }
391
        });
392
    }
414
    // function relevantExperts(){
415
    //     $.ajax({
416
    //         "url": "/ajax/article/ralatePro",
417
    //         "type": "get",
418
    //         "dataType" : "json",
419
    //         "data" :{"articleId":articleId},
420
    //         "success": function(data) {
421
    //             if(data.success && data.data) {
422
    //                 for(var i = 0; i < data.data.length; i++) {
423
    //                     var professorId = data.data[i].professorId;
424
    //                     relevantExpertsList(professorId)
425
    //                 }
426
    //
427
    //             }
428
    //         },
429
    //         "error": function() {
430
    //             $.MsgBox.Alert('提示', '链接服务器超时')
431
    //         }
432
    //     });
433
    // }
393 434
394 435
    //相关专家信息
395
    function relevantExpertsList(professorId){
396
        $.ajax({
397
            "url" : "/ajax/professor/info/"+professorId,
398
            "type" :  "GET" ,
399
            "dataType" : "json",
400
            "success" : function(data) {
401
                console.log(data);
402
                if (data.success && data.data){
403
                    var itemlist = '';
404
                    var itemlist = '<li id="usid">';
405
                    itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
406
                    itemlist += '<div class="madiaInfo">';
407
                    itemlist += '<p class="ellipsisSty"><span class="h1Font" id="name"></span><span class="h2Font" style="margin-left:10px;" id="title"></span></p>';
408
                    itemlist += '<p class="h2Font ellipsisSty" id="orgName"></p>';
409
                    itemlist += '</div><div class="deleteThis"></div></li>';
410
                    $itemlist = $(itemlist);
411
                    $("#expertli").append($itemlist);
412
                    var datalist = data.data;
413
                    $itemlist.attr("data-id",datalist.id);
414
                    $itemlist.find("#name").text(datalist.name);
415
                    $itemlist.find("#title").text(datalist.title);
416
                    $itemlist.find("#orgName").text(datalist.orgName);
417
                    if(datalist.hasHeadImage==1) {
418
                        $itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + datalist.id + "_l.jpg);");
419
                    }
420
                }
421
            },
422
            "error":function(){
423
                $.MsgBox.Alert('提示','链接服务器超时')
424
            }
425
        });
426
    }
427
428
    //相关资源
429
    function relevantResources(){
430
        $.ajax({
431
            "url": "/ajax/article/ralateRes",
432
            "type": "get",
433
            "dataType" : "json",
434
            "data" :{"articleId":articleId},
435
            "success": function(data) {
436
                if(data.success && data.data) {
437
                    for(var i = 0; i < data.data.length; i++) {
438
                        var resourceId = data.data[i].resourceId;
439
                        relevantResourcesList(resourceId)
440
                    }
441
442
                }
443
            },
444
            "error": function() {
445
                $.MsgBox.Alert('提示', '链接服务器超时')
446
            }
447
        });
448
    }
449
450
    //相关资源信息
451
    function relevantResourcesList(resourceId){
452
        $.ajax({
453
            "url" : "/ajax/resource/resourceInfo",
454
            "type" :  "GET" ,
455
            "dataType" : "json",
456
            "data" :{"resourceId":resourceId},
457
            "success" : function(data) {
458
                console.log(data);
459
                if (data.success && data.data){
460
                    var itemlist = '<li id="usid">';
461
                    itemlist += '<div class="madiaHead resouseHead" id="userimg"></div>';
462
                    itemlist += '<div class="madiaInfo">';
463
                    itemlist += '<p class="h2Font ellipsisSty" id="resourceName"></p>';
464
                    itemlist += '<p class="h1Font" id="name"></p>';
465
                    itemlist += '</div><div class="deleteThis"></div></li>';
466
                    $itemlist = $(itemlist);
467
                    $("#resources").append($itemlist);
468
                    var datalist = data.data;
469
                    $itemlist.attr("data-id", datalist.resourceId);
470
                    $itemlist.find("#resourceName").text(datalist.resourceName);
471
                    $itemlist.find("#name").text(datalist.editProfessor.name);
472
                    if(datalist.images.length > 0) {
473
                        $itemlist.find("#userimg").attr("style", "background-image: url(/data/resource/" + datalist.images[0].imageSrc + ");");
474
                    }
475
                }
476
            },
477
            "error":function(){
478
                $.MsgBox.Alert('提示','链接服务器超时')
479
            }
480
        });
481
    }
436
    // function relevantExpertsList(professorId){
437
    //     $.ajax({
438
    //         "url" : "/ajax/professor/info/"+professorId,
439
    //         "type" :  "GET" ,
440
    //         "dataType" : "json",
441
    //         "success" : function(data) {
442
    //             console.log(data);
443
    //             if (data.success && data.data){
444
    //                 var itemlist = '';
445
    //                 var itemlist = '<li id="usid">';
446
    //                 itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
447
    //                 itemlist += '<div class="madiaInfo" style="padding-right:42px">';
448
    //                 itemlist += '<p class="ellipsisSty"><span class="h1Font" id="name"></span><span class="h2Font" style="margin-left:10px;" id="title"></span></p>';
449
    //                 itemlist += '<p class="h2Font ellipsisSty" id="orgName"></p>';
450
    //                 itemlist += '</div><div class="deleteThis"></div></li>';
451
    //                 $itemlist = $(itemlist);
452
    //                 $("#expertli").append($itemlist);
453
    //                 var datalist = data.data;
454
    //                 $itemlist.attr("data-id",datalist.id);
455
    //                 $itemlist.find("#name").text(datalist.name);
456
    //                 $itemlist.find("#title").text(datalist.title);
457
    //                 $itemlist.find("#orgName").text(datalist.orgName);
458
    //                 if(datalist.hasHeadImage==1) {
459
    //                     $itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + datalist.id + "_l.jpg);");
460
    //                 }
461
    //             }
462
    //         },
463
    //         "error":function(){
464
    //             $.MsgBox.Alert('提示','链接服务器超时')
465
    //         }
466
    //     });
467
    // }
468
    //
469
    // //相关资源
470
    // function relevantResources(){
471
    //     $.ajax({
472
    //         "url": "/ajax/article/ralateRes",
473
    //         "type": "get",
474
    //         "dataType" : "json",
475
    //         "data" :{"articleId":articleId},
476
    //         "success": function(data) {
477
    //             if(data.success && data.data) {
478
    //                 for(var i = 0; i < data.data.length; i++) {
479
    //                     var resourceId = data.data[i].resourceId;
480
    //                     relevantResourcesList(resourceId)
481
    //                 }
482
    //
483
    //             }
484
    //         },
485
    //         "error": function() {
486
    //             $.MsgBox.Alert('提示', '链接服务器超时')
487
    //         }
488
    //     });
489
    // }
490
    //
491
    // //相关资源信息
492
    // function relevantResourcesList(resourceId){
493
    //     $.ajax({
494
    //         "url" : "/ajax/resource/resourceInfo",
495
    //         "type" :  "GET" ,
496
    //         "dataType" : "json",
497
    //         "data" :{"resourceId":resourceId},
498
    //         "success" : function(data) {
499
    //             console.log(data);
500
    //             if (data.success && data.data){
501
    //                 var itemlist = '<li id="usid">';
502
    //                 itemlist += '<div class="madiaHead resouseHead" id="userimg"></div>';
503
    //                 itemlist += '<div class="madiaInfo" style="padding-right:42px">';
504
    //                 itemlist += '<p class="h1Font ellipsisSty" id="resourceName"></p>';
505
    //                 itemlist += '<p class="h2Font" id="name"></p>';
506
    //                 itemlist += '</div><div class="deleteThis"></div></li>';
507
    //                 $itemlist = $(itemlist);
508
    //                 $("#resources").append($itemlist);
509
    //                 var datalist = data.data;
510
    //                 $itemlist.attr("data-id", datalist.resourceId);
511
    //                 $itemlist.find("#resourceName").text(datalist.resourceName);
512
    //                 $itemlist.find("#name").text(datalist.editProfessor.name);
513
    //                 if(datalist.images.length > 0) {
514
    //                     $itemlist.find("#userimg").attr("style", "background-image: url(/data/resource/" + datalist.images[0].imageSrc + ");");
515
    //                 }
516
    //             }
517
    //         },
518
    //         "error":function(){
519
    //             $.MsgBox.Alert('提示','链接服务器超时')
520
    //         }
521
    //     });
522
    // }
482 523
483 524
    var titleflase = false;
484 525
    //交验图片和标题不能为空
@ -521,67 +562,134 @@ $(function() {
521 562
        return $.unique(resourcesarray);
522 563
    }
523 564
524
565
    var seleClum ='<div class="mb-list mb-listL"><p>请选择文章发布的栏目:</p>'+
566
        '<select class="form-control form-column" id="seletColum"></select></div>';
567
    var seleTime = '<div class="mb-list mb-listR"><p>请设置文章发布的时间:</p>'+
568
        '<div class="formTime"><div class="form-group">'+
569
        '<input size="16" type="text" value="" readonly class="form-control form_datetime">'+
570
        '</div></div></div>';
525 571
    //文章发布
526
    $("#release").on("click",function(){
527
        noTitleImg();
528
        if(titleflase){
529
            $.MsgBox.Confirm("提示","确认发布该文章?",newsAdd);
572
    $("#release").on("click", function() {
573
        if($(this).hasClass("disableLi")){
574
            return;
530 575
        }
531
    })
532
533
    //文章存草稿
534
    $("#draft").on("click",function(){
535 576
        noTitleImg();
536
        if(titleflase){
537
            draftAdd(1);
538
        }
539
    })
577
        if(titleflase) {
578
            console.log(colMgr)
579
            if(colMgr=="true"){
580
                $(".blackcover2").fadeIn();
581
                var btnOk='<input class="mb_btn mb_btnOk mb_btnOkpub" type="button" value="确定">'
582
                $(".mb_btnOk").remove(); $("#promotGt").prepend(btnOk);
583
                $(".modelContain").show(); $("body").addClass("modelOpen");
584
                $(".mb-listR").remove();
585
                $(".mb-listL").remove();
586
                $("#promotTh").prepend(seleClum);
587
                fillColum(7);//填充select栏目
588
                $(".mb_btnOkpub").on("click", function() {
589
                    $(".blackcover2").fadeOut();
590
                    $(".modelContain").hide();
591
                    $("body").removeClass("modelOpen");
592
                    $.MsgBox.Confirm("提示", "确认修改该文章?", newsAdd);
593
                })
594
            }else{
595
                $.MsgBox.Confirm("提示", "确认修改该文章?", newsAdd);
596
            }
540 597
541
    //文章预览
542
    $("#preview").on("click",function(){
543
        noTitleImg();
544
        if(titleflase){
545
            draftAdd(2);
546 598
        }
547
    })
548
549
    //删除文章
550
    $("#delete").on("click",function(){
551
        $.MsgBox.Confirm("提示","确认删除该文章",newsDelet);
552
    })
599
    });
553 600
554 601
    //定时文章发布
555
    $("#setTimeIssue").on("click", function() {
556
        //$(".form_datetime").val(timeGeshi(modifyTimeval));
557
        noTitleImg();
558
        if(titleflase) {
559
            $(".blackcover2").fadeIn();
560
            $(".modelContain").show();
561
            $("body").addClass("modelOpen");
562
            $(".mb_btnOk").on("click", function() {
563
                var modifyTimeval = $(".form_datetime").val();
564
                settime = true;
565
                setTimeIssue(st6(modifyTimeval),settime);
566
            })
567
        }
568
    })
569
602
    // $("#setTimeIssue").on("click", function() {
603
    //     if($(this).hasClass("disableLi")){
604
    //         return;
605
    //     }
606
    //     noTitleImg();
607
    //     if(titleflase) {
608
    //         $(".blackcover2").fadeIn();
609
    //         var btnOk='<input class="mb_btn mb_btnOk mb_btnOkset" type="button" value="确定">'
610
    //         $(".mb_btnOk").remove(); $("#promotGt").prepend(btnOk);
611
    //         $(".modelContain").show(); $("body").addClass("modelOpen");
612
    //         $(".mb-listR").remove(); $("#promotTh").append(seleTime);//时间选择器
613
    //         $(".mb-listR .form_datetime").datetimepicker({
614
    //             format: 'yyyy-mm-dd hh:ii',
615
    //             forceParse: true,
616
    //             autoclose: true,
617
    //         });
618
    //         $(".mb-listR .form_datetime").val(getNowFormatDate());
619
    //         if(colMgr=="true"){
620
    //             $(".mb-listL").remove();
621
    //             $("#promotTh").prepend(seleClum);
622
    //             fillColum(7);//填充select栏目
623
    //         }
624
    //         $(".mb_btnOkset").on("click", function() {
625
    //             var publishTime = $(".form_datetime").val();
626
    //             console.log(st6(publishTime));
627
    //             setTimeIssue(st6(publishTime));
628
    //         })
629
    //     }
630
    // })
631
    //
632
    // //文章存草稿
633
    // $("#draft").on("click",function(){
634
    //     if($(this).hasClass("disableLi")){
635
    //         return;
636
    //     }
637
    //     noTitleImg();
638
    //     if(titleflase){
639
    //         draftAdd(1);
640
    //     }
641
    // })
642
    //
643
    // //文章预览
644
    // $("#preview").on("click",function(){
645
    //     if($(this).hasClass("disableLi")){
646
    //         return;
647
    //     }
648
    //     noTitleImg();
649
    //     if(titleflase){
650
    //         draftAdd(2);
651
    //     }
652
    // })
653
    //
654
    // //删除文章
655
    // $("#delete").on("click",function(){
656
    //     $.MsgBox.Confirm("提示","确认删除该文章?",newsDelet);
657
    // })
658
659
660
    function getAttrId() {
661
        var arr=[];
662
        this.each(function(){
663
            arr.push( $(this).attr("data-id"));
664
        });
665
        return arr;
666
    }
570 667
    /*获取数据*/
571
    function getdata(publishTime,settime) {
572
        expertli();//相关专家
573
        resourcesli();//相关咨询
574
        $data.articleId = articleId;
575
        $data.professorId = userid;
668
    function getdata(publishTime) {
669
        expertli(); //相关专家
670
        resourcesli(); //相关咨询
671
        // $data.orgId = orgId;
672
        $data.articleId=articleId;
673
        if($("#companys li").length) {
674
            $data.orgs = getAttrId.call($("#companys li"));
675
        }
576 676
        $data.articleTitle = $("#newstitle").val();
577 677
        $data.subject = captiureSubInd("keyWordlist .delkeylist");
578 678
        $data.articleImg = $("#uploader").attr("data-id");
579 679
        $data.articleContent = ue.getContent();
580
        $data.professors = experarray;
581
        $data.resources = resourcesarray;
582
        if(settime) {
583
            $data.publishTime = publishTime;
584
        }
680
        // $data.professors = experarray;
681
        // $data.resources = resourcesarray;
682
        // if(colMgr=="true"){
683
        //     $data.colNum = $("#seletColum").val();
684
        //     if(publishTime!="") {
685
        //         $data.publishTime = publishTime;
686
        //     }
687
        // }else{
688
        //     if(publishTime!="") {
689
        //         $data.publishTime = publishTime;
690
        //     }
691
        //     $data.colNum=2;
692
        // }
585 693
        console.log($data);
586 694
    }
587 695
@ -589,25 +697,29 @@ $(function() {
589 697
    /*文章添加*/
590 698
    function newsAdd(){
591 699
        getdata();
700
        $(".operateBlock").find("li").addClass("disableLi");
592 701
        $.ajax({
593 702
            "url" : "/ajax/article/save",
594 703
            "type" :  "post" ,
595 704
            "dataType" : "json",
596 705
            "data" :$data,
597 706
            "traditional": true, //传数组必须加这个
707
            "complete":function(){
708
                $(".operateBlock").find("li").removeClass("disableLi");
709
            },
598 710
            "success" : function(data) {
599 711
                console.log(data);
600 712
                if (data.success){
601 713
                    articleId = data.data;
602
                    $.MsgBox.Alert("提示","文章发表成功!",function articalList(){
603
                        location.href = "articalList.html";
714
                    $.MsgBox.Alert("提示","文章修改成功!",function articalList(){
715
                        // location.href = "cmp-articalList.html";
604 716
                    });
605
                    $("#mb_msgicon").css("background", 'url("images/sign_icon_chenggong_nor.png") 0% 0% / contain');
717
                    $("#mb_msgicon").css("background", 'url("/images/sign_icon_chenggong_nor.png") 0% 0% / contain');
606 718
                } else {
607 719
                    if(data.code==90) {
608 720
                        $.MsgBox.Alert('提示', '由于操作时间过久,上传图片已失效,请重新上传。');
609 721
                    }else{
610
                        $.MsgBox.Alert("提示", "文章发表失败!");
722
                        $.MsgBox.Alert("提示", "文章修改失败!");
611 723
                    }
612 724
                }
613 725
            },
@ -618,111 +730,270 @@ $(function() {
618 730
    }
619 731
620 732
    /*文章定时发布*/
621
    function setTimeIssue(publishTime,settime) {
622
        var opublishTime=publishTime+"01";
623
        getdata(opublishTime,settime);
624
        $.ajax({
625
            "url": "/ajax/article/timing",
626
            "type": "post",
627
            "dataType": "json",
628
            "data": $data,
629
            "traditional": true, //传数组必须加这个
630
            "success": function(data) {
631
                console.log(data);
632
                if(data.success) {
633
                    articleId = data.data;
634
                    location.href = "articalList.html";
635
                } else {
636
                    if(data.code==90) {
637
                        $.MsgBox.Alert('提示', '由于操作时间过久,上传图片已失效,请重新上传。');
638
                    }else{
639
                        $.MsgBox.Alert("提示", "文章发表失败!");
640
                    }
641
                }
642
            },
643
            "error": function() {
644
                $.MsgBox.Alert('提示', '链接服务器超时')
645
            }
646
        });
647
    }
733
    // function setTimeIssue(publishTime,settime) {
734
    //     var opublishTime=publishTime+"01";
735
    //     getdata(opublishTime,settime);
736
    //     $(".operateBlock").find("li").addClass("disableLi");
737
    //     $.ajax({
738
    //         "url": "/ajax/article/timing",
739
    //         "type": "post",
740
    //         "dataType": "json",
741
    //         "data": $data,
742
    //         "traditional": true, //传数组必须加这个
743
    //         "complete":function(){
744
    //             $(".operateBlock").find("li").removeClass("disableLi");
745
    //         },
746
    //         "success": function(data) {
747
    //             console.log(data);
748
    //             if(data.success) {
749
    //                 articleId = data.data;
750
    //                 location.href = "cmp-articalList.html";
751
    //             } else {
752
    //                 if(data.code==90) {
753
    //                     $.MsgBox.Alert('提示', '由于操作时间过久,上传图片已失效,请重新上传。');
754
    //                 }else{
755
    //                     $.MsgBox.Alert("提示", "文章发表失败!");
756
    //                 }
757
    //             }
758
    //         },
759
    //         "error": function() {
760
    //             $.MsgBox.Alert('提示', '链接服务器超时')
761
    //         }
762
    //     });
763
    // }
648 764
649 765
    /*文章添加草稿和文章预览*/
650
    function draftAdd(num){
651
        getdata();
652
        $.ajax({
653
            "url" : "/ajax/article/draft",
654
            "type" :  "post" ,
655
            "dataType" : "json",
656
            "data" :$data,
657
            "traditional": true, //传数组必须加这个
658
            "success" : function(data) {
659
                console.log(data);
660
                if(num==1){
661
                    if (data.success){
662
                        articleId = data.data;
663
                        $.MsgBox.Alert("提示","文章已保存草稿。");
664
                        $("#mb_msgicon").css("background", 'url("images/sign_icon_chenggong_nor.png") 0% 0% / contain');
665
                        articleshow();
666
                    }else{
667
                        if(data.code==90) {
668
                            $.MsgBox.Alert('提示', '由于操作时间过久,上传图片已失效,请重新上传。');
669
                        }else{
670
                            $.MsgBox.Alert("提示", "文章发表失败!");
671
                        }
672
                    }
673
                }
674
                if(num==2){
675
                    if(data.success) {
676
                        $("#hidearticleId").val(data.data);
677
                        articleId = data.data;
678
                        $("#delete").removeClass("disableLi").addClass("odele");
679
                        fa = true;
680
                    }else{
681
                        if(data.code==90) {
682
                            $.MsgBox.Alert('提示', '由于操作时间过久,上传图片已失效,请重新上传。');
683
                        }else{
684
                            $.MsgBox.Alert("提示", "文章发表失败!");
685
                        }
686
                    }
687
                    if(fa) {
688
                        window.open("articalPreview.html?articleId=" + articleId)
689
                    }
690
                }
691
            },
692
            "error":function(){
693
                $.MsgBox.Alert('提示','链接服务器超时')
694
            }
695
        });
696
    }
766
    // function draftAdd(num){
767
    //     getdata();
768
    //     $(".operateBlock").find("li").addClass("disableLi");
769
    //     $.ajax({
770
    //         "url" : "/ajax/article/draft",
771
    //         "type" :  "post" ,
772
    //         "dataType" : "json",
773
    //         "data" :$data,
774
    //         "traditional": true, //传数组必须加这个
775
    //         "complete":function(){
776
    //             $(".operateBlock").find("li").removeClass("disableLi");
777
    //         },
778
    //         "success" : function(data) {
779
    //             console.log(data);
780
    //             if(num==1){
781
    //                 if (data.success){
782
    //                     articleId = data.data;
783
    //                     $.MsgBox.Alert("提示","文章已保存草稿。");
784
    //                     $("#mb_msgicon").css("background", 'url("images/sign_icon_chenggong_nor.png") 0% 0% / contain');
785
    //                     articleshow();
786
    //                 }else{
787
    //                     if(data.code==90) {
788
    //                         $.MsgBox.Alert('提示', '由于操作时间过久,上传图片已失效,请重新上传。');
789
    //                     }else{
790
    //                         $.MsgBox.Alert("提示", "文章发表失败!");
791
    //                     }
792
    //                 }
793
    //             }
794
    //             if(num==2){
795
    //                 if(data.success) {
796
    //                     $("#hidearticleId").val(data.data);
797
    //                     articleId = data.data;
798
    //                     $("#delete").removeClass("disableLi").addClass("odele");
799
    //                     fa = true;
800
    //                 }else{
801
    //                     if(data.code==90) {
802
    //                         $.MsgBox.Alert('提示', '由于操作时间过久,上传图片已失效,请重新上传。');
803
    //                     }else{
804
    //                         $.MsgBox.Alert("提示", "文章发表失败!");
805
    //                     }
806
    //                 }
807
    //                 if(fa) {
808
    //                     window.open("../articalPreview.html?articleId=" + articleId)
809
    //                 }
810
    //             }
811
    //         },
812
    //         "error":function(){
813
    //             $.MsgBox.Alert('提示','链接服务器超时')
814
    //         }
815
    //     });
816
    // }
697 817
698 818
    /*文章删除*/
699
    function newsDelet() {
700
        $.ajax({
701
            "url" : "/ajax/article/deleteArticle",
702
            "type" : "POST",
703
            "dataType" : "json",
704
            "data": {
705
                "articleId": articleId
706
            },
707
            "success" : function($data) {
708
                if ($data.success) {
709
                    location.href = "articalList.html";
710
                }
711
            },
712
            "error":function(){
713
                $.MsgBox.Alert('提示','链接服务器超时')
714
            }
715
        })
716
    }
717
718
    function st6(osr) {
719
        var tim = osr.substring(0, 4) + osr.substring(5, 7) + osr.substring(8, 10) + osr.substring(11, 13) + osr.substring(14, 16);
720
        return tim;
721
    }
722
723
    function timeGeshi(otm) {
724
        var otme = otm.substring(0, 4) + "-" + otm.substring(4, 6).replace(/\b(0+)/gi, "") + "-" + otm.substring(6, 8).replace(/\b(0+)/gi, "") + " " + otm.substring(8, 10)+ ":" + otm.substring(10, 12);
725
        return otme;
726
    }
727
728
});
819
    // function newsDelet() {
820
    //     $.ajax({
821
    //         "url" : "/ajax/article/deleteArticle",
822
    //         "type" : "POST",
823
    //         "dataType" : "json",
824
    //         "data": {
825
    //             "articleId": articleId
826
    //         },
827
    //         "success" : function($data) {
828
    //             if ($data.success) {
829
    //                 location.href = "cmp-articalList.html";
830
    //             }
831
    //         },
832
    //         "error":function(){
833
    //             $.MsgBox.Alert('提示','链接服务器超时')
834
    //         }
835
    //     })
836
    // }
837
838
    // function st6(osr) {
839
    //     var tim = osr.substring(0, 4) + osr.substring(5, 7) + osr.substring(8, 10) + osr.substring(11, 13) + osr.substring(14, 16);
840
    //     return tim;
841
    // }
842
    //
843
    // function timeGeshi(otm) {
844
    //     var otme = otm.substring(0, 4) + "-" + otm.substring(4, 6) + "-" + otm.substring(6, 8) + " " + otm.substring(8, 10)+ ":" + otm.substring(10, 12);
845
    //     return otme;
846
    // }
847
    // /*添加相关企业*/
848
    // relatCompanies("#company");
849
    // /*添加相关企业*/
850
    // function  relatCompanies(sel) {
851
    //
852
    //     $(sel).bind({
853
    //         paste: function(e) {
854
    //             var pastedText;
855
    //             if (window.clipboardData  &&  window.clipboardData.getData)  {  // IE
856
    //
857
    //                 pastedText  = $(this).val() +  window.clipboardData.getData('Text');
858
    //             }
859
    //             else  {
860
    //                 pastedText  = $(this).val() +  e.originalEvent.clipboardData.getData('Text'); //e.clipboardData.getData('text/plain');
861
    //
862
    //             }
863
    //             $(this).val(pastedText);
864
    //             e.preventDefault();
865
    //         },
866
    //         cut: function(e) {
867
    //             var $this = $(this);
868
    //         },
869
    //         blur: function() {
870
    //             var $this = $(this);
871
    //             setTimeout(function() {
872
    //                 $this.siblings(".form-drop").hide();
873
    //             }, 500)
874
    //             $(this).siblings(".aboutTit").find("span").text("");
875
    //         },
876
    //         focus: function() {
877
    //             $(this).siblings(".form-drop").show();
878
    //             $(this).siblings(".aboutTit").find("span").text("最多选择3家企业");
879
    //         },
880
    //         keyup: function(e) {
881
    //             var ti=$(this).val();
882
    //             orgr=ti;
883
    //             var $this=$(this);
884
    //             if($(this).val().trim()) {
885
    //                 var lNum = $.trim($(this).val()).length;
886
    //                 if(0 < lNum) {
887
    //                     setTimeout(function(){
888
    //                         if( ti===orgr && ti!== orgrEnd) {
889
    //                             var tt=ti;
890
    //                             orgrEnd=tt;
891
    //                             $("#companylist").parent().show();
892
    //                             $.ajax({
893
    //                                 "url": "/ajax/org/qr",
894
    //                                 "type": "GET",
895
    //                                 "data":{
896
    //                                     kw: $this.val(),
897
    //                                     limit:3
898
    //                                 },
899
    //                                 "success": function(data) {
900
    //                                     console.log(data);
901
    //                                     if(data.success) {
902
    //                                         if(orgrEnd==tt) {
903
    //                                             if(data.data.length == 0) {
904
    //                                                 $this.siblings(".form-drop").addClass("displayNone");
905
    //                                                 $this.siblings(".form-drop").find("ul").html("");
906
    //                                             } else {
907
    //                                                 $this.siblings(".form-drop").removeClass("displayNone");
908
    //                                                 var oSr = "";
909
    //                                                 for(var i = 0; i < data.data.length; i++) {
910
    //                                                     var busName=(data.data[i].forShort)?data.data[i].forShort:data.data[i].name;
911
    //                                                     oSr += '<li style="min-height:40px;position:static;"data-id="'+data.data[i].id+'">' + busName + '</li>';
912
    //                                                 }
913
    //                                                 $this.siblings(".form-drop").find("ul").html(oSr);
914
    //                                             }
915
    //                                         }
916
    //                                     } else {
917
    //                                         $this.siblings(".form-drop").addClass("displayNone");
918
    //                                         $this.siblings(".form-drop").find("ul").html("");
919
    //                                     }
920
    //                                 },
921
    //                                 dataType: "json",
922
    //                                 'error': function() {
923
    //                                     $.MsgBox.Alert('提示', '服务器连接超时!');
924
    //                                 }
925
    //                             });
926
    //                         }
927
    //                     },500)
928
    //                 }
929
    //             } else {
930
    //                 $(this).siblings(".form-drop").addClass("displayNone");
931
    //                 $(this).siblings(".form-drop").find("ul").html("");
932
    //             }
933
    //         }
934
    //     })
935
    //     $("#company").siblings(".form-drop").on("click", "li", function() {
936
    //         var oValue = $(this).text();
937
    //         var oJudge = $(this).parents(".form-drop").siblings(".form-result").find("ul li");
938
    //         for(var i = 0; i < oJudge.length; i++) {
939
    //             if(oValue == oJudge[i].innerText) {
940
    //                 $.MsgBox.Alert('提示', '该企业已选择.');
941
    //                 return;
942
    //             }
943
    //         }
944
    //         $(this).parents(".form-drop").siblings(".form-result").find("ul").append('<li class="ellipsisSty" style="min-height:40px;padding-right:42px;" data-id="'+$(this).attr("data-id")+'">' + oValue + '<div class="deleteThis"></div></li>');
945
    //         $(this).parents(".form-drop").siblings("input").val("");
946
    //         if(oJudge.length == 4) {
947
    //             $(this).parents(".form-drop").siblings("input").val("");
948
    //             $("#company").hide();
949
    //         }
950
    //         $(this).parent("ul").html("")
951
    //     })
952
    // }
953
    // companylist()
954
    // //相关企业
955
    // function companylist() {
956
    //     $.ajax({
957
    //         url:"/ajax/article/ralateOrg",
958
    //         dataType: 'json', //数据格式类型
959
    //         type: 'GET', //http请求类型
960
    //         data: {
961
    //             "articleId": articleId,
962
    //         },
963
    //         timeout: 10000, //超时设置
964
    //         success: function(data) {
965
    //             if(data.success) {
966
    //                 var $data=data.data;
967
    //                 if($data.length>=5) {
968
    //                     $("#company").hide();
969
    //                 }
970
    //                 for(var i=0;i<$data.length;i++) {
971
    //                     angleBus.call($data[i])
972
    //                 }
973
    //             }
974
    //         },
975
    //         error: function() {
976
    //             $.MsgBox.Alert('提示', '服务器请求失败')
977
    //         }
978
    //     });
979
    // }
980
    // function angleBus() {
981
    //     $.ajax({
982
    //         url: "/ajax/org/" +this.orgId,
983
    //         type: "GET",
984
    //         timeout: 10000,
985
    //         dataType: "json",
986
    //         context: $("#companys"),
987
    //         success: function(data) {
988
    //             if(data.success) {
989
    //                 var oValue=data.data.forShort?data.data.forShort:data.data.name;
990
    //                 this.append('<li class="ellipsisSty" style="min-height:40px;padding-right:42px;" data-id="'+data.data.id+'">' + oValue + '<div class="deleteThis"></div></li>')
991
    //
992
    //             }
993
    //         },
994
    //         error: function(XMLHttpRequest, textStats, errorThrown) {
995
    //             $.MsgBox.Alert('提示', '服务器请求失败')
996
    //         }
997
    //     })
998
    // }
999
});

+ 43 - 0
js/model/sys/article/index.js

@ -97,6 +97,49 @@ spa_define(function () {
97 97
                        util.alert("请选择一篇文章");
98 98
                    }
99 99
                });
100
                root.find(".opt-edit").on("click", function() {
101
                    var $article = root.find("td.opt-check>i.checked");
102
                    if($article.length) {
103
                        if($article.length > 1) {
104
                            util.alert("只能选择一篇文章");
105
                        } else {
106
                            // $.util.get("../ajax/article/id/"+$article.attr("articleId"),null,function(rd){
107
                            //     if(rd){
108
                                    window.open('http://localhost:81/html/model/sys/article/articleModify.html?articleId=' + $article.attr("articleId"));
109
                            //     }else{
110
                            //         util.alertMsg("文章不存在", function(){pdg.reload();});
111
                            //     }
112
                            // },{});
113
                        }
114
                    } else {
115
                        util.alert("请选择一篇文章");
116
                    }
117
                });
118
119
                root.find(".opt-relate").on("click", function() {
120
                    var $article = root.find("td.opt-check>i.checked");
121
                    if($article.length) {
122
                        if($article.length > 1) {
123
                            util.alert("只能选择一篇文章");
124
                        } else {
125
                            $.util.get("../ajax/article/id/" + $article.attr("articleId"), null, function (rd) {
126
                                if (rd) {
127
                                    spa.showModal("sys_article_relate", {
128
                                        data: rd, hand: function () {
129
                                            pdg.reload()
130
                                        }
131
                                    })
132
                                } else {
133
                                    util.alertMsg("文章不存在", function () {
134
                                        pdg.reload();
135
                                    });
136
                                }
137
                            }, {});
138
                        }
139
                    } else {
140
                        util.alert("请选择一篇文章");
141
                    }
142
                });
100 143
                root.find(".opt-view").on("click", function () {
101 144
                    var $org = root.find("td.opt-check>i.checked");
102 145
                    if ($org.length) {

+ 42 - 0
js/model/sys/article/relate.js

@ -0,0 +1,42 @@
1
/**
2
 * Created by TT on 2017/9/11.
3
 */
4
;
5
spa_define(function () {
6
    return $.use(["spa", "util", "form"], function (spa, util, fb) {
7
        return {
8
            modal: function (data) {
9
                var root = spa.findInModal(".sys_article_edit");
10
                var form = fb.build(root.find(".newForm"));
11
                var saveBtn = root.find(".opt-save"),
12
                    save = function () {
13
                        if (form.val().sortNum) {
14
                            var sortNum = form.val().sortNum;
15
                            var reg = new RegExp("^(\\d|[1-9]\\d|100)$");
16
                            if (!reg.test(sortNum)) {
17
                                util.alert("权重值必须是0-100的正整数");
18
                                return;
19
                            }
20
                        } else {
21
                            form.val({sortNum: 0});
22
                        }
23
                        util.post("../ajax/article/sortNum", {
24
                            articleId: data.data.articleId,
25
                            sortNum: form.val().sortNum
26
                        }, function () {
27
                            spa.closeModal();
28
                            if (data.hand) {
29
                                data.hand();
30
                            }
31
                        }, {});
32
                    };
33
34
                root.find(".modal-ctrl .icon-times").on("click", function () {
35
                    spa.closeModal();
36
                });
37
38
                saveBtn.on("click", save);
39
            }
40
        }
41
    });
42
});