Browse Source

客户姓名跳转

XMTT 8 years ago
parent
commit
25a7684ae4

+ 3 - 0
css/model/sys/customer.css

@ -26,4 +26,7 @@
26 26
.sys_customer_salesedit{
27 27
    width:800px;
28 28
}
29
.sys_customer_allindex .table-opt .name{
30
    cursor:pointer;
31
}
29 32
.temtextarea{width: 100%;height: 80px;margin-top: 8px;border: none;border: 1px solid #ccc; border-radius: 4px;}

+ 1 - 1
html/model/sys/customer/allindex.html

@ -60,7 +60,7 @@
60 60
				<tr ch-dir="list">
61 61
					<td>{{pi}}</td>
62 62
					<td>{{id}}</td>
63
					<td>{{name}}</td>
63
					<td class="table-opt" professorId="{{id}}"><i class="name">{{name}}</i></td>
64 64
					<td>{{title}}</td>
65 65
					<td>{{address}}</td>
66 66
					<td>{{orgname}}</td>

+ 28 - 21
js/model/sys/customer/allindex.js

@ -1,23 +1,30 @@
1 1
;
2
spa_define(function(){
3
	return $.use(["spa","pagedatagrid","util"],function(spa,pdgf,util){
4
		return{
5
			main: function() {				
6
				var root = spa.findInMain(".sys_customer_allindex");
7
				var pdg = pdgf.build(root);
8
				pdg.code.shell("showDay", function(env) {
9
					if(env.cd && env.cd[this.k]) {
10
						var day = env.cd[this.k];
11
						return day.substring(0, 4) + "-" + day.substring(4, 6) + "-" + day.substring(6, 8);
12
					}
13
					return "";
14
				});
15
				pdg.code.listen($.dict.doTransfer);
16
				root.find(".opt-query").on("click", function() {
17
					pdg.load();
18
				});
19
				pdg.load();
20
			}
21
		};
22
	});
2
spa_define(function () {
3
    return $.use(["spa", "pagedatagrid", "util"], function (spa, pdgf, util) {
4
        return {
5
            main: function () {
6
                var root = spa.findInMain(".sys_customer_allindex");
7
                var pdg = pdgf.build(root);
8
                pdg.code.shell("showDay", function (env) {
9
                    if (env.cd && env.cd[this.k]) {
10
                        var day = env.cd[this.k];
11
                        return day.substring(0, 4) + "-" + day.substring(4, 6) + "-" + day.substring(6, 8);
12
                    }
13
                    return "";
14
                });
15
                pdg.code.listen($.dict.doTransfer);
16
                root.find(".opt-query").on("click", function () {
17
                    pdg.load();
18
                });
19
                pdg.load();
20
                var event = function () {
21
                    root.find(".table-opt i.name").on("click", function () {
22
                        var professorId = $(this).parent().attr("professorId");
23
                        window.open('http://www.ekexiu.com/information-brow.html?professorId=' + professorId);
24
                    });
25
                };
26
                pdg.code.listen(event);
27
            }
28
        };
29
    });
23 30
});