Commit 5d0a24f3 authored by wangqinghua's avatar wangqinghua

文章审核

parent 9bf7404b
<?xml version='1.0' encoding='utf-8'?>
<widget id="io.ionic.partyCloud.starter.test" version="0.5.5" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>部机关党建云(测试)</name>
<name>部机关党建云(试运行)</name>
<description>An awesome Ionic/Cordova app.</description>
<author email="hi@ionicframework" href="http://ionicframework.com/">Ionic Framework Team</author>
<content src="index.html" />
......
......@@ -67,7 +67,7 @@
<span class="info-span">房间号</span>
<div class="info-item-content">
<ng-container *ngIf="role == 1 && orgName == nowOrgName">
<ng-container *ngIf="(role == 1 || role == 5) && orgName == nowOrgName">
<label (click)="editFun()">
<input type="text" [(ngModel)]="abbreviation">
<ion-icon ios="ios-create-outline" md="md-create-outline"></ion-icon>
......@@ -95,7 +95,7 @@
<div class="info-item">
<span class="info-span">座机</span>
<div class="info-item-content" >
<ng-container *ngIf="role == 1 && orgName == nowOrgName">
<ng-container *ngIf="(role == 1 || role == 5) && orgName == nowOrgName">
<label (click)="editFun()">
<input type="text" [(ngModel)]="telephone">
<ion-icon ios="ios-create-outline" md="md-create-outline"></ion-icon>
......@@ -125,7 +125,7 @@
<div class="info-item">
<span class="info-span">邮箱</span>
<div class="info-item-content">
<ng-container *ngIf="role == 1 && orgName == nowOrgName">
<ng-container *ngIf="(role == 1 || role == 5) && orgName == nowOrgName">
<label (click)="editFun()">
<input type="text" [(ngModel)]="email">
<ion-icon ios="ios-create-outline" md="md-create-outline"></ion-icon>
......
......@@ -259,7 +259,7 @@ export class PublishPage {
title: this.obj.title, //标题
plateType: this.obj.type, //分类
source: '上海市委组织部', //来源
publishStatus: status, //已提交
publishStatus: status, //已提交 退回1 发布3
content: `&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;` + content, //内容
publishRange: this.obj.publishRange, //范围
submitter: this.userid, //提交者
......@@ -345,7 +345,7 @@ export class PublishPage {
};
let buttonArr = [];
buttonArr.push(preview);
if (this.role == 3) {
if (this.role == 3 || this.role == 5) {
buttonArr.push(publish);
} else {
buttonArr.push(submit);
......
......@@ -25,7 +25,7 @@
<img src="./assets/imgs/home/icon-zbqk.png" alt="">
<label class="label2-2">值班情况</label>
</div>
<ng-container *ngIf="role == 1 || role == 2 || role == 3">
<ng-container *ngIf="role == 1 || role == 2 || role == 3 && role == 5">
<div class="card" (click)="goActivityTrack()">
<img src="./assets/imgs/home/icon-hdgz.png" alt="">
<label class="label2-2">活动跟踪</label>
......
import {Injectable} from "@angular/core";import {HttpClient} from "@angular/common/http";import {Http} from "@angular/http";import {Observable} from "rxjs/Observable";import {AppGlobal} from "../../service/http.service";import {CommonService} from "../../provide/common.service"; @Injectable()export class MineService { constructor( private http: HttpClient, //该请求 将结果转为json private commonSer: CommonService, private https: Http, //该请求不转json ) { } //我的发布 myPublish(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/stuff/myPublish', data); } //我的收藏 myCollection(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/stuff/myCollection', data); } //上传头像 imageUpload(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/common/file/image/upload', data); } //获取个人头像 showImgByFileid(data): Observable<any> { return this.http.get(AppGlobal.domain + '/wisdomgroup/modules/common/file/showImgByFileid/' + data); } //支部积分 orgPointList(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/twissignhistory/orgPointList', this.commonSer.toFormData(data)); } //个人排行榜 personPointList(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/twissignhistory/personPointList', this.commonSer.toFormData(data) ); } //个人积分信息 personPointDetail(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/twissignhistory/personPointDetail', this.commonSer.toFormData(data) ); } }
\ No newline at end of file
import {Injectable} from "@angular/core";import {HttpClient} from "@angular/common/http";import {Http} from "@angular/http";import {Observable} from "rxjs/Observable";import {AppGlobal} from "../../service/http.service";import {CommonService} from "../../provide/common.service"; @Injectable()export class MineService { constructor( private http: HttpClient, //该请求 将结果转为json private commonSer: CommonService, private https: Http, //该请求不转json ) { } //我的发布 myPublish(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/stuff/myPublish', data); } //我的收藏 myCollection(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/stuff/myCollection', data); } //我的审核 appCheckList(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/stuff/appCheckList', data); } //上传头像 imageUpload(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/common/file/image/upload', data); } //获取个人头像 showImgByFileid(data): Observable<any> { return this.http.get(AppGlobal.domain + '/wisdomgroup/modules/common/file/showImgByFileid/' + data); } //支部积分 orgPointList(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/twissignhistory/orgPointList', this.commonSer.toFormData(data)); } //个人排行榜 personPointList(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/twissignhistory/personPointList', this.commonSer.toFormData(data) ); } //个人积分信息 personPointDetail(data): Observable<any> { return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/twissignhistory/personPointDetail', this.commonSer.toFormData(data) ); } }
\ No newline at end of file
......
......@@ -36,10 +36,10 @@
<div *ngIf="footerView" class="stuff-footer">
<ion-row>
<ion-col col-6>
<button>退回</button>
<ion-col col-6 (click)="handle(1)">
<button style="background-color: #999999">退回</button>
</ion-col>
<ion-col col-6>
<ion-col col-6 (click)="handle(3)">
<button>通过</button>
</ion-col>
</ion-row>
......
......@@ -9,6 +9,7 @@ page-verify-handle {
.stuff-container {
padding: 1.5rem;
background-color: #fff;
.stuff-title {
font-weight: 600;
font-size: 2.5rem;
......@@ -31,7 +32,8 @@ page-verify-handle {
color: #888888;
}
}
.stuff-content{
.stuff-content {
line-height: 2.8rem;
color: #444444;
font-family: 'SourceHanSans-Light';
......@@ -49,6 +51,16 @@ page-verify-handle {
border-top: 1px solid #eeeeee;
z-index: 9;
button {
width: 100px;
height: 35px;
line-height: 35px;
background: #e42417;
color: #fff;
border-radius: 5px;
font-size: 1.6rem;
}
[col-2] {
line-height: 4rem;
}
......@@ -136,6 +148,7 @@ page-verify-handle {
margin-top: 1rem;
padding: 0 1.5rem;
background-color: #fff;
.comment-title {
border-bottom: 1px solid #dddddd;
font-weight: 500;
......@@ -143,7 +156,8 @@ page-verify-handle {
margin-bottom: .8rem;
position: relative;
}
.comment-title::after{
.comment-title::after {
content: '';
position: absolute;
top: 7px;
......@@ -152,18 +166,20 @@ page-verify-handle {
height: 15px;
background-color: #e12724;
}
[col-10],[col-2]{
[col-10], [col-2] {
padding: 0;
}
.comment-item {
.contact-img{
.contact-img {
border-radius: 50%;
width: 50px;
height: 50px;
text-align: center;
margin-top: 8px;
}
.comment-info {
color: #d88f27;
font-size: 1.4rem;
......@@ -178,10 +194,12 @@ page-verify-handle {
color: #333333;
line-height: 1.4rem;
}
.comment-time{
.comment-time {
font-size: 1.4rem;
color: #888888;
.repear{
.repear {
color: #3961b3;
font-size: 1.2rem;
cursor: pointer;
......
......@@ -2,6 +2,8 @@ import {Component} from '@angular/core';
import {IonicPage, NavController, NavParams} from 'ionic-angular';
import {AppGlobal} from "../../../service/http.service";
import {DomSanitizer} from "@angular/platform-browser";
import {TabsService} from "../../tabs/tabs.service";
import {CommonService} from "../../../provide/common.service";
@IonicPage()
......@@ -15,20 +17,64 @@ export class VerifyHandlePage {
url = AppGlobal.domain + '/wisdomgroup';
attachments; //附件
footerView = true;
constructor(public navCtrl: NavController, public navParams: NavParams,
public sanitizer: DomSanitizer) {
footerView = false;
stuffId;
constructor(public navCtrl: NavController, public navParams: NavParams, private commonSer: CommonService,
public sanitizer: DomSanitizer, private tabSer: TabsService) {
}
ionViewDidLoad() {
this.stuffObj = this.navParams.get('stuff');
if (this.stuffObj.attachments) this.attachments = this.stuffObj.attachments;
setTimeout(() => {
this.footerView = true;
}, 300)
this.stuffId = this.navParams.get('id');
this.getStuff();
}
ionViewWillLeave() {
this.footerView = false;
}
//获取文章信息
getStuff() {
this.tabSer.stuffInfo(this.stuffId).subscribe(
(res) => {
this.stuffObj = res.data;
this.attachments = res.data.attachments;
let con = this.stuffObj.content.replace(/\r?\n/g, "<br />");
this.stuffObj.content = this.sanitizer.bypassSecurityTrustHtml(con);
}
)
}
handle(){
handle(status) {
let message;
if (status == 1) message = '确定退回当前内容?';
if (status == 3) message = '确定通过当前内容?';
this.commonSer.alert(message, () => {
if (status == 1) {
this.tabSer.stuffPublish(this.stuffId).subscribe(
(res) => {
this.commonSer.toast('已提交');
setTimeout(() => {
this.navCtrl.pop()
}, 800)
}
)
}
if (status == 3) {
this.tabSer.stuffRecall(this.stuffId).subscribe(
(res) => {
this.commonSer.toast('已提交');
setTimeout(() => {
this.navCtrl.pop()
}, 800)
}
)
}
})
}
}
......@@ -7,14 +7,14 @@
</ion-header>
<ion-content class="bgc-e7e8ed">
<ion-content>
<ion-refresher (ionRefresh)="doRefresh($event)">
<ion-refresher-content pullingText="下拉刷新"
refreshingSpinner="bubbles">
</ion-refresher-content>
</ion-refresher>
<div class="main-news">
<ng-container *ngFor="let new of collectionList;">
<ng-container *ngFor="let new of checkList;">
<ng-container *ngIf="new.imgUrl">
<ion-row class="news-item" (click)="goToDetail(new)">
<ion-col col-8 class="news-left">
......@@ -38,13 +38,13 @@
</p>
<p class="news-end">
<span>提交人:</span><span>{{new.publishTime | date:'yyyy-MM-dd'}}</span>
<span>提交时间:</span><span>{{new.publishTime | date:'yyyy-MM-dd'}}</span>
<span>提交时间:</span><span>{{new.createTime | date:'yyyy-MM-dd'}}</span>
</p>
</ion-col>
</ion-row>
</ng-container>
</ng-container>
<ion-list text-center style="margin-top: 10rem" *ngIf="!isLoad && collectionList.length == 0">
<ion-list text-center style="margin-top: 10rem" *ngIf="!isLoad && checkList.length == 0">
<img style="width: 20%;" src="./assets/imgs/no-info.png" alt="">
<p text-center>
暂无审核
......
......@@ -11,12 +11,12 @@ import {StuffDetailPage} from "../../home-pages/stuff-detail/stuff-detail";
templateUrl: 'verify.html',
})
export class VerifyPage {
@ViewChild(InfiniteScrollContent) infiniteScrollContent:InfiniteScrollContent;
@ViewChild(InfiniteScrollContent) infiniteScrollContent: InfiniteScrollContent;
changeType = 1;
pageNum = 1;
pageCount = 10;
collectionList = [];
checkList = [];
picture: string = AppGlobal.domain + '/wisdomgroup';
isLoad = true;
......@@ -31,7 +31,7 @@ export class VerifyPage {
this.getList();
}
change(type){
change(type) {
}
......@@ -40,9 +40,9 @@ export class VerifyPage {
pageNum: this.pageNum,
pageCount: this.pageCount
};
this.mineSer.myCollection(data).subscribe(
this.mineSer.appCheckList(data).subscribe(
(res) => {
this.collectionList = res.data.list;
this.checkList = res.data.list;
this.isLoad = false;
this.totalNum = res.data.total;
}
......@@ -57,9 +57,9 @@ export class VerifyPage {
pageNum: 1,
pageCount: this.pageCount
};
this.mineSer.myCollection(data).subscribe(
this.mineSer.appCheckList(data).subscribe(
(res) => {
this.collectionList = res.data.list;
this.checkList = res.data.list;
this.totalNum = res.data.total;
setTimeout(() => {
this.commonSer.toast('刷新成功');
......@@ -71,7 +71,7 @@ export class VerifyPage {
//加载更多
doInfinite(e) {
if (this.totalNum == this.collectionList.length) {
if (this.totalNum == this.checkList.length) {
this.loadMore = false;
e.enable(false);
return false;
......@@ -81,11 +81,11 @@ export class VerifyPage {
pageNum: this.pageNum,
pageCount: this.pageCount
};
this.mineSer.myCollection(data).subscribe(
this.mineSer.appCheckList(data).subscribe(
(res) => {
this.totalNum = res.data.total;
res.data.list.forEach(e => {
this.collectionList.push(e);
this.checkList.push(e);
});
setTimeout(() => {
e.complete()
......@@ -96,7 +96,7 @@ export class VerifyPage {
//查看文章详情
goToDetail(item) {
this.navCtrl.push(StuffDetailPage, {
this.navCtrl.push("VerifyHandlePage", {
id: item.id
})
}
......
......@@ -87,7 +87,7 @@
<ion-icon name="ios-arrow-forward"></ion-icon>
</ion-col>
</ion-row>
<ion-row *ngIf="role == 3" (click)="goTo('VerifyPage')">
<ion-row (click)="goTo('VerifyPage')">
<ion-col class="group-left" col-2>
<img src="./assets/imgs/mine/wdfb.png">
</ion-col>
......
......@@ -93,8 +93,6 @@ export class ServePage {
ionViewDidEnter() {
//获取权限
this.getRole();
//获取消息数量
this.getNewCount();
//获取日历
......
......@@ -144,6 +144,17 @@ export class TabsService {
return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/stuff/save', data);
}
//审核通过
stuffPublish(params): Observable<any> {
return this.http.get(AppGlobal.domain + '/wisdomgroup/modules/stuff/publish/' + params);
}
//审核退回
stuffRecall(params): Observable<any> {
return this.http.get(AppGlobal.domain + '/wisdomgroup/modules/stuff/recall/' + params);
}
//获取用户组
getGroup(): Observable<any> {
return this.http.get(AppGlobal.domain + '/wisdomgroup/sysmanagement/usergroup/search.ajax');
......@@ -161,7 +172,7 @@ export class TabsService {
//我要出题列表
findPersonQuestions(data): Observable<any> {
return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/personquestion/findPersonQuestions', this.commonSer.toFormData(data) );
return this.http.post(AppGlobal.domain + '/wisdomgroup/modules/personquestion/findPersonQuestions', this.commonSer.toFormData(data));
}
//我要出题列表
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment